diff options
Diffstat (limited to 'abs/core/LinHES-config')
-rwxr-xr-x | abs/core/LinHES-config/PKGBUILD | 4 | ||||
-rwxr-xr-x | abs/core/LinHES-config/mv_webuser.py | 17 |
2 files changed, 15 insertions, 6 deletions
diff --git a/abs/core/LinHES-config/PKGBUILD b/abs/core/LinHES-config/PKGBUILD index b86421e..daacaf2 100755 --- a/abs/core/LinHES-config/PKGBUILD +++ b/abs/core/LinHES-config/PKGBUILD @@ -1,6 +1,6 @@ pkgname=LinHES-config pkgver=2.3 -pkgrel=175 +pkgrel=177 conflicts=(MythVantage-config MythVantage-config-dev LinHES-config-dev LinHes-config ) pkgdesc="Install and configure your system" depends=('bc' 'libstatgrab' 'mysql-python' 'expect' 'curl' 'dnsutils' 'parted' @@ -156,7 +156,7 @@ md5sums=('6a9a22b3c3cb74d9f1ac595cf437a7b7' '824e49d9b01fed295c704ab68908b464' 'fe5e31b833cc6707209e9d656b6eb53c' 'ecb52b9b7a9ac0c8988093c1dfdda635' - '23d0e12b7ca1cc6ea6b993c1d7ff20b9' + '087a0ef743bc8af915503f8773536ce4' '1aa69e89034def751177cbd96c64e4ef' 'b4900090d841d3e390cb840cf16afd85' '6dd202ec664ede468e42edf600f7913d' diff --git a/abs/core/LinHES-config/mv_webuser.py b/abs/core/LinHES-config/mv_webuser.py index 3e383f2..e349e0b 100755 --- a/abs/core/LinHES-config/mv_webuser.py +++ b/abs/core/LinHES-config/mv_webuser.py @@ -8,16 +8,25 @@ def setup_web_auth(UseMythWEB_auth): return logging.info("____Start of setup_web_auth____") + include_file="/etc/gen_light_conf.d/auth.conf" if UseMythWEB_auth == str(1): - #enable auth logging.info(" Enabling authorization for mythweb") - cmd='''sed -i "s/^.*include.*auth-inc.conf.*$/include \\"\/etc\/lighttpd\/auth-inc.conf\\"/g" /etc/lighttpd/lighttpd.conf''' - mv_common.runcmd(cmd) + try: + fo = open(include_file, "w") + out_string='''include "/etc/lighttpd/auth-inc.conf"''' + fo.write(out_string) + fo.close() + except: + logging.info(" Couldn't open auth include file") + else: #disable auth logging.info(" Disabling authorization for mythweb") - cmd='''sed -i "s/^.*include.*auth-inc.conf.*$/#include \\"\/etc\/lighttpd\/auth-inc.conf\\"/g" /etc/lighttpd/lighttpd.conf''' + cmd="rm -f %s" %include_file mv_common.runcmd(cmd) + logging.debug("Running gen_light_include.py") + cmd="/usr/LH/bin/gen_light_include.py" + mv_common.runcmd(cmd) logging.debug("Restarting lighttpd") cmd="sudo sv restart lighttpd" mv_common.runcmd(cmd) |