Include real OS type and version in copyconfig.pl call

This commit is contained in:
Jamie Cameron
2017-08-10 12:48:08 -07:00
parent e9c7425498
commit e55e1a32dd

View File

@@ -342,7 +342,9 @@ if [ "$post_config" = "1" ]; then
# Copy config file to /etc/webmin or /etc/usermin
os_type=`grep "^os_type=" /etc/$prog/config | sed -e 's/os_type=//g'`
os_version=`grep "^os_version=" /etc/$prog/config | sed -e 's/os_version=//g'`
/usr/bin/perl /usr/libexec/$prog/copyconfig.pl \$os_type \$os_version /usr/libexec/$prog /etc/$prog $mod
real_os_type=`grep "^real_os_type=" /etc/$prog/config | sed -e 's/real_os_type=//g'`
real_os_version=`grep "^real_os_version=" /etc/$prog/config | sed -e 's/real_os_version=//g'`
/usr/bin/perl /usr/libexec/$prog/copyconfig.pl "\$os_type/\$real_os_type" "\$os_version/\$real_os_version" /usr/libexec/$prog /etc/$prog $mod
# Update the ACL for the root user, or the first user in the ACL
grep "^root:" /etc/$prog/webmin.acl >/dev/null