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
a9b4a2a1
Commit
a9b4a2a1
authored
Nov 06, 2016
by
neil
Committed by
GitHub
Nov 06, 2016
Browse files
Merge pull request #370 from Neilpang/dev
add APACHE_HTTPD_CONF
parents
37d7f89c
5be1449d
Changes
1
Hide whitespace changes
Inline
Side-by-side
acme.sh
View file @
a9b4a2a1
...
...
@@ -1808,22 +1808,28 @@ _apachePath() {
return
1
fi
httpdconfname
=
"
$(
$_APACHECTL
-V
|
grep
SERVER_CONFIG_FILE
=
|
cut
-d
=
-f
2 |
tr
-d
'"'
)
"
_debug httpdconfname
"
$httpdconfname
"
if
[
-z
"
$httpdconfname
"
]
;
then
_err
"Can not read apache config file."
return
1
fi
if
_startswith
"
$httpdconfname
"
'/'
;
then
httpdconf
=
"
$httpdconfname
"
if
[
"
$APACHE_HTTPD_CONF
"
]
;
then
_saveaccountconf APACHE_HTTPD_CONF
"
$APACHE_HTTPD_CONF
"
httpdconf
=
"
$APACHE_HTTPD_CONF
"
httpdconfname
=
"
$(
basename
$httpdconfname
)
"
else
httpdroot
=
"
$(
$_APACHECTL
-V
|
grep
HTTPD_ROOT
=
|
cut
-d
=
-f
2 |
tr
-d
'"'
)
"
_debug httpdroot
"
$httpdroot
"
httpdconf
=
"
$httpdroot
/
$httpdconfname
"
httpdconfname
=
"
$(
basename
$httpdconfname
)
"
httpdconfname
=
"
$(
$_APACHECTL
-V
|
grep
SERVER_CONFIG_FILE
=
|
cut
-d
=
-f
2 |
tr
-d
'"'
)
"
_debug httpdconfname
"
$httpdconfname
"
if
[
-z
"
$httpdconfname
"
]
;
then
_err
"Can not read apache config file."
return
1
fi
if
_startswith
"
$httpdconfname
"
'/'
;
then
httpdconf
=
"
$httpdconfname
"
httpdconfname
=
"
$(
basename
$httpdconfname
)
"
else
httpdroot
=
"
$(
$_APACHECTL
-V
|
grep
HTTPD_ROOT
=
|
cut
-d
=
-f
2 |
tr
-d
'"'
)
"
_debug httpdroot
"
$httpdroot
"
httpdconf
=
"
$httpdroot
/
$httpdconfname
"
httpdconfname
=
"
$(
basename
$httpdconfname
)
"
fi
fi
_debug httpdconf
"
$httpdconf
"
_debug httpdconfname
"
$httpdconfname
"
...
...
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