aboutsummaryrefslogtreecommitdiffstats
path: root/modules/planet/templates
diff options
context:
space:
mode:
authorDan Fandrich <danf@mageia.org>2024-10-04 19:28:06 -0700
committerDan Fandrich <danf@mageia.org>2024-10-04 19:28:06 -0700
commit2c7da66570999dcd21f11f976dc6ec27d820f45c (patch)
treeb97dd9f25df691c66b2be31b658cc6fec638d47e /modules/planet/templates
parenta69863ece1973cf3eae488f30c657b57dfb89779 (diff)
downloadpuppet-2c7da66570999dcd21f11f976dc6ec27d820f45c.tar
puppet-2c7da66570999dcd21f11f976dc6ec27d820f45c.tar.gz
puppet-2c7da66570999dcd21f11f976dc6ec27d820f45c.tar.bz2
puppet-2c7da66570999dcd21f11f976dc6ec27d820f45c.tar.xz
puppet-2c7da66570999dcd21f11f976dc6ec27d820f45c.zip
Use @ when accessing variables in templates
Access without the @ symbol is the older method and is discouraged.
Diffstat (limited to 'modules/planet/templates')
-rwxr-xr-xmodules/planet/templates/backup_planet-files.sh2
-rwxr-xr-xmodules/planet/templates/deploy_new-planet.sh4
-rw-r--r--modules/planet/templates/planet_vhosts.conf2
3 files changed, 4 insertions, 4 deletions
diff --git a/modules/planet/templates/backup_planet-files.sh b/modules/planet/templates/backup_planet-files.sh
index 8cab8d1e..47916370 100755
--- a/modules/planet/templates/backup_planet-files.sh
+++ b/modules/planet/templates/backup_planet-files.sh
@@ -11,7 +11,7 @@ do
then
/bin/mkdir $PATH_TO_FILE/$locale
fi
- rsync -aHP --delete <%= location %>/$locale $PATH_TO_FILE/$locale/$locale-$COUNT
+ rsync -aHP --delete <%= @location %>/$locale $PATH_TO_FILE/$locale/$locale-$COUNT
done
# Check count file to have a week of backup in the directory
if [ $COUNT -ne 6 ]
diff --git a/modules/planet/templates/deploy_new-planet.sh b/modules/planet/templates/deploy_new-planet.sh
index b3889d31..41557fcc 100755
--- a/modules/planet/templates/deploy_new-planet.sh
+++ b/modules/planet/templates/deploy_new-planet.sh
@@ -2,7 +2,7 @@
# Initialization
PATH_TO_FILE=${PATH_TO_FILE:-/var/lib/planet}
-PATH_TO_PLANET=${PATH_TO_PLANET:-<%= location %>}
+PATH_TO_PLANET=${PATH_TO_PLANET:-<%= @location %>}
#Ask for new locale name
echo -n "Locale name: "
@@ -33,7 +33,7 @@ then
/bin/mkdir $FILE"cache"
/bin/chown -R planet:apache $FILE
/bin/chmod g+w $FILE"custom" $FILE"custom/people.opml" $FILE"admin/inc/pwd.inc.php" $FILE"cache"
- echo -e "Info: a new Planet had been deployed.\nThe locale is: \"$locale\" - https://planet.<%= domain %>/$locale \n-- \nMail sent by the script '$0' on `hostname`" | /bin/mail -s "New planet Mageia deployed" mageia-webteam@<%= domain %> mageia-marketing@<%= domain %>
+ echo -e "Info: a new Planet had been deployed.\nThe locale is: \"$locale\" - https://planet.<%= @domain %>/$locale \n-- \nMail sent by the script '$0' on `hostname`" | /bin/mail -s "New planet Mageia deployed" mageia-webteam@<%= @domain %> mageia-marketing@<%= @domain %>
fi
else
echo "Aborted, please try again."
diff --git a/modules/planet/templates/planet_vhosts.conf b/modules/planet/templates/planet_vhosts.conf
index b3a07ab9..652a69e7 100644
--- a/modules/planet/templates/planet_vhosts.conf
+++ b/modules/planet/templates/planet_vhosts.conf
@@ -1,4 +1,4 @@
-<Directory <%= location %> >
+<Directory <%= @location %> >
Order deny,allow
Allow from All
AllowOverride All