env fix
This commit is contained in:
30
Dockerfile
30
Dockerfile
@@ -28,22 +28,26 @@ WORKDIR /app
|
||||
COPY --from=builder /app/server /app
|
||||
COPY nearle-gear-firebase-adminsdk-l9oha-23ca3b3609.json .
|
||||
|
||||
# The container's own configuration.
|
||||
# Nearle Buddy's credential, as ONE container variable.
|
||||
#
|
||||
# Copied in so the deployment does not depend on every variable having been
|
||||
# entered into a hosting platform's settings screen. A variable missed there is
|
||||
# a variable unset in production, and the failure is silent — the assistant sat
|
||||
# switched off for two days for exactly that reason, with nothing on any screen
|
||||
# saying which value was absent.
|
||||
# Not an env file. `COPY .env.production .` was tried on 2026-09-25 and took the
|
||||
# backend down with 502 on every endpoint: that file declares twenty-three
|
||||
# variables, and godotenv fills any the platform leaves unset, so a stale
|
||||
# committed DB or Redis value replaced a live one and the process died at boot.
|
||||
# Twenty-three variables shipped to deliver one.
|
||||
#
|
||||
# Anything the platform DOES set still wins: `godotenv` only fills variables
|
||||
# that are not already in the environment, so Dokploy can override any line in
|
||||
# this file without the file having to change.
|
||||
COPY .env.production .
|
||||
# A single ENV cannot do that — it sets this name and no other. A value set on
|
||||
# the platform still wins, because `docker run -e` overrides a Dockerfile ENV,
|
||||
# so this is a default rather than an override.
|
||||
#
|
||||
# Provider, endpoint and model are constants in config.go, so this is the only
|
||||
# thing the assistant needs to come up.
|
||||
ENV ASSISTANT_API_KEY=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
|
||||
|
||||
# Decides which rules config.Load applies — production insists on a signing
|
||||
# secret and never falls back to localhost values — and which file above is
|
||||
# read: loadEnvFiles reads `.env.<APP_ENV>` then `.env`.
|
||||
# No `.env.*` is copied in (see .dockerignore), so this only decides which rules
|
||||
# config.Load applies: production insists on a signing secret and never falls
|
||||
# back to localhost values. Every other real value comes from the platform's
|
||||
# environment settings, exactly as before.
|
||||
ENV APP_ENV=production
|
||||
|
||||
# Must match APP_PORT in the platform's environment (1009 in production).
|
||||
|
||||
Reference in New Issue
Block a user