bash->sh fix

This commit is contained in:
2024-08-22 17:49:25 +02:00
parent f60539f0b5
commit a6aed08961
2 changed files with 5 additions and 11 deletions

View File

@@ -16,12 +16,6 @@ RUN chmod +x /usr/bin/redis-cli
RUN apk add --update --no-cache docker-cli wget curl dos2unix jq openssl git RUN apk add --update --no-cache docker-cli wget curl dos2unix jq openssl git
#### TEMPORARY KEY MANGEMENT
RUN mkdir -p /root/.ssh
COPY installer /root/.ssh/installer
RUN chmod 660 /root/.ssh/installer
###########################
COPY scripts/scheduler/*.sh /scripts/ COPY scripts/scheduler/*.sh /scripts/
RUN find ./scripts -name "*.sh" | xargs dos2unix RUN find ./scripts -name "*.sh" | xargs dos2unix
RUN ["chmod", "+x", "-R", "/scripts/"] RUN ["chmod", "+x", "-R", "/scripts/"]

View File

@@ -75,7 +75,7 @@ $VOLUME_MOUNTS \
$DOCKER_REGISTRY_URL$SETUP:$SETUP_VERSION" $DOCKER_REGISTRY_URL$SETUP:$SETUP_VERSION"
# TEMP template JSON test nextcloud.json # TEMP template JSON test nextcloud.json
NEXTCLOUD_TEMPLATE=" NEXTCLOUD_TEMPLATE='
{ {
"name": "nextcloud", "name": "nextcloud",
"fields": [ "fields": [
@@ -97,7 +97,7 @@ NEXTCLOUD_TEMPLATE="
} }
] ]
} }
"; ';
if [ "$SERVICE_DIR" == "" ]; then if [ "$SERVICE_DIR" == "" ]; then
SERVICE_DIR="/etc/user/config/services"; SERVICE_DIR="/etc/user/config/services";
@@ -354,12 +354,12 @@ execute_task() {
JSON_TARGET=$(echo '{ "DATE": "'$DATE'", "INSTALL_STATUS": "'$INSTALL_STATUS'" }' | jq -r . | base64 -w0); JSON_TARGET=$(echo '{ "DATE": "'$DATE'", "INSTALL_STATUS": "'$INSTALL_STATUS'" }' | jq -r . | base64 -w0);
elif [ "$TASK_NAME" == "system" ]; then elif [ "$TASK_NAME" == "system" ]; then
#SYSTEM_LIST=("core-dns.json" "cron.json" "domain-local-backend.json" "firewall-letsencrypt.json" "firewall-local-backend.json" "firewall-localloadbalancer-dns.json" "firewall-localloadbalancer-to-smarthostbackend.json" "firewall-smarthost-backend-dns.json" "firewall-smarthost-loadbalancer-dns.json" "firewall-smarthost-to-backend.json" "firewall-smarthostloadbalancer-from-publicbackend.json" "letsencrypt.json" "local-backend.json" "local-proxy.json" "service-framework.json" "smarthost-proxy-scheduler.json" "smarthost-proxy.json") #SYSTEM_LIST="core-dns.json cron.json domain-local-backend.json firewall-letsencrypt.json firewall-local-backend.json firewall-localloadbalancer-dns.json firewall-localloadbalancer-to-smarthostbackend.json firewall-smarthost-backend-dns.json firewall-smarthost-loadbalancer-dns.json firewall-smarthost-to-backend.json firewall-smarthostloadbalancer-from-publicbackend.json letsencrypt.json local-backend.json local-proxy.json service-framework.json smarthost-proxy-scheduler.json smarthost-proxy.json"
SYSTEM_LIST=("core-dns.json" "cron.json" "letsencrypt.json" "local-proxy.json" "service-framework.json" "smarthost-proxy-scheduler.json" "smarthost-proxy.json") SYSTEM_LIST="core-dns.json cron.json letsencrypt.json local-proxy.json service-framework.json smarthost-proxy-scheduler.json smarthost-proxy.json";
INSTALLED_SERVICES=$(ls /etc/user/config/services/*.json ); INSTALLED_SERVICES=$(ls /etc/user/config/services/*.json );
SERVICES=""; SERVICES="";
for SERVICE in $(echo $INSTALLED_SERVICES); do for SERVICE in $(echo $INSTALLED_SERVICES); do
for ITEM in "${SYSTEM_LIST[@]}"; do for ITEM in $SYSTEM_LIST; do
if [ "$(basename $SERVICE)" == "$ITEM" ]; then # system file if [ "$(basename $SERVICE)" == "$ITEM" ]; then # system file
CONTENT=$(cat $SERVICE | base64 -w0); CONTENT=$(cat $SERVICE | base64 -w0);
if [ "$SERVICES" != "" ]; then if [ "$SERVICES" != "" ]; then