fix: ENVIRONMENT.md documents contracts.env with VITE_ prefixes that do not match the actual file (#386)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
openhands 2026-03-03 01:21:48 +00:00
parent afcf13bc84
commit 47174c3dfe

View file

@ -86,14 +86,23 @@ For testing login: `lobsterDao`, `test123`, `lobster-x010syqe?412!`
| Variable | Default | Set in docker-compose | Purpose | | Variable | Default | Set in docker-compose | Purpose |
|---|---|---|---| |---|---|---|---|
| `VITE_ENABLE_LOCAL_SWAP` | `false` (unset) | `true` | Show inline ETH→$KRK swap widget on Get KRK page instead of the Uniswap link. Enable for local dev; leave unset for production builds. | | `VITE_ENABLE_LOCAL_SWAP` | `false` (unset) | `true` | Show inline ETH→$KRK swap widget on Get KRK page instead of the Uniswap link. Enable for local dev; leave unset for production builds. |
| `VITE_KRAIKEN_ADDRESS` | from `deployments-local.json` | via `contracts.env` | Override KRK token address. | | `VITE_KRAIKEN_ADDRESS` | from `deployments-local.json` | via `contracts.env` + entrypoint | Override KRK token address. |
| `VITE_STAKE_ADDRESS` | from `deployments-local.json` | via `contracts.env` | Override Stake contract address. | | `VITE_STAKE_ADDRESS` | from `deployments-local.json` | via `contracts.env` + entrypoint | Override Stake contract address. |
| `VITE_DEFAULT_CHAIN_ID` | auto-detected (31337 on localhost) | — | Force the default chain. | | `VITE_DEFAULT_CHAIN_ID` | auto-detected (31337 on localhost) | — | Force the default chain. |
## Contract Addresses ## Contract Addresses
After bootstrap, addresses are in `/home/debian/harb/tmp/containers/contracts.env`. After bootstrap, addresses are written to `/home/debian/harb/tmp/containers/contracts.env` with the following variable names (no `VITE_` prefix):
Landing sources this file on startup for `VITE_KRAIKEN_ADDRESS` and `VITE_STAKE_ADDRESS`.
```
LIQUIDITY_MANAGER=0x...
KRAIKEN=0x...
STAKE=0x...
```
The entrypoint scripts read this file and re-export the addresses with `VITE_` prefixes for Vite builds:
- `containers/landing-entrypoint.sh` exports `VITE_KRAIKEN_ADDRESS` and `VITE_STAKE_ADDRESS`
- `containers/webapp-entrypoint.sh` exports `VITE_KRAIKEN_ADDRESS` and `VITE_STAKE_ADDRESS`
## E2E Test Environment Variables ## E2E Test Environment Variables