diff options
Diffstat (limited to 'sysutils/webmin/files')
-rw-r--r-- | sysutils/webmin/files/patch-mount_freebsd-mounts-7.c | 8 | ||||
-rw-r--r-- | sysutils/webmin/files/patch-setup.sh | 74 | ||||
-rw-r--r-- | sysutils/webmin/files/webmin.in | 5 |
3 files changed, 38 insertions, 49 deletions
diff --git a/sysutils/webmin/files/patch-mount_freebsd-mounts-7.c b/sysutils/webmin/files/patch-mount_freebsd-mounts-7.c deleted file mode 100644 index 589bf5032d7a..000000000000 --- a/sysutils/webmin/files/patch-mount_freebsd-mounts-7.c +++ /dev/null @@ -1,8 +0,0 @@ ---- mount/freebsd-mounts-7.c.orig 2015-03-13 23:51:39 UTC -+++ mount/freebsd-mounts-7.c -@@ -1,3 +1,5 @@ -+#include <stdlib.h> -+#include <string.h> - #include <stdio.h> - #include <errno.h> - #include <sys/param.h> diff --git a/sysutils/webmin/files/patch-setup.sh b/sysutils/webmin/files/patch-setup.sh index 4146f59d0404..b7acc29be455 100644 --- a/sysutils/webmin/files/patch-setup.sh +++ b/sysutils/webmin/files/patch-setup.sh @@ -1,6 +1,6 @@ ---- setup.sh.orig 2022-10-01 06:55:59 UTC +--- setup.sh.orig +++ setup.sh -@@ -13,6 +13,13 @@ if [ "$bootscript" = "" ]; then +@@ -13,6 +13,13 @@ bootscript="webmin" fi @@ -14,7 +14,7 @@ cd `dirname $0` if [ -x /bin/pwd ]; then wadir=`/bin/pwd` -@@ -112,7 +119,7 @@ echo "you can just accept the defaults." +@@ -113,15 +120,16 @@ echo "" envetcdir="$config_dir" if [ "$envetcdir" = "" ]; then @@ -23,8 +23,10 @@ envetcdirnotfound=1 fi printf "Config file directory [$envetcdir]: " -@@ -120,7 +127,7 @@ if [ "$config_dir" = "" ]; then - read config_dir + if [ "$config_dir" = "" ]; then +- read config_dir ++ config_dir="$envetcdir" ++ echo "$envetcdir" fi if [ "$config_dir" = "" ]; then - config_dir=/etc/webmin @@ -32,16 +34,7 @@ fi abspath=`echo $config_dir | grep "^/"` if [ "$abspath" = "" ]; then -@@ -214,7 +221,7 @@ if [ "$upgrading" = 1 ]; then - if [ $? != "0" ]; then - echo "logout=$config_dir/logout-flag" >> $config_dir/miniserv.conf - fi -- -+ - # Check for third-party modules in old version - if [ "$wadir" != "$oldwadir" ]; then - echo "Checking for third-party modules .." -@@ -231,7 +238,7 @@ if [ "$upgrading" = 1 ]; then +@@ -232,7 +240,7 @@ else # Config directory exists .. make sure it is not in use ls $config_dir | grep -v rpmsave >/dev/null 2>&1 @@ -50,7 +43,7 @@ echo "ERROR: Config directory $config_dir is not empty" echo "" exit 2 -@@ -240,7 +247,7 @@ else +@@ -241,15 +249,16 @@ # Ask for log directory envvardir="$var_dir" if [ "$envvardir" = "" ]; then @@ -59,8 +52,10 @@ envvardirnotfound=1 fi printf "Log file directory [$envvardir]: " -@@ -248,7 +255,7 @@ else - read var_dir + if [ "$var_dir" = "" ]; then +- read var_dir ++ var_dir="$envvardir" ++ echo "$envvardir" fi if [ "$var_dir" = "" ]; then - var_dir=/var/webmin @@ -68,27 +63,26 @@ fi abspath=`echo $var_dir | grep "^/"` if [ "$abspath" = "" ]; then -@@ -305,7 +312,7 @@ else +@@ -290,7 +299,8 @@ + if [ "$perl" = "" ]; then + if [ "$perldef" = "" ]; then + printf "Full path to perl: " +- read perl ++ perl="%%PERL%%" ++ echo "$perl" + if [ "$perl" = "" ]; then + echo "ERROR: No path entered!" + echo "" +@@ -298,10 +308,8 @@ + fi + else + printf "Full path to perl (default $perldef): " +- read perl +- if [ "$perl" = "" ]; then +- perl=$perldef +- fi ++ perl=$perldef ++ echo "$perldef" + fi fi echo "" - -- # Test perl -+ # Test perl - echo "Testing Perl .." - if [ ! -x $perl ]; then - echo "ERROR: Failed to find perl at $perl" -@@ -780,7 +787,7 @@ if [ -x "$systemctlcmd" ]; then - - # Fix existing systemd webmin.service file to update start and stop commands - (cd "$wadir/init" ; WEBMIN_CONFIG=$config_dir WEBMIN_VAR=$var_dir "$wadir/init/updateboot.pl" "$bootscript") -- -+ - chmod 755 $config_dir/stop $config_dir/start $config_dir/restart $config_dir/restart-by-force-kill $config_dir/reload $config_dir/.pre-install $config_dir/.post-install - else - # Creating symlinks -@@ -1053,5 +1060,3 @@ if [ "$oldwadir" != "$wadir" -a "$upgrading" = 1 -a "$ - echo "version." - echo "" - fi -- -- diff --git a/sysutils/webmin/files/webmin.in b/sysutils/webmin/files/webmin.in index 37eeb2f305b5..797951d52c68 100644 --- a/sysutils/webmin/files/webmin.in +++ b/sysutils/webmin/files/webmin.in @@ -15,8 +15,11 @@ webmin_enable=${webmin_enable:-"NO"} name=webmin rcvar=webmin_enable +required_files=%%PREFIX%%/etc/webmin/var-path +webmin_var_path=`cat %%PREFIX%%/etc/webmin/var-path` + procname=%%PERL%% -pidfile=/var/log/webmin/miniserv.pid +pidfile=${webmin_var_path}/miniserv.pid required_dirs=%%PREFIX%%/etc/webmin command=%%PREFIX%%/etc/webmin/start |