Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Grenoble
Eole-Wol
Commits
4bd42da0
Unverified
Commit
4bd42da0
authored
Aug 26, 2019
by
David Beniamine
Browse files
Alert forbidden actions
parent
69bca546
Changes
2
Hide whitespace changes
Inline
Side-by-side
wol/scripts/wakeonlanservice.sh
View file @
4bd42da0
...
...
@@ -85,6 +85,11 @@ do
# Extract the pertinent part of the log
awk
'BEGIN{IN=0} /Begin host/{if($4=="'
$name
'"){IN=1}} {if(IN){print $0}} /End host/{if($4=="'
$name
'"){IN=0}}'
\
$logfile
>
$tempfile
if
[
!
-s
$tempfile
]
then
# Log file is empty, this happens when we are starting an upgrade on a specific host
cp
$logfile
$tempfile
fi
answer
$tempfile
rm
$tempfile
fi
...
...
wol/www/index.php
View file @
4bd42da0
...
...
@@ -126,7 +126,7 @@ if(!isset($action)){
<input
type=
"submit"
value=
"Mise à jour config"
title=
"Mettre à jour"
>
</form>
<form
action=
"index.php"
method=
"post"
>
<input
type=
"hidden"
name=
"action"
value=
"upgradeA
PT
"
>
<input
type=
"hidden"
name=
"action"
value=
"upgradeA
pt
"
>
<input
type=
"hidden"
name=
"name"
value=
"
<?php
echo
$entry
[
2
];
?>
"
>
<input
type=
"submit"
value=
"Mise à jour config + APT"
title=
"Mettre à jour + apt"
>
</form>
...
...
@@ -258,8 +258,15 @@ if(!isset($action)){
<input
type=
"submit"
value=
"Rafraichir les logs"
title=
"Rafraichir les logs"
>
</form>
<?
}
else
{
echo
"<p><strong>Action '
$action
' interdite !</strong></p>"
;
}
}
?>
<form
action=
"index.php"
method=
"post"
>
<input
type=
"submit"
value=
"Retour à l'accueil"
title=
"Retour à l'accueil"
>
</form>
<?php
}
?>
</div>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment