[Compatibility] Use `$HOME` instead of hardcoding `/root`
This commit is contained in:
parent
b9cbe29516
commit
f8005f80d9
2
.acmeenv
2
.acmeenv
|
@ -1,4 +1,4 @@
|
|||
. "/root/.acme.sh/acme.sh.env"
|
||||
. "$HOME/.acme.sh/acme.sh.env"
|
||||
|
||||
export CF_Account_ID=""
|
||||
export CF_Token=""
|
6
setup.sh
6
setup.sh
|
@ -20,7 +20,7 @@ chmod -R 600 $SSL_BASE
|
|||
# But I use zsh as the main shell
|
||||
# Therefore I need a shared "environment file" that loads acme.sh
|
||||
# And related environment variables
|
||||
curl -L "$GIST/.acmeenv" > "/root/.acmeenv"
|
||||
curl -L "$GIST/.acmeenv" > "$HOME/.acmeenv"
|
||||
|
||||
# Get the alias config for Let's Encrypt challenges:
|
||||
curl -L "$GIST/letsencrypt.conf" > "$NGINX/letsencrypt.conf"
|
||||
|
@ -36,7 +36,7 @@ curl -L "$GIST/phpfpm.conf" > "$NGINX/phpfpm.conf"
|
|||
curl -L "$GIST/generate-dhparams.sh" | sudo bash
|
||||
|
||||
# Add to ZSH/Bash config files
|
||||
echo '. "/root/.acmeenv"' >> "/root/.zshrc";
|
||||
echo '. "/root/.acmeenv"' >> "/root/.bashrc";
|
||||
echo '. "$HOME/.acmeenv"' >> "$HOME/.zshrc";
|
||||
echo '. "$HOME/.acmeenv"' >> "$HOME/.bashrc";
|
||||
|
||||
echo "Base setup done. Open this link for a base nginx site configuration: $GIST/000-default.conf"
|
Loading…
Reference in New Issue