blob: a079e9e56df437b52d393db4bd4523ec4ae502c5 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
|
SHORT_OPTS=":vh"
LONG_OPTS="version,help"
LOG_DIR="/tmp/pbmtk"
run_module_checks () {
if [ ! -z $1 ]; then
perror "Too many parameters. \n"
print_usage
exit 1
fi
}
init_params () {
:
}
print_usage() {
echo "Usage: $(basename $SELF) pbs-serials [OPTIONS]"
echo -e " -h --help \t print help"
echo -e " -v --version \t print version information"
}
read_params() {
getopt_start $@
eval set -- "$GETOPT_TEMP"
while true ; do
case "$1" in
-v|--version)
echo "OpenSLX PreBoot .. ($VERSION - $VDATE)."
exit 0
;;
-h|--help)
print_usage
exit 0
;;
--) shift ; break ;;
*) perror "Internal error!" ; exit 1 ;;
esac
done
}
get_preboot_serials() {
pinfo "Retrieving Serials..."
unset_quiet
wget -qO- pbs2.mp.openslx.org/resource/getprebootserials/apikey/apikey_uni-freiburg | cat
set_quiet
}
run () {
set_quiet
get_preboot_serials
unset_quiet
}
|