Skip to content

Commit c7b01c4

Browse files
committed
Updated docs and examples to include new device_prefix option
1 parent a12bd57 commit c7b01c4

File tree

3 files changed

+13
-0
lines changed

3 files changed

+13
-0
lines changed

README.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -161,6 +161,9 @@ retry_delay = 5
161161
level = "info"
162162
format = "json"
163163
output = "/var/log/vault-dm-crypt.log"
164+
165+
[dmcrypt]
166+
device_prefix = "crypt" # Prefix for dm-crypt device names (default: "crypt")
164167
```
165168

166169
#### Option 2: AppRole Authentication
@@ -183,12 +186,16 @@ retry_delay = 5
183186
level = "info"
184187
format = "json"
185188
output = "/var/log/vault-dm-crypt.log"
189+
190+
[dmcrypt]
191+
device_prefix = "crypt" # Prefix for dm-crypt device names (default: "crypt")
186192
```
187193

188194
**Notes**:
189195
- Use either `vault_token` OR `approle`/`secret_id`, not both. The two authentication methods are mutually exclusive.
190196
- The `vault_path` supports the `%h` placeholder which is replaced with the short hostname of the machine. This allows organizing keys by hostname.
191197
- For vaultlocker compatibility, set `vault_path = "vaultlocker"` (without hostname placeholder)
198+
- The `device_prefix` option controls the prefix used for dm-crypt device mapper names (e.g., `/dev/mapper/crypt-<uuid>`). Set to `"vaultlocker"` for compatibility with Python vaultlocker. Can also be set via `VAULT_DM_CRYPT_DEVICE_PREFIX` environment variable.
192199

193200
## Vault Configuration
194201

configs/systemd/README.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,9 @@ backend = "secret"
7777
approle = "12345678-1234-1234-1234-123456789012"
7878
approle_name = "vault-dm-crypt-prod" # Required for refresh
7979
secret_id = "87654321-4321-4321-4321-210987654321"
80+
81+
[dmcrypt]
82+
device_prefix = "crypt" # Prefix for dm-crypt device names (default: "crypt")
8083
```
8184

8285
## Monitoring

test/integration/README.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -246,6 +246,9 @@ retry_delay = 5
246246
level = "debug"
247247
format = "text"
248248
output = "stdout"
249+
250+
[dmcrypt]
251+
device_prefix = "crypt" # Prefix for dm-crypt device names (default: "crypt")
249252
```
250253

251254
## Security Considerations

0 commit comments

Comments
 (0)