File tree Expand file tree Collapse file tree 1 file changed +8
-3
lines changed Expand file tree Collapse file tree 1 file changed +8
-3
lines changed Original file line number Diff line number Diff line change 3939 if $managed_dirs {
4040 $managed_dirs .each | $entry | {
4141 $dir = $options [' mysqld' ][" ${entry} " ]
42+
4243 if ( $dir and $dir != ' /usr' and $dir != ' /tmp' ) {
44+ $clean_dir = shell_escape($dir )
45+ $clean_package_name = shell_escape($mysql::server::package_name )
46+
4347 exec { "${entry}-managed_dir-mkdir" :
44- command => " /bin/mkdir -p ${dir} " ,
45- unless => " /usr/bin/dpkg -s ${mysql::server::package_name} " ,
48+ command => [ ' /bin/mkdir' , ' -p ' , $clean_dir ] ,
49+ unless => [[ ' /usr/bin/dpkg' , ' -s ' , $clean_package_name ]] ,
4650 notify => Exec[" ${entry} -managed_dir-chmod" ],
4751 }
52+
4853 exec { "${entry}-managed_dir-chmod" :
49- command => " /bin/chmod 777 ${dir} " ,
54+ command => [ ' /bin/chmod' , ' 777' , $clean_dir ] ,
5055 refreshonly => true ,
5156 }
5257 }
You can’t perform that action at this time.
0 commit comments