Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
emulab
emulab-devel
Commits
0153edc2
Commit
0153edc2
authored
Sep 24, 2004
by
Leigh B. Stoller
Browse files
Fix the getopt stuff.
Add -b (batchmode).
parent
e6fc07f1
Changes
1
Hide whitespace changes
Inline
Side-by-side
install/boss-install.in
View file @
0153edc2
...
...
@@ -168,11 +168,17 @@ sub usage {
}
my
$packagedir
=
"";
my
$batchmode
=
0
;
my
%opts
;
getopt
("
p:
",
%opts
);
if
(
$opt
{
p
})
{
$packagedir
=
$opt
{
p
};
if
(
!
getopts
("
p:b
",
\
%opts
))
{
usage
();
}
if
(
defined
(
$opts
{
p
}))
{
$packagedir
=
$opts
{
p
};
}
if
(
defined
(
$opts
{
b
}))
{
$batchmode
=
1
;
}
if
(
@ARGV
)
{
...
...
@@ -182,12 +188,16 @@ if (@ARGV) {
#
# Make sure they know what they're getting into...
#
warn
"
***** Please run install-ops on ops, and reboot it, before running
\n
";
warn
"
this script!
\n\n
";
print
STDERR
"
WARNING: This script is ONLY intended to be run on a machine
\n
";
print
STDERR
"
that is being set up as a dedicated boss node. Continue? [y/N]
";
my
$response
=
<>
;
die
"
Installation aborted!
\n
"
unless
(
$response
=~
/^y/i
);
if
(
!
$batchmode
)
{
warn
"
***** Please run install-ops on ops, and reboot it, before running
\n
";
warn
"
this script!
\n\n
";
print
STDERR
"
WARNING: This script is ONLY intended to be run on a machine
\n
";
print
STDERR
"
that is being set up as a dedicated boss node. Continue? [y/N]
";
my
$response
=
<>
;
die
"
Installation aborted!
\n
"
unless
(
$response
=~
/^y/i
);
}
if
(
$UID
!=
0
)
{
die
"
This script must be run as root.
\n
";
...
...
Write
Preview
Supports
Markdown
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