More docker and deploy updates

main
Antonio De Lucreziis 2 years ago
parent 2ef06720d7
commit 709805d722

@ -12,6 +12,7 @@ COPY . .
RUN go build -buildvcs=false -o storage-server -v . RUN go build -buildvcs=false -o storage-server -v .
FROM alpine:latest AS runner FROM alpine:latest AS runner
RUN apk add mdadm
WORKDIR /app WORKDIR /app
COPY --from=frontend-builder /frontend/dist ./_frontend/dist COPY --from=frontend-builder /frontend/dist ./_frontend/dist
COPY ./scripts ./scripts COPY ./scripts ./scripts

@ -54,7 +54,7 @@ func init() {
Mode = loadEnv("MODE", "development") Mode = loadEnv("MODE", "development")
Host = loadEnv("HOST", ":4000") Host = loadEnv("HOST", ":4000")
BaseURL = loadEnv("HOST", "http://localhost:4000") BaseURL = loadEnv("BASE_URL", "http://localhost:4000")
AdminPassword = loadEnv("ADMIN_PASSWORD", "secret") AdminPassword = loadEnv("ADMIN_PASSWORD", "secret")

@ -19,6 +19,8 @@ docker run -d \
--name "$CONTAINER_NAME" \ --name "$CONTAINER_NAME" \
--restart unless-stopped \ --restart unless-stopped \
-p "$HOST_PORT:4000" \ -p "$HOST_PORT:4000" \
-v /proc:/proc \
-v /dev:/dev \
-v "$(pwd)/buckets.local:/buckets" \ -v "$(pwd)/buckets.local:/buckets" \
-v "$(pwd)/database.local.json:/app/database.local.json" \ -v "$(pwd)/database.local.json:/app/database.local.json" \
"$IMAGE_NAME" "$IMAGE_NAME"

Loading…
Cancel
Save