OpenPanel is an open-source web and product analytics platform, an open-source alternative to Mixpanel with optional self-hosting.
fix(dashboard): dockerfile + other self-hosting issues
Carl-Gerhard Lindesvärd1cfd7e7e1b70
diff --git a/apps/dashboard/Dockerfile b/apps/dashboard/Dockerfileindex 8fc570d79..2ce4936ae 100644--- a/apps/dashboard/Dockerfile+++ b/apps/dashboard/Dockerfile@@ -41,6 +41,7 @@ COPY packages/common/package.json packages/common/package.jsonCOPY packages/auth/package.json packages/auth/package.jsonCOPY packages/email/package.json packages/email/package.jsonCOPY packages/constants/package.json packages/constants/package.json+COPY packages/payments/package.json packages/payments/package.jsonCOPY packages/validation/package.json packages/validation/package.jsonCOPY packages/integrations/package.json packages/integrations/package.jsonCOPY packages/sdks/sdk/package.json packages/sdks/sdk/package.jsondiff --git a/self-hosting/update b/self-hosting/updateindex c00736fa6..af21ba433 100755--- a/self-hosting/update+++ b/self-hosting/update@@ -6,6 +6,6 @@ echo "Pulling latest docker images"docker compose pullecho "Restarting services"-docker compose restart+docker compose up -d --remove-orphansecho "Done"diff --git a/sh/docker-build b/sh/docker-buildindex b46ec17d4..9e28310a5 100755--- a/sh/docker-build+++ b/sh/docker-build@@ -38,34 +38,36 @@ docker buildx create --name multi-arch-builder --use || truebuild_image() {local app=$1local image_name="lindesvard/openpanel-$app"--- # Prepare tags based on whether PRERELEASE is provided- if [ -z "$PRERELEASE" ]; then- echo "Building multi-architecture image for $image_name:$VERSION"+ local full_version="$image_name:$VERSION"++ if [ -n "$PRERELEASE" ]; then+ full_version="$full_version-$PRERELEASE"+ echo "(pre-release) Building multi-architecture image for $full_version"docker buildx build \--platform linux/amd64,linux/arm64 \- -t "$image_name:$VERSION" \- -t "$image_name:latest" \+ -t "$full_version" \--build-arg DATABASE_URL="postgresql://p@p:5432/p" \-f "apps/$app/Dockerfile" \+ --push \.else- echo "Building multi-architecture image for $image_name:$VERSION-$PRERELEASE"+ echo "(latest) Building multi-architecture image for $full_version"docker buildx build \--platform linux/amd64,linux/arm64 \- -t "$image_name:$VERSION-$PRERELEASE" \+ -t "$full_version" \+ -t "$image_name:latest" \--build-arg DATABASE_URL="postgresql://p@p:5432/p" \-f "apps/$app/Dockerfile" \+ --push \.fiif [ $? -ne 0 ]; then- echo "Failed to build $image_name:$VERSION"+ echo "Failed to build $full_version"exit 1fi- echo "Successfully built and pushed multi-architecture image for $image_name:$VERSION"+ echo "Successfully built and pushed multi-architecture image for $full_version"}if [ "$APP" == "all" ]; then