I have q question regarding the resource type „mount“.
If I first create a directory resource and afterwards uses the resource
mount to mount a remote file system on the previous created directory it
works only for the first chef-client run.
After the mount of the remote filesystem, the resource directory will fail
during the next chef-client run.
Following code:
directory “#{tomcat_bag[‘webserver’][‘mountpoint_fs_install’]}” do
’tomcatusr1’
group 'tomcatusr1’
mode 0755
action :create
end
mount tomcat_bag[servertype][‘mountpoint_fs_install’] do
device tomcat_bag[servertype][‘mountsource_fs_install’]
fstype "nfs"
options "rw"
action [:mount, :enable]
End
Log:
First run:
directory[/apps/install] action create (up to date)
I have q question regarding the resource type „mount“.
If I first create a directory resource and afterwards uses the resource
mount to mount a remote file system on the previous created directory it
works only for the first chef-client run.
After the mount of the remote filesystem, the resource directory will fail
during the next chef-client run.
Following code:
directory "#{tomcat_bag['webserver']['mountpoint_fs_install']}" do
'tomcatusr1'
group 'tomcatusr1'
mode 0755
action :create
end
mount tomcat_bag[servertype]['mountpoint_fs_install'] do
device tomcat_bag[servertype]['mountsource_fs_install']
fstype "nfs"
options "rw"
action [:mount, :enable]
End
Log:
First run:
directory[/apps/install] action create (up to date)
At the first run, the directory resource created the local directory /apps/install,
then chwoned and chgrped it. When the second run, fil0001.stag.nubon.com:/install
was already mounted on /apps/install, and the resource tried to chown and chgrp it.
At the first run, the directory resource created the local directory
/apps/install,
then chwoned and chgrped it. When the second run, fil0001.stag.nubon.com:/install
was already mounted on /apps/install, and the resource tried to chown and
chgrp it.