Lets the test build present itself under its own address
VITE_SITE_URL sets the origin used for canonical, og:url, og:image, JSON-LD and the sitemap. Only the test build sets it (https://test.andreaslop.nl); the production artifact keeps https://andreaslop.nl. Only a clean https origin (or http on localhost) is accepted, anything else falls back to production. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -40,10 +40,11 @@ Both follow the same rules as the packages: baked into the HTML at build time, r
|
||||
|
||||
## Environment and variables
|
||||
|
||||
| Name | Where | Meaning |
|
||||
| ------------------------ | ------------------- | ------------------------------------------------------------------------------------------------------ |
|
||||
| `OFFERINGS_URL` | build env | Site address that serves the API (for example `https://test.andreaslop.nl`). Unset gives the snapshot. |
|
||||
| `ASF_OFFERINGS_URL_TEST` | Gitea repo variable | Value of `OFFERINGS_URL` for the test build. Set by SLS, not by feature sessions. |
|
||||
| `API_PROXY_TARGET` | dev env | Forwards `/api` in `pnpm dev` to a CMS host. |
|
||||
| Name | Where | Meaning |
|
||||
| ------------------------ | ------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||
| `OFFERINGS_URL` | build env | Site address that serves the API (for example `https://test.andreaslop.nl`). Unset gives the snapshot. |
|
||||
| `ASF_OFFERINGS_URL_TEST` | Gitea repo variable | Value of `OFFERINGS_URL` for the test build. Set by SLS, not by feature sessions. |
|
||||
| `API_PROXY_TARGET` | dev env | Forwards `/api` in `pnpm dev` to a CMS host. |
|
||||
| `VITE_SITE_URL` | build env | Address the site presents itself under (canonical, og:*, JSON-LD, sitemap). Only the test build sets it (`https://test.andreaslop.nl`); unset gives `https://andreaslop.nl`. |
|
||||
|
||||
The production artifact is built without `OFFERINGS_URL` on purpose: production must never carry the prices of the test CMS.
|
||||
|
||||
Reference in New Issue
Block a user