Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
ruanhaishen
Acme.Sh
Commits
0fda2a1d
Commit
0fda2a1d
authored
Jan 26, 2016
by
neil
Browse files
minor, polish install message
parent
de8090f5
Changes
1
Show whitespace changes
Inline
Side-by-side
le.sh
View file @
0fda2a1d
...
...
@@ -241,13 +241,7 @@ _stopserver() {
}
_initpath
()
{
if
command
-v
sudo
>
/dev/null
;
then
if
[
"
$(
sudo
-n
uptime
2>&1|grep
"load"
|wc
-l
)
"
!=
"0"
]
;
then
SUDO
=
sudo
fi
fi
SUDO
=
"
$(
command
-v
sudo
|
grep
-o
'sudo'
)
"
if
[
-z
"
$API
"
]
;
then
if
[
-z
"
$STAGE
"
]
;
then
API
=
"
$DEFAULT_CA
"
...
...
@@ -917,22 +911,33 @@ uninstallcronjob() {
install
()
{
_initpath
if
command
-v
yum
>
/dev/null
;
then
YUM
=
"1"
INSTALL
=
"
$SUDO
yum install -y "
elif
command
-v
apt-get
>
/dev/null
;
then
INSTALL
=
"
$SUDO
apt-get install -y "
fi
if
!
command
-v
"curl"
>
/dev/null
;
then
_err
"Please install curl first."
_err
"Ubuntu: sudo apt-get install curl"
_err
"CentOS: yum install curl"
_err
"
$INSTALL
curl"
return
1
fi
if
!
command
-v
"crontab"
>
/dev/null
;
then
_err
"Please install crontab first."
_err
"CentOs: yum -y install crontabs"
if
[
"
$YUM
"
]
;
then
_err
"
$INSTALL
crontabs"
else
_err
"
$INSTALL
crontab"
fi
return
1
fi
if
!
command
-v
"openssl"
>
/dev/null
;
then
_err
"Please install openssl first."
_err
"
CentOs: yum -y install
openssl"
_err
"
$INSTALL
openssl"
return
1
fi
...
...
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