mirror of
https://github.com/webmin/webmin.git
synced 2026-02-03 06:03:28 +00:00
Merge branch 'master' of github.com:webmin/webmin
This commit is contained in:
@@ -32,8 +32,13 @@ if ($auto) {
|
||||
if (-r "/etc/os-release") {
|
||||
$os_release = `cat /etc/os-release`;
|
||||
}
|
||||
$uname = `uname -a 2>/dev/null`;
|
||||
if (&has_command('uname')) {
|
||||
$uname = `uname -a 2>/dev/null`;
|
||||
}
|
||||
foreach $o (@list) {
|
||||
if ("$^O" =~ /MSWin32/ && "$o->[2]" !~ /windows/) {
|
||||
next;
|
||||
}
|
||||
if ($o->[4] && eval "$o->[4]") {
|
||||
# Got a match! Resolve the versions
|
||||
$ver = $o;
|
||||
|
||||
29
setup.bat
29
setup.bat
@@ -1,13 +1,18 @@
|
||||
@ECHO off
|
||||
ECHO Helper Script to install Webmin on Windows
|
||||
ECHO (c) gnadelwartz https:://gitbub.com/gnadelwartz
|
||||
:: (c) gnadelwartz https:://gitbub.com/gnadelwartz
|
||||
ECHO UNOFFICIAL helper script to guide less experienced users on Windows
|
||||
ECHO for information on installing webmin on Windows manually see:
|
||||
ECHO http://www.webmin.com/windows.html
|
||||
ECHO .
|
||||
ECHO NOTE: Webmin on Windows is community provided and not suppored officially!
|
||||
ECHO last reported working insallations was on Windows 8.1
|
||||
ECHO .
|
||||
|
||||
:: prepare unautenticated Setup
|
||||
SET WEBMIN_download=https://sourceforge.net/projects/webadmin/
|
||||
SET WRT_download=https://www.microsoft.com/download/details.aspx?id=17657
|
||||
SET PROCESS_download=http://retired.beyondlogic.org/solutions/processutil/processutil.htm
|
||||
SET PERL_download=https://www.activestate.com/activeperl/
|
||||
SET PROCESS_download=https://web.archive.org/web/20180105215524/http://retired.beyondlogic.org/solutions/processutil/processutil.htm
|
||||
SET PERL_download=https://platform.activestate.com/ActiveState/ActivePerl-5.26
|
||||
SET perl_path32=C:\Perl
|
||||
SET perl_path64=C:\Perl64
|
||||
SET inst_dir=C:\webmin
|
||||
@@ -20,6 +25,7 @@ SET admin=10000
|
||||
SET ssl=0
|
||||
SET login=admin
|
||||
SET password=admin
|
||||
SET nostart=nostart
|
||||
SET INSTALL=setup.pl
|
||||
|
||||
:: check if we are in webmin dir
|
||||
@@ -36,6 +42,7 @@ IF NOT EXIST %INSTALL% (
|
||||
)
|
||||
|
||||
:: check if perl is installed
|
||||
ECHO Check for Webmin prerequisites ...
|
||||
IF EXIST %perl_path32% (
|
||||
SET perl_path=%perl_path32%
|
||||
ECHO Perl detected
|
||||
@@ -44,7 +51,7 @@ IF EXIST %perl_path32% (
|
||||
SET perl_path=%perl_path64%
|
||||
echo Perl64 detected
|
||||
) ELSE (
|
||||
ECHO Perl is not installed! Please download it from
|
||||
ECHO No Perl detected! Please adjust perl_path or download active state perl
|
||||
ECHO %PERL_download% and install it!
|
||||
start "" %PERL_download%
|
||||
ECHO .
|
||||
@@ -56,7 +63,7 @@ IF EXIST %perl_path32% (
|
||||
WHERE process >nul 2>&1
|
||||
IF %ERRORLEVEL% NEQ 0 (
|
||||
ECHO Required process.exe is not installed! Please download it from
|
||||
ECHO %PROCESS_download% and xopy it to C:\Windows!
|
||||
ECHO %PROCESS_download% and copy it to C:\Windows!
|
||||
start "" %PROCESS_download%
|
||||
ECHO .
|
||||
SET INSTALL=false
|
||||
@@ -65,11 +72,10 @@ IF %ERRORLEVEL% NEQ 0 (
|
||||
:: check if rescource kit is installed
|
||||
WHERE sc >nul 2>&1
|
||||
IF %ERRORLEVEL% NEQ 0 (
|
||||
ECHO Windows Resource Toolkit is not installed! Please download it from
|
||||
ECHO %WRT_download% and install it!
|
||||
ECHO Windows Resource Toolkit is not installed you may not able to run Webmin as a Service!
|
||||
ECHO Please download from %WRT_download% and install it!
|
||||
start "" %WRT_download%
|
||||
ECHO .
|
||||
SET INSTALL=false
|
||||
)
|
||||
|
||||
:: check if needed dir exist
|
||||
@@ -92,7 +98,10 @@ IF EXIST %INSTALL% (
|
||||
SET perl_path=%perl_path%\bin\perl.exe
|
||||
perl %INSTALL% %wa_dir%
|
||||
) ELSE (
|
||||
ECHO Webmin can not installed becasue of missing depedencies!
|
||||
ECHO Webmin can not installed because of missing prerequisites!
|
||||
ECHO see http://www.webmin.com/windows.html for manual installation instructions
|
||||
ECHO .
|
||||
ECHO If you are able to improve/fix installtion on newer Windows Versions report them pls
|
||||
)
|
||||
ECHO .
|
||||
PAUSE
|
||||
|
||||
10
setup.pl
10
setup.pl
@@ -213,7 +213,7 @@ else {
|
||||
print "***********************************************************************\n";
|
||||
$autoos = $ENV{'autoos'} || 2;
|
||||
$temp = &tempname();
|
||||
$ex = system("$perl "."e_path("$srcdir/oschooser.pl")." "."e_path("$srcdir/os_list.txt")." $temp $autoos");
|
||||
$ex = system("$perl "."e_path("$srcdir/oschooser.pl")." "."e_path("$srcdir/os_list.txt")." "."e_path($temp)." $autoos");
|
||||
exit($ex) if ($ex);
|
||||
&read_env_file($temp, \%osinfo);
|
||||
$os_type = $osinfo{'os_type'};
|
||||
@@ -236,8 +236,7 @@ else {
|
||||
if (!&has_command("process.exe")) {
|
||||
&errorexit("The command process.exe must be installed to run Webmin on Windows");
|
||||
}
|
||||
eval "use Win32::Daemon";
|
||||
if ($@) {
|
||||
if (eval "use Win32::Daemon; 1") {
|
||||
&errorexit("The Perl module Win32::Daemon must be installed to run Webmin on Windows");
|
||||
}
|
||||
}
|
||||
@@ -730,6 +729,9 @@ if (!$ENV{'nostart'}) {
|
||||
print "presented, as it does not recognize the CA. Say yes.\n";
|
||||
print "\n";
|
||||
}
|
||||
} else {
|
||||
print "***********************************************************************\n";
|
||||
print "Webmin has been installed but not started!\n\n";
|
||||
}
|
||||
|
||||
if ($oldwadir ne $wadir && $upgrading && !$ENV{'deletedold'}) {
|
||||
@@ -752,7 +754,7 @@ sub copy_to_wadir
|
||||
{
|
||||
if ($wadir ne $srcdir) {
|
||||
print "Copying files to $wadir ..\n";
|
||||
if (&has_command("tar")) {
|
||||
if ("$^O" !~ /MSWin32/) {
|
||||
# Unix tar exists
|
||||
system("cd "."e_path($srcdir)." && tar cf - . | (cd "."e_path($wadir)." ; tar xf -)");
|
||||
}
|
||||
|
||||
@@ -7,10 +7,10 @@ sub acl_security_form
|
||||
{
|
||||
my ($o) = @_;
|
||||
print &ui_table_row($text{'acl_edit'},
|
||||
&ui_yesno_radio("edit", $o->{'edit'}))l
|
||||
&ui_yesno_radio("edit", $o->{'edit'}));
|
||||
|
||||
print &ui_table_row($text{'acl_sched'},
|
||||
&ui_yesno_radio("sched", $o->{'sched'}))l
|
||||
&ui_yesno_radio("sched", $o->{'sched'}));
|
||||
}
|
||||
|
||||
# acl_security_save(&options)
|
||||
|
||||
@@ -8,11 +8,11 @@ sub acl_security_form
|
||||
my ($o) = @_;
|
||||
|
||||
print &ui_table_row($text{'acl_upload'},
|
||||
&ui_yesno_radio("upload", $o->{'upload'}));
|
||||
&ui_yesno_radio("upload", $o->{'upload'}), 3);
|
||||
|
||||
print &ui_table_row($text{'acl_max'},
|
||||
&ui_opt_textbox("max", $o->{'max'}, 8, $text{'acl_unlim'})." ".
|
||||
$text{'acl_b'});
|
||||
$text{'acl_b'}, 3);
|
||||
|
||||
print &ui_table_row($text{'acl_download'},
|
||||
&ui_radio("download", $o->{'download'},
|
||||
@@ -34,7 +34,7 @@ print &ui_table_row($text{'acl_dirs'},
|
||||
&ui_checkbox("home", 1, $text{'acl_home'}, $o->{'home'}), 3);
|
||||
|
||||
print &ui_table_row($text{'acl_fetch'},
|
||||
&ui_yesno_radio("fetch", $o->{'fetch'}));
|
||||
&ui_yesno_radio("fetch", $o->{'fetch'}), 3);
|
||||
}
|
||||
|
||||
# acl_security_save(&options)
|
||||
|
||||
@@ -143,5 +143,5 @@ Per-domain-name SSL certificates can now be created as well as per-IP, allowing
|
||||
---- Changes since 1.890 ----
|
||||
Wildcard SSL certs can now be requested via Let's Encrypt in DNS mode, if the native client is installed.
|
||||
Announcements to all Webmin users can now be displayed on the System Information page.
|
||||
---- Changes since 1.930 ----
|
||||
---- Changes since 1.940 ----
|
||||
The host, port and SSL mode for redirects can now be customized via miniserv.conf options.
|
||||
|
||||
@@ -22,7 +22,7 @@ print &ui_table_row($text{'acl_mods'},
|
||||
|
||||
# Allowed users
|
||||
print &ui_table_row($text{'acl_users'},
|
||||
&ui_radio("users_def", $o->{'users'} eq "*" ? 1
|
||||
&ui_radio("users_def", $o->{'users'} eq "*" ? 1 :
|
||||
$o->{'users'} eq "x" ? 2 : 0,
|
||||
[ [ 1, $text{'acl_all'} ],
|
||||
[ 2, $text{'acl_self'} ],
|
||||
|
||||
@@ -20,7 +20,7 @@ our %access_mods = map { $_, 1 } split(/\s+/, $access{'mods'});
|
||||
our %access_users = map { $_, 1 } split(/\s+/, $access{'users'});
|
||||
our %parser_cache;
|
||||
our (%text, $module_config_directory, $root_directory, $webmin_logfile,
|
||||
$module_var_directory);
|
||||
$module_var_directory, $remote_user);
|
||||
|
||||
=head2 list_webmin_log([only-user], [only-module], [start-time, end-time])
|
||||
|
||||
|
||||
Reference in New Issue
Block a user