Amplify Portal
The portal is a Vite SPA hosted on AWS Amplify
AWS Amplify — hosts the Vite portal SPA. This walkthrough deploys via manual zip upload (no Git connection required). . Terraform
HashiCorp Terraform — provisions all platform infrastructure through five modules in `terraform/`. can build and zip-deploy it automatically on apply, or you can deploy manually when deploy_amplify_on_apply=false.
URL reference
Section titled “URL reference”| Use case | URL | How to get it |
|---|---|---|
| curl / scripts / Postman | API Gateway | terraform -chdir=terraform output -raw api_url |
| Browser UI (portal) | Amplify app | terraform -chdir=terraform output -raw app_url |
The hosted portal receives VITE_API_URL at build time, pointing to the same API Gateway URL. No Git connection is required — deployment uses manual zip upload.
Automatic deploy on apply
Section titled “Automatic deploy on apply”When deploy_amplify_on_apply=true (default), a full terraform apply runs npm install, npm run build, and uploads web/dist/ to Amplify. Requires Node.js >= 20 on the machine running Terraform.
Manual deploy
Section titled “Manual deploy”If you skipped Amplify during apply or need to ship UI changes:
export AMPLIFY_APP_ID="$(terraform -chdir=terraform output -raw amplify_app_id)"export VITE_API_URL="$(terraform -chdir=terraform output -raw api_url)"export WEB_SOURCE_DIR="$(pwd)/web"./scripts/deploy-amplify.shRun from the demo repo root after a successful Terraform apply.
Build only (inspection)
Section titled “Build only (inspection)”cd webnpm installnpm run buildBuild output lands in web/dist/.
Run unit tests locally
Section titled “Run unit tests locally”cd web && npm install && npm testVerify portal access
Section titled “Verify portal access”terraform -chdir=terraform output -raw app_urlOpen the URL in a browser. You should see the station browser interface. See Portal verification and Portal Usage.
Next step
Section titled “Next step”Lock down API Gateway
Amazon API Gateway — REST API exposing `/catalog`, `/query`, and `/reprocess`. Browser CORS is locked to the Amplify hostname; CLI clients call the API Gateway URL directly. CORS with CORS Lockdown so the hosted portal can call the API.