document how to unmount with Hiera
This commit is contained in:
@@ -138,3 +138,20 @@ mounter::def::e10550:
|
||||
Note that beside the mandatory `bind` option there is
|
||||
- `_netdev` to be set when the directory to bind (`device`) is on a network volume
|
||||
- `x-systemd.requires-mounts-for=$OTHER_MOUNTPOINT` ensures that systemd prepares the bind mount after the volume on which the directory to bind (`device`) is located
|
||||
|
||||
## Removing a Mount
|
||||
|
||||
Only removing a mount point definition from Hiera does not unmount and remove it from the node. This can then be done manually by unmounting it and removing it from `/etc/fstab`.
|
||||
|
||||
Alternatively an `absent` mount defintion as in below example will automatically unmount and remove the mount `/etc/fstab` entry:
|
||||
|
||||
```
|
||||
mounter::def::scratch:
|
||||
ensure: 'absent'
|
||||
mountpoint: '/media/scratch'
|
||||
|
||||
mounter::mounts:
|
||||
- 'scratch'
|
||||
```
|
||||
|
||||
This configuration can then be removed again after it has been rolled out once to all concernded nodes.
|
||||
|
||||
Reference in New Issue
Block a user