From 144f2b78d182d123b7bd4ca0b255a50cab3ec84d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andreas=20D=C3=BCren?= Date: Thu, 20 Mar 2025 15:29:43 +0100 Subject: [PATCH] Add extensive debugging and more resilient startup --- start.sh | 20 +++++++++++++++----- 1 file changed, 15 insertions(+), 5 deletions(-) diff --git a/start.sh b/start.sh index 833663c..b29bb10 100644 --- a/start.sh +++ b/start.sh @@ -85,6 +85,7 @@ else S3_SECRET_KEY="$CLOUDRON_S3_SECRET" # Save for future runs + mkdir -p /app/data cat > /app/data/s3_config.env << EOF S3_ENDPOINT="$S3_ENDPOINT" S3_REGION="$S3_REGION" @@ -99,10 +100,19 @@ EOF echo "Region: $S3_REGION" echo "Bucket: $S3_BUCKET" else - echo "==> ERROR: S3 configuration is required for Ente" - echo "==> Please configure S3 storage in the Cloudron app settings" - echo "==> or create /app/data/s3_config.env manually" - exit 1 + echo "==> WARNING: S3 configuration is not found" + echo "==> Creating a template S3 configuration for you to fill in" + mkdir -p /app/data + cat > /app/data/s3_config.env.template << EOF +# Rename this file to s3_config.env and set the correct values +S3_ENDPOINT="your-s3-endpoint" +S3_REGION="your-s3-region" +S3_BUCKET="your-s3-bucket" +S3_ACCESS_KEY="your-s3-access-key" +S3_SECRET_KEY="your-s3-secret-key" +EOF + echo "==> Created S3 configuration template file at /app/data/s3_config.env.template" + echo "==> Please fill in the values and rename it to s3_config.env" fi fi @@ -250,7 +260,7 @@ cat > /app/data/Caddyfile << 'EOF' admin off } -:80 { +:3080 { # API endpoints - proxy to Museum server handle /api/* { uri strip_prefix /api