local backend deploy
This commit is contained in:
17
deploy.sh
17
deploy.sh
@@ -23,6 +23,7 @@ WIREGUARD=$(toUpperCase $WIREGUARD)
|
||||
OPENVPN=$(toUpperCase $OPENVPN)
|
||||
LETSENCRYPT_MAIL=$LETSENCRYPT_MAIL
|
||||
USER_CONFIG_PATH=$USER_CONFIG_PATH
|
||||
DOMAIN=$DOMAIN;
|
||||
|
||||
if [ "$USER_CONFIG_PATH" = "" ]; then
|
||||
USER_CONFIG_PATH=/etc/user/config/user.json
|
||||
@@ -58,6 +59,16 @@ fi
|
||||
if [ "$CRON_REPO" == "" ]; then
|
||||
CRON_REPO="cron";
|
||||
fi
|
||||
if [ "$LOCAL_BACKEND_REPO" == "" ]; then
|
||||
LOCAL_BACKEND_REPO="local-backend";
|
||||
fi
|
||||
|
||||
install_local_backend() {
|
||||
|
||||
sed -i s/DOMAIN_NAME/$DOMAIN/g /tmp/$LOCAL_BACKEND_PROXY/*.json
|
||||
|
||||
cp -rv /tmp/$LOCAL_BACKEND_PROXY/*.json $SERVICE_DIR/ ;
|
||||
}
|
||||
|
||||
install_core_dns() {
|
||||
|
||||
@@ -99,6 +110,10 @@ install_additionals() {
|
||||
|
||||
install_core_dns
|
||||
|
||||
if [[ "$SMARTHOST_PROXY" == "YES" || "$SMART_HOST_PROXY" == "TRUE" ]]; then
|
||||
install_local_backend
|
||||
fi
|
||||
|
||||
if [[ "$LOCAL_PROXY" == "YES" || "$LOCAL_PROXY" == "TRUE" ]]; then
|
||||
cp -av /tmp/$LOCAL_PROXY_REPO/*.json $SERVICE_DIR/
|
||||
fi
|
||||
@@ -141,6 +156,8 @@ if [[ "$CRON" == "YES" || "$CRON" == "TRUE" ]]; then
|
||||
git clone ssh://$GIT_REPO/$ORGANIZATION/$CRON_REPO.git /tmp/$CRON_REPO
|
||||
fi
|
||||
|
||||
git clone ssh://$GIT_REPO/$ORGANIZATION/$LOCAL_BACKEND_REPO.git /tmp/$LOCAL_BACKEND_REPO
|
||||
|
||||
# INSTALL PROXY SERVICES
|
||||
|
||||
for i in $(echo $PROXY_TYPE); do
|
||||
|
Reference in New Issue
Block a user