From 90f3b26bcff975f87a26357659543b69dad2492f Mon Sep 17 00:00:00 2001 From: Brad Warren Date: Sun, 11 Oct 2015 17:29:19 -0700 Subject: [PATCH] Fixed a2enmod --- .../configurators/apache/a2enmod.sh | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/letsencrypt-compatibility-test/letsencrypt_compatibility_test/configurators/apache/a2enmod.sh b/letsencrypt-compatibility-test/letsencrypt_compatibility_test/configurators/apache/a2enmod.sh index 0a8ade4c2..60a62407a 100755 --- a/letsencrypt-compatibility-test/letsencrypt_compatibility_test/configurators/apache/a2enmod.sh +++ b/letsencrypt-compatibility-test/letsencrypt_compatibility_test/configurators/apache/a2enmod.sh @@ -1,6 +1,6 @@ #!/bin/bash # An extremely simplified version of `a2enmod` for enabling modules in the -# httpd docker image. First argument is the server_root and the second is the +# httpd docker image. First argument is the ServerRoot and the second is the # module to be enabled. confdir=$1 @@ -8,10 +8,11 @@ module=$2 echo "LoadModule ${module}_module " \ "/usr/local/apache2/modules/mod_${module}.so" >> "${confdir}/test.conf" -available_conf=$APACHE_CONFDIR"/mods-available/${module}.conf" -enabled_dir=$APACHE_CONFDIR"/mods-enabled" -enabled_conf=$enabled_dir"/"$1".conf" -if [ -e "$available_conf" -a -d "$enabled_dir" -a ! -e "$enabled_conf" ] +availbase="/mods-available/${module}.conf" +availconf=$confdir$availbase +enabldir="$confdir/mods-enabled" +enablconf="$enabldir/${module}.conf" +if [ -e $availconf -a -d $enabldir -a ! -e $enablconf ] then - ln -s "..$available_base" $enabled_conf + ln -s "..$availbase" $enablconf fi