Skip to content

Commit

Permalink
hot-fix: dashboard deployment configs
Browse files Browse the repository at this point in the history
  • Loading branch information
danh91 committed Jul 22, 2024
1 parent 48c487d commit 4170745
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 17 deletions.
10 changes: 5 additions & 5 deletions docker/dashboard/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,13 @@ FROM node:21.2.0-alpine3.17 AS runner
ARG VERSION
WORKDIR /app

ENV NODE_ENV production
ENV NEXT_TELEMETRY_DISABLED 1
ENV SENTRY_IGNORE_API_RESOLUTION_ERROR 1
ENV NODE_ENV production
ENV JWT_SECRET "nasdlfij34l5kj5k6j5kl6lp+lsick5bi*90!mbk7rc3iy_op1r"
ENV KARRIO_PUBLIC_URL https://api.karrio.io
ENV DASHBOARD_URL http://localhost:3000
ENV DASHBOARD_VERSION ${VERSION}
ENV NEXTAUTH_SECRET "nasdlfij34l5kj5k6j5kl6lp+lsick5bi*90!mbk7rc3iy_op1r"
ENV NEXT_PUBLIC_KARRIO_PUBLIC_URL https://api.karrio.io
ENV NEXT_PUBLIC_DASHBOARD_URL http://localhost:3000
ENV NEXT_PUBLIC_DASHBOARD_VERSION ${VERSION}

RUN addgroup -g 1001 -S nodejs
RUN adduser -S karrio -u 1001
Expand Down
6 changes: 1 addition & 5 deletions docker/dashboard/entrypoint
Original file line number Diff line number Diff line change
@@ -1,11 +1,7 @@
#!/bin/bash

# Setup environment variables
export NEXTAUTH_SECRET=${NEXTAUTH_SECRET:=$JWT_SECRET}
export NEXTAUTH_URL=${NEXTAUTH_URL:=$DASHBOARD_URL}
export NEXT_PUBLIC_DASHBOARD_URL=${NEXT_PUBLIC_DASHBOARD_URL:=$DASHBOARD_URL}
export NEXT_PUBLIC_DASHBOARD_VERSION=${NEXT_PUBLIC_DASHBOARD_VERSION:=$DASHBOARD_VERSION}
export NEXT_PUBLIC_KARRIO_PUBLIC_URL=${NEXT_PUBLIC_KARRIO_PUBLIC_URL:=$KARRIO_PUBLIC_URL}
export NEXTAUTH_URL=${NEXTAUTH_URL:=$NEXT_PUBLIC_DASHBOARD_URL}

# Start services
set -e
Expand Down
6 changes: 3 additions & 3 deletions docker/docker-compose.hobby.yml
Original file line number Diff line number Diff line change
Expand Up @@ -54,9 +54,9 @@ services:
depends_on:
- api
environment:
JWT_SECRET: ${JWT_SECRET}
DASHBOARD_URL: ${DASHBOARD_URL}
KARRIO_PUBLIC_URL: ${KARRIO_PUBLIC_URL}
NEXTAUTH_SECRET: ${JWT_SECRET}
NEXT_PUBLIC_DASHBOARD_URL: ${DASHBOARD_URL}
NEXT_PUBLIC_KARRIO_PUBLIC_URL: ${KARRIO_PUBLIC_URL}

caddy:
container_name: karrio.caddy
Expand Down
8 changes: 4 additions & 4 deletions docker/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,17 +46,17 @@ services:

dashboard:
container_name: karrio.dashboard
image: karrio.docker.scarf.sh/karrio/dashboard:2024.6-rc12
image: karrio/dashboard:2024.6-rc13
restart: unless-stopped
ports:
- ${DASHBOARD_PORT}:3000/tcp
depends_on:
- api
environment:
JWT_SECRET: ${JWT_SECRET}
KARRIO_URL: http://api:${KARRIO_HTTP_PORT:-5002}
DASHBOARD_URL: ${DASHBOARD_URL}
KARRIO_PUBLIC_URL: ${KARRIO_PUBLIC_URL}
NEXTAUTH_SECRET: ${JWT_SECRET}
NEXT_PUBLIC_DASHBOARD_URL: ${DASHBOARD_URL}
NEXT_PUBLIC_KARRIO_PUBLIC_URL: ${KARRIO_PUBLIC_URL}

maildev:
container_name: karrio.mail
Expand Down

0 comments on commit 4170745

Please sign in to comment.