Skip to content

feat. implement cloud run deployment for Express-Checkout - #396

Merged
pwei1018 merged 2 commits into
bcgov:mainfrom
pwei1018:feature-loadbalancer
Oct 22, 2026
Merged

pwei1018 merged 2 commits into
bcgov:mainfrom
pwei1018:feature-loadbalancer

Conversation

@pwei1018

Copy link
Copy Markdown
Collaborator

Issue #: bcgov/entity#35321

Description of changes:

This pull request introduces significant updates to the express-checkout application, focusing on modernizing the build and deployment pipeline, enhancing security and environment configuration, and upgrading dependencies for better maintainability and compatibility. The changes transition the project to Nuxt 4, update Docker and environment handling for production readiness, and improve security practices, especially around redirects and sensitive configuration.

Key changes include:

Build and Deployment Modernization

  • Migrated deployment workflows from Firebase to Google Cloud Platform (GCP).
  • Implemented stricter security headers and route rules in nuxt.config.ts, including SSR configuration and long-term caching for static assets. Content-Security-Policy is now managed at runtime via environment variables.
  • Introduced safe redirect utilities to prevent open redirects and unsafe URL handling, and refactored login logic to use these utilities.
  • Refactored environment variable usage for API URLs and keys, separating public and server-only values to enhance security and clarity.
  • Improved API composables to use absolute URLs and ensure requests are correctly routed through the server proxy, keeping sensitive keys on the server side.
  • Various small fixes and improvements, such as correcting default value handling in components, explicit imports for enums, and minor logic adjustments.

/^api\/v[12]\/payment-links\/[^/]+\/(transactions|receipts)$/,
/^api\/v[12]\/payment-requests\/\d+\/transactions\/[^/]+$/
]
const BEARER = /^Bearer \S+$/

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is Bear token might be null or undefined?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This validation only checks the format of the header. Literal values such as Bearer null or Bearer undefined would still match the pattern. If we need to reject those values, I can add additional validation logic or explicitly parse and validate the token.

@pwei1018
pwei1018 merged commit 6431e71 into bcgov:main Oct 22, 2026
14 of 15 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants