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
Polish DEPLOY.md: fix missing vars and clarify infra vs space
- Add POSTGATE_SYSTEM_TOKEN_SECRET, ASSETS binding to env table
- Fix variable types (GITHUB_CLIENT_ID as var, not secret)
- Separate Docker-mode vars (POSTGATE_URL/TOKEN) into own table
- Clarify infra (direct DB) vs space (via API) distinction
- Promote env vars section to top level
ow infra env bind openworkers-api-env ASSETS openworkers-api-storage --type assets
55
55
56
-
# Set variables and secrets
56
+
# Set variables and secrets (see environment variables table below)
57
57
ow infra env set openworkers-api-env APP_URL https://dash.example.com
58
+
ow infra env set openworkers-api-env POSTGATE_SYSTEM_TOKEN_SECRET --secret
58
59
ow infra env set openworkers-api-env JWT_ACCESS_SECRET --secret
59
60
ow infra env set openworkers-api-env JWT_REFRESH_SECRET --secret
60
-
# ... (see environment variables table below)
61
61
62
62
# Build and upload
63
63
cd openworkers-api
@@ -81,18 +81,18 @@ ow infra worker upload openworkers-dash ./dist/openworkers
81
81
82
82
## Worker mode (subsequent deploys)
83
83
84
-
Build then upload as a worker:
84
+
Once the platform is running, use a **space alias** (goes through the API) for subsequent deploys:
85
85
86
86
```bash
87
87
bun run build
88
88
ow <space> worker upload openworkers-api ./build
89
89
```
90
90
91
-
Where `<space>` is the target namespace (`dev`, `infra`, `main`, `ps`, ...).
91
+
Where `<space>` is the target space (`dev`, `main`, `ps`, ...).
92
92
93
93
Create the environment **before** the first upload so the project inherits it automatically. If the worker was already uploaded without an environment, `worker link` will cascade it to the project and all function workers.
94
94
95
-
###Environment variables
95
+
## Environment variables
96
96
97
97
Secrets are prompted interactively (masked input) when value is omitted:
|`MISTRAL_API_KEY`| secret | no | Mistral AI API key |
116
-
|`ANTHROPIC_API_KEY`| secret | no | Anthropic API key |
117
-
|`SHARED_STORAGE_BUCKET`| secret | no | S3 bucket name |
118
-
|`SHARED_STORAGE_ENDPOINT`| secret | no | S3 endpoint URL |
119
-
|`SHARED_STORAGE_ACCESS_KEY_ID`| secret | no | S3 access key |
120
-
|`SHARED_STORAGE_SECRET_ACCESS_KEY`| secret | no | S3 secret key |
121
-
|`SHARED_STORAGE_PUBLIC_URL`| var | no | S3 public URL |
122
-
|`EMAIL_PROVIDER`| var | no | Email provider (e.g. `scaleway`) |
123
-
|`EMAIL_FROM`| var | no | Sender email address |
124
-
|`SCW_SECRET_KEY`| secret | no | Scaleway secret key |
125
-
|`SCW_PROJECT_ID`| secret | no | Scaleway project ID |
126
-
|`SCW_REGION`| var | no | Scaleway region |
127
-
128
-
Note: `POSTGATE_URL` and `POSTGATE_TOKEN` are only needed when running outside OpenWorkers (Docker mode). In worker mode, the `DATABASE` binding provides direct database access.
|`MISTRAL_API_KEY`| secret | no | Mistral AI API key |
118
+
|`ANTHROPIC_API_KEY`| secret | no | Anthropic API key |
119
+
|`SHARED_STORAGE_BUCKET`| var | no | S3 bucket name |
120
+
|`SHARED_STORAGE_ENDPOINT`| var | no | S3 endpoint URL |
121
+
|`SHARED_STORAGE_ACCESS_KEY_ID`| secret | no | S3 access key |
122
+
|`SHARED_STORAGE_SECRET_ACCESS_KEY`| secret | no | S3 secret key |
123
+
|`SHARED_STORAGE_PUBLIC_URL`| var | no | S3 public URL |
124
+
|`EMAIL_PROVIDER`| var | no | Email provider (e.g. `scaleway`) |
125
+
|`EMAIL_FROM`| var | no | Sender email address |
126
+
|`SCW_SECRET_KEY`| secret | no | Scaleway secret key |
127
+
|`SCW_PROJECT_ID`| var | no | Scaleway project ID |
128
+
|`SCW_REGION`| var | no | Scaleway region |
129
+
130
+
In worker mode, the `DATABASE` binding provides direct database access. `POSTGATE_URL` and `POSTGATE_TOKEN` are only needed in Docker mode (see below).
129
131
130
132
## Docker mode
131
133
@@ -143,7 +145,14 @@ bun start
143
145
144
146
The server listens on `PORT` (default `7000`).
145
147
146
-
In Docker mode, set `POSTGATE_URL` and `POSTGATE_TOKEN` in `.env` instead of the `DB` binding.
148
+
In Docker mode, there is no `DATABASE` binding. Set these additional variables in `.env`:
0 commit comments