You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The Docker image runs from `/app`. With the default compose mount below, the backend reads `/app/config.yaml` automatically:
115
+
116
+
```yaml
117
+
volumes:
118
+
- ./config.yaml:/app/config.yaml:ro
119
+
```
120
+
121
+
To use a different file path, set `CONFIG_FILE` to the container path:
122
+
123
+
```yaml
124
+
environment:
125
+
CONFIG_FILE: "/app/config.yaml"
126
+
```
127
+
128
+
Custom config file paths are read from `CONFIG_FILE`. If both compose environment variables and `config.yaml` define the same key, the environment variable wins. In `docker-compose.full.yml`, `POSTGRES_DSN`, `REDIS_ADDR`, and `REDIS_PASSWORD` are set in `environment`, so they override the PostgreSQL and Redis values in `config.yaml`.
129
+
130
+
`config.yaml`is for static infrastructure and security configuration such as server URLs, database, Redis, storage, GeoIP, tracing, JWT, and encryption keys. Runtime business settings are stored in the database and managed in the admin console, so changing those values in YAML after startup is not the source of truth.
131
+
114
132
`APP_ENV`accepts `dev`/`development` and `prod`/`production`, normalizes them to `dev` or `prod`, and defaults to `prod` when omitted. Use `dev` only for local development. Public production deployments should keep `APP_ENV=prod` or `APP_ENV=production` and use production secrets.
This mode primarily uses `config.yaml`; keep compose `environment` empty unless you intentionally want an environment variable to override the file.
145
+
126
146
#### Full Stack Start
127
147
128
148
Starts `app`, `postgres`, and `redis`. Use this for local evaluation, development smoke tests, or single-machine deployments without external services.
This mode uses compose environment variables for the bundled PostgreSQL and Redis services. Edit `docker-compose.full.yml` or remove those environment entries if you want `config.yaml` to provide these connection values instead.
156
+
135
157
The default application image is `ghcr.io/deeix-ai/deeix-chat:latest`. Override it with `DEEIX_CHAT_IMAGE` when testing a custom build:
136
158
137
159
```bash
@@ -140,6 +162,13 @@ DEEIX_CHAT_IMAGE=deeix-chat:local docker compose up -d --build
140
162
141
163
Docker URL: `http://localhost:8080`. Keep the Docker `server` section unchanged unless changing ports or public domains; then update compose ports, public URLs, and CORS together.
142
164
165
+
For troubleshooting, inspect startup logs and verify that the mounted file exists inside the container:
166
+
167
+
```bash
168
+
docker compose exec app ls -l /app/config.yaml
169
+
docker compose logs app
170
+
```
171
+
143
172
#### Separated Deployment
144
173
145
174
Use this mode when the frontend and backend are served from different public origins, for example `https://chat.example.com` and `https://api.example.com`.
@@ -221,6 +250,8 @@ pnpm build
221
250
222
251
Static infrastructure configuration is loaded from the repository-level `config.yaml` and can be overridden by environment variables. Runtime business settings are stored in `system_settings` and managed from the admin console.
223
252
253
+
Docker deployments read `/app/config.yaml` by default when `./config.yaml` is mounted to `/app/config.yaml`. `CONFIG_FILE` can point to another container path.
254
+
224
255
Frontend build-time variables:
225
256
226
257
| Variable | Purpose |
@@ -232,6 +263,7 @@ Common backend environment variables:
232
263
| Variable | Purpose |
233
264
| --- | --- |
234
265
| `APP_ENV` | Runtime environment. Accepts `dev`/`development` and `prod`/`production`; omitted values default to `prod`. |
266
+
| `CONFIG_FILE` | Optional custom config file path inside the running process or container. Docker defaults to `/app/config.yaml` through the working directory and compose mount. |
235
267
| `HTTP_PORT` | API/runtime port. |
236
268
| `JWT_SECRET` | JWT signing secret. Must be strong in production. |
237
269
| `DATA_ENCRYPTION_KEY` | Key material for encrypted secrets such as upstream API keys, SSO client secrets, MCP tokens, and TOTP secrets. |
0 commit comments