From ba860398f395f3346e6a791e4f4267afc4914a13 Mon Sep 17 00:00:00 2001 From: Andras Bacsai Date: Fri, 13 Sep 2024 12:47:46 +0200 Subject: [PATCH] chore: Update .env file and docker-compose configuration --- other/nightly/.env.development.example | 23 +++++++++++++++-------- other/nightly/docker-compose.prod.yml | 8 +++++++- other/nightly/docker-compose.yml | 1 - other/nightly/install.sh | 6 +++++- other/nightly/upgrade.sh | 1 - other/nightly/versions.json | 9 ++++++--- 6 files changed, 33 insertions(+), 15 deletions(-) diff --git a/other/nightly/.env.development.example b/other/nightly/.env.development.example index f9bcd361a0..3023a21a68 100644 --- a/other/nightly/.env.development.example +++ b/other/nightly/.env.development.example @@ -6,13 +6,7 @@ APP_KEY= APP_URL=http://localhost APP_PORT=8000 APP_DEBUG=true -MUX_ENABLED=false - -# Enable Laravel Telescope for debugging -TELESCOPE_ENABLED=false - -# Selenium Driver URL for Dusk -DUSK_DRIVER_URL=http://selenium:4444 +SSH_MUX_ENABLED=false # PostgreSQL Database Configuration DB_DATABASE=coolify @@ -21,9 +15,22 @@ DB_PASSWORD=password DB_HOST=host.docker.internal DB_PORT=5432 -#Set custom ray port +# Ray Configuration +# Set to true to enable Ray +RAY_ENABLED=false +# Set custom ray port RAY_PORT= +# Clockwork Configuration +CLOCKWORK_ENABLED=false +CLOCKWORK_QUEUE_COLLECT=true + +# Enable Laravel Telescope for debugging +TELESCOPE_ENABLED=false + +# Selenium Driver URL for Dusk +DUSK_DRIVER_URL=http://selenium:4444 + # Special Keys for Andras # For cache purging BUNNY_API_KEY= diff --git a/other/nightly/docker-compose.prod.yml b/other/nightly/docker-compose.prod.yml index b26cd57467..ffcfadead3 100644 --- a/other/nightly/docker-compose.prod.yml +++ b/other/nightly/docker-compose.prod.yml @@ -48,6 +48,7 @@ services: - PUSHER_APP_SECRET - AUTOUPDATE - SELF_HOSTED + - SSH_MUX_ENABLED - SSH_MUX_PERSIST_TIME - FEEDBACK_DISCORD_WEBHOOK - WAITLIST @@ -109,18 +110,23 @@ services: retries: 10 timeout: 2s soketi: + image: 'ghcr.io/coollabsio/coolify-realtime:latest' ports: - "${SOKETI_PORT:-6001}:6001" + - "6002:6002" + volumes: + - ./storage:/var/www/html/storage environment: SOKETI_DEBUG: "${SOKETI_DEBUG:-false}" SOKETI_DEFAULT_APP_ID: "${PUSHER_APP_ID}" SOKETI_DEFAULT_APP_KEY: "${PUSHER_APP_KEY}" SOKETI_DEFAULT_APP_SECRET: "${PUSHER_APP_SECRET}" healthcheck: - test: wget -qO- http://127.0.0.1:6001/ready || exit 1 + test: ["CMD-SHELL", "wget -qO- http://127.0.0.1:6001/ready && wget -qO- http://127.0.0.1:6002/ready || exit 1"] interval: 5s retries: 10 timeout: 2s + volumes: coolify-db: name: coolify-db diff --git a/other/nightly/docker-compose.yml b/other/nightly/docker-compose.yml index 930c0a6b93..7d71ba8e12 100644 --- a/other/nightly/docker-compose.yml +++ b/other/nightly/docker-compose.yml @@ -24,7 +24,6 @@ services: networks: - coolify soketi: - image: 'quay.io/soketi/soketi:1.6-16-alpine' container_name: coolify-realtime restart: always networks: diff --git a/other/nightly/install.sh b/other/nightly/install.sh index 23c2efc6fb..b1fe8e80a1 100755 --- a/other/nightly/install.sh +++ b/other/nightly/install.sh @@ -340,7 +340,6 @@ curl -fsSL $CDN/upgrade.sh -o /data/coolify/source/upgrade.sh # Copy .env.example if .env does not exist if [ -f $ENV_FILE ]; then echo "File exists: $ENV_FILE" - cat $ENV_FILE echo "Copying .env to .env-$DATE" cp $ENV_FILE $ENV_FILE-$DATE else @@ -366,6 +365,7 @@ else fi # Merge .env and .env.production. New values will be added to .env +echo "Updating .env with new values (if necessary)..." awk -F '=' '!seen[$1]++' "$ENV_FILE-$DATE" /data/coolify/source/.env.production > $ENV_FILE if [ "$AUTOUPDATE" = "false" ]; then @@ -405,3 +405,7 @@ echo "Waiting for 20 seconds for Coolify to be ready..." sleep 20 echo "Please visit http://$(curl -4s https://ifconfig.io):8000 to get started." echo -e "\nCongratulations! Your Coolify instance is ready to use.\n" + +echo -e "Make sure you backup your /data/coolify/source/.env file to a safe location, outside of this server.\n" +cp /data/coolify/source/.env /data/coolify/source/.env.backup +echo -e "Your .env file has been copied to /data/coolify/source/.env.backup\n" diff --git a/other/nightly/upgrade.sh b/other/nightly/upgrade.sh index 45295a5106..9aa3a5f9ae 100644 --- a/other/nightly/upgrade.sh +++ b/other/nightly/upgrade.sh @@ -12,7 +12,6 @@ curl -fsSL $CDN/.env.production -o /data/coolify/source/.env.production # Merge .env and .env.production. New values will be added to .env awk -F '=' '!seen[$1]++' /data/coolify/source/.env /data/coolify/source/.env.production > /data/coolify/source/.env.tmp && mv /data/coolify/source/.env.tmp /data/coolify/source/.env - # Check if PUSHER_APP_ID or PUSHER_APP_KEY or PUSHER_APP_SECRET is empty in /data/coolify/source/.env if grep -q "PUSHER_APP_ID=$" /data/coolify/source/.env; then sed -i "s|PUSHER_APP_ID=.*|PUSHER_APP_ID=$(openssl rand -hex 32)|g" /data/coolify/source/.env diff --git a/other/nightly/versions.json b/other/nightly/versions.json index 7bb400bfd9..966c2aa339 100644 --- a/other/nightly/versions.json +++ b/other/nightly/versions.json @@ -1,13 +1,16 @@ { "coolify": { "v4": { - "version": "4.0.0-beta.330" + "version": "4.0.0-beta.336" }, "nightly": { - "version": "4.0.0-beta.331" + "version": "4.0.0-beta.337" }, - "helper": { + "realtime": { "version": "1.0.0" + }, + "helper": { + "version": "1.0.1" } } }