Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Set non-empty default mount options for the backup_mount resource. #34

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

jperville
Copy link

The backup_mount resource passes an array of node['backup']['mount_options'] to the underlying mount resource since #27. Since these mount options are empty by default and they are passed verbatim to the underlying mount resource, not specifying any mount options explicitly results in broken entries in /etc/fstab.

For example:

root@bib:~# grep nfs /etc/fstab
172.17.17.10://mnt/HD/HD_a2//backups/myserver /data/backups-sync nfs  0 2
172.17.17.10://mnt/HD/HD_a2//backups/myserver /data/backups-sync nfs  0 2
172.17.17.10://mnt/HD/HD_a2//backups/myserver /data/backups-sync nfs  0 2
...

Note that each chef-run adds a line to the /etc/fstab file.
When the server restarts, the backup directory will not be mounted until the next chef-run.

This PR adds default, safe options (default['backup']['mount_options'] = ['soft', 'nosuid']) which should work out of the box.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant