diff options
author | Michael Scherer <misc@mageia.org> | 2011-04-18 10:14:34 +0000 |
---|---|---|
committer | Michael Scherer <misc@mageia.org> | 2011-04-18 10:14:34 +0000 |
commit | e52e80b0a1857f7ffdb1566e8d402e26beec289a (patch) | |
tree | d0099eac7bc26620fded055f5434876b373f4761 /modules/phpbb/manifests/init.pp | |
parent | 118f3a70b4d3dbb999d2a14683c0fb0df76275ac (diff) | |
download | puppet-e52e80b0a1857f7ffdb1566e8d402e26beec289a.tar puppet-e52e80b0a1857f7ffdb1566e8d402e26beec289a.tar.gz puppet-e52e80b0a1857f7ffdb1566e8d402e26beec289a.tar.bz2 puppet-e52e80b0a1857f7ffdb1566e8d402e26beec289a.tar.xz puppet-e52e80b0a1857f7ffdb1566e8d402e26beec289a.zip |
fix reentrency issues of phpbb module ( ie, apache_writable_dir that could not be declared more
than once )
Diffstat (limited to 'modules/phpbb/manifests/init.pp')
-rw-r--r-- | modules/phpbb/manifests/init.pp | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/modules/phpbb/manifests/init.pp b/modules/phpbb/manifests/init.pp index 7cc2f9f7..7f6e166e 100644 --- a/modules/phpbb/manifests/init.pp +++ b/modules/phpbb/manifests/init.pp @@ -64,16 +64,6 @@ class phpbb { } } - define apache_writable_dir() { - file { "$forums_dir/$lang/phpBB/$name": - ensure => directory, - owner => apache, - group => root, - mode => 755, - require => Exec["git_clone $lang"], - } - } - # TODO find a way to avoid all the phpbb::base prefix define instance() { include phpbb::base @@ -104,10 +94,20 @@ class phpbb { # list found by reading ./install/install_install.php # end of check_server_requirements ( 2 loops ) - apache_writable_dir { ['cache', - 'images/avatars/upload', - 'files', - 'store' ]: + + $writable_dirs = ['cache', + 'images/avatars/upload', + 'files', + 'store' ] + + $dir_names = regsubst($writable_dirs,'^',"$forums_dir/$lang/phpBB/") + + file { $dir_names: + ensure => directory, + owner => apache, + group => root, + mode => 755, + require => Exec["git_clone $lang"], } file { "$forums_dir/$lang/phpBB/config.php": |