Skip to content

staging#16

Closed
daveio wants to merge 20 commits intoproductionfrom
staging
Closed

staging#16
daveio wants to merge 20 commits intoproductionfrom
staging

Conversation

@daveio
Copy link
Member

@daveio daveio commented Feb 12, 2026

  • Bump @nuxt/eslint from 1.14.0 to 1.15.1 in the all-dependencies group
    Bumps the all-dependencies group with 1 update: @nuxt/eslint.

    Updates @nuxt/eslint from 1.14.0 to 1.15.1


    updated-dependencies:

    • dependency-name: "@nuxt/eslint"
      dependency-version: 1.15.1
      dependency-type: direct:production
      update-type: version-update:semver-minor
      dependency-group: all-dependencies
      ...

    Signed-off-by: dependabot[bot] support@github.com

  • 🚀 Implement multi-environment deployment and D1 configuration

    • Add GitHub Actions for staging, production, and PR previews.
    • Move D1 bindings to nuxt.config.ts using $env overrides.
    • Create wrangler.dev.jsonc for local development.
    • Update scripts to support environment-aware builds and migrations.
    • Update documentation for new deployment and database workflows.
    • Upgrade Bun to 1.3.9 and update various dev dependencies.

    Establish a robust CI/CD pipeline that handles database migrations and
    worker versioning. Moving D1 configuration to Nuxt's environment
    overrides prevents Nitro build conflicts while ensuring the correct
    database is bound per environment. The split wrangler configuration
    allows for clean local development without interfering with production
    build settings.

  • 📝 (README.md): reformat text and update section headings
    Wrap long lines of text and adjust whitespace to improve readability.
    Rename the database section for better consistency and update internal
    links to prevent broken references. These adjustments make the
    documentation easier to maintain and read across different platforms.

  • 📝 Simplify database section header in README
    Remove the emoji from the "D1 Database" header and update internal links.
    This ensures cleaner anchor navigation and consistent formatting
    throughout the documentation.

  • Fix deploy:staging
    Co-authored-by: Copilot 175728472+Copilot@users.noreply.github.com

  • Use env vars for db:migrate:*
    Co-authored-by: Copilot 175728472+Copilot@users.noreply.github.com

  • Remove typecast, it's only a warning
    Co-authored-by: Copilot 175728472+Copilot@users.noreply.github.com

  • Staging should build staging, duh
    Co-authored-by: Copilot 175728472+Copilot@users.noreply.github.com

  • Remove commented out config
    Co-authored-by: Copilot 175728472+Copilot@users.noreply.github.com

  • expand dev wrangler.jsonc

  • 🏗️ migrate deployment to Cloudflare Workers Builds
    Remove GitHub Actions deployment workflow and transition to Cloudflare
    Workers Builds for automated deployments. This change centralizes
    environment configuration into dedicated wrangler.jsonc and
    wrangler.staging.jsonc files, simplifying the CI/CD pipeline and
    reducing reliance on external secrets for database IDs. Migration
    scripts are updated to reference these config files directly for
    better reliability and developer experience. Documentation in
    AGENTS.md is updated to reflect the new workflow.

  • 🏗️ migrate deployment pipeline to Cloudflare Workers Builds
    Add HUMAN_INTERVENTION_REQUIRED.md for manual setup steps. Update
    README.md to reflect the new multi-worker architecture. Introduce
    environment-specific wrangler configuration files. Update
    worker-configuration.d.ts with the DB binding.

    The deployment strategy is shifted from GitHub Actions to Cloudflare
    Workers Builds to leverage native platform features and simplify the
    pipeline. Splitting staging and production into separate Workers
    improves isolation. Environment-specific wrangler configs ensure
    correct D1 bindings during migrations and builds.

  • 🔥 Remove HUMAN_INTERVENTION_REQUIRED.md
    Remove the manual intervention guide now that the Cloudflare worker
    reconfiguration and deployment pipeline setup are complete.

    The file was intended as a temporary checklist for manual steps required
    to transition to the new deployment workflow. Since these steps are
    finished, the documentation is no longer necessary.

  • 🔨 update and reorganize package scripts
    Add snapshot deployment commands and update staging deployment logic.
    Reorganize database, test, and utility scripts for better readability.
    Remove the obsolete deploy:nonprod script.

    The scripts are reorganized to improve developer experience and
    maintainability. New snapshot deployment commands are added to support
    versioned uploads, while the staging deployment is updated to perform
    a full deploy. Obsolete scripts are removed to reduce clutter and
    related commands are grouped together logically.

  • 📝 Update DaisyUI description in README
    Refine the language describing DaisyUI's open-source nature to be clearer
    and more professional. Replace the vague phrase "is it" with "is the full
    package" to improve the quality and readability of the documentation.

  • 🔧 add Node.js compatibility flags to wrangler configs
    Add nodejs_compat and no_nodejs_compat_v2 flags to wrangler.jsonc,
    wrangler.dev.jsonc, and wrangler.staging.jsonc.

    These flags enable Node.js API support within the Cloudflare Workers
    runtime. Including them ensures that the application has access to
    necessary Node.js polyfills while explicitly opting out of the v2
    compatibility mode to maintain environment stability.

  • 🏷️ Update worker configuration types
    Update generated types and add NodeJS.ProcessEnv definitions.

    Synchronize types with the latest Wrangler generation and include
    NodeJS.ProcessEnv mappings for Cloudflare bindings. This enables
    better type safety and autocompletion when using environment
    variables in Node.js compatibility mode.

dependabot bot and others added 20 commits February 10, 2026 14:10
Bumps the all-dependencies group with 1 update: [@nuxt/eslint](https://github.com/nuxt/eslint/tree/HEAD/packages/module).


Updates `@nuxt/eslint` from 1.14.0 to 1.15.1
- [Release notes](https://github.com/nuxt/eslint/releases)
- [Commits](https://github.com/nuxt/eslint/commits/v1.15.1/packages/module)

---
updated-dependencies:
- dependency-name: "@nuxt/eslint"
  dependency-version: 1.15.1
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: all-dependencies
...

Signed-off-by: dependabot[bot] <support@github.com>
- Add GitHub Actions for staging, production, and PR previews.
- Move D1 bindings to `nuxt.config.ts` using `$env` overrides.
- Create `wrangler.dev.jsonc` for local development.
- Update scripts to support environment-aware builds and migrations.
- Update documentation for new deployment and database workflows.
- Upgrade Bun to 1.3.9 and update various dev dependencies.

Establish a robust CI/CD pipeline that handles database migrations and
worker versioning. Moving D1 configuration to Nuxt's environment
overrides prevents Nitro build conflicts while ensuring the correct
database is bound per environment. The split wrangler configuration
allows for clean local development without interfering with production
build settings.
Wrap long lines of text and adjust whitespace to improve readability.
Rename the database section for better consistency and update internal
links to prevent broken references. These adjustments make the
documentation easier to maintain and read across different platforms.
Remove the emoji from the "D1 Database" header and update internal links.
This ensures cleaner anchor navigation and consistent formatting
throughout the documentation.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
…ronment

🚀 Implement multi-environment deployment and D1 configuration, fixes #13
Remove GitHub Actions deployment workflow and transition to Cloudflare
Workers Builds for automated deployments. This change centralizes
environment configuration into dedicated wrangler.jsonc and
wrangler.staging.jsonc files, simplifying the CI/CD pipeline and
reducing reliance on external secrets for database IDs. Migration
scripts are updated to reference these config files directly for
better reliability and developer experience. Documentation in
AGENTS.md is updated to reflect the new workflow.
Add HUMAN_INTERVENTION_REQUIRED.md for manual setup steps. Update
README.md to reflect the new multi-worker architecture. Introduce
environment-specific wrangler configuration files. Update
worker-configuration.d.ts with the DB binding.

The deployment strategy is shifted from GitHub Actions to Cloudflare
Workers Builds to leverage native platform features and simplify the
pipeline. Splitting staging and production into separate Workers
improves isolation. Environment-specific wrangler configs ensure
correct D1 bindings during migrations and builds.
Remove the manual intervention guide now that the Cloudflare worker
reconfiguration and deployment pipeline setup are complete.

The file was intended as a temporary checklist for manual steps required
to transition to the new deployment workflow. Since these steps are
finished, the documentation is no longer necessary.
Add snapshot deployment commands and update staging deployment logic.
Reorganize database, test, and utility scripts for better readability.
Remove the obsolete deploy:nonprod script.

The scripts are reorganized to improve developer experience and
maintainability. New snapshot deployment commands are added to support
versioned uploads, while the staging deployment is updated to perform
a full deploy. Obsolete scripts are removed to reduce clutter and
related commands are grouped together logically.
Refine the language describing DaisyUI's open-source nature to be clearer
and more professional. Replace the vague phrase "is it" with "is the full
package" to improve the quality and readability of the documentation.
Add nodejs_compat and no_nodejs_compat_v2 flags to wrangler.jsonc,
wrangler.dev.jsonc, and wrangler.staging.jsonc.

These flags enable Node.js API support within the Cloudflare Workers
runtime. Including them ensures that the application has access to
necessary Node.js polyfills while explicitly opting out of the v2
compatibility mode to maintain environment stability.
Update generated types and add NodeJS.ProcessEnv definitions.

Synchronize types with the latest Wrangler generation and include
NodeJS.ProcessEnv mappings for Cloudflare bindings. This enables
better type safety and autocompletion when using environment
variables in Node.js compatibility mode.
Copilot AI review requested due to automatic review settings February 12, 2026 23:59
@cloudflare-workers-and-pages
Copy link

cloudflare-workers-and-pages bot commented Feb 12, 2026

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Updated (UTC)
✅ Deployment successful!
View logs
affirm-staging 291d6c8 Feb 12 2026, 11:59 PM

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This pull request implements a multi-environment deployment strategy for the Affirm application, transitioning from a single-environment setup to separate staging and production Workers with dedicated D1 databases. The PR includes dependency updates (@nuxt/eslint 1.14.0→1.15.1, vue 3.5.27→3.5.28, and others), comprehensive environment-specific wrangler configurations, and updated documentation explaining the new deployment workflow.

Changes:

  • Establish separate staging and production Cloudflare Workers with dedicated wrangler config files
  • Configure environment-specific D1 database bindings using Nuxt's $env overrides mechanism
  • Reorganize and expand package.json scripts to support environment-aware builds and database migrations
  • Update documentation to reflect the Cloudflare Workers Builds deployment strategy
  • Update development dependencies and tooling versions

Reviewed changes

Copilot reviewed 9 out of 11 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
wrangler.jsonc Moved D1 binding to end of file, added Node.js compatibility flags
wrangler.staging.jsonc New staging environment configuration for affirm-staging Worker
wrangler.dev.jsonc New local development configuration with local-dev database ID
nuxt.config.ts Added $env production/staging overrides with D1 bindings, configured cloudflareDev path
package.json Updated dependencies, reorganized scripts for multi-environment support
worker-configuration.d.ts Generated types update with NodeJS.ProcessEnv mappings for environment variables
README.md Comprehensive documentation updates for deployment workflow and database configuration
AGENTS.md Updated agent guide with multi-environment deployment instructions
bun.lock Lockfile updates matching package.json dependency changes
.github/workflows/ci.yaml Updated Bun version from 1.3.8 to 1.3.9
.trunk/trunk.yaml Updated linter versions (checkov, trufflehog)

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

"deploy:snapshot": "bun run-s build:staging deploy:snapshot:wrangler",
"deploy:snapshot:wrangler": "bun run wrangler versions upload -c wrangler.staging.jsonc",
"deploy:staging": "bun run-s build:staging deploy:staging:wrangler",
"deploy:staging:wrangler": "bun run wrangler deploy -c wrangler.staging.jsonc",
Copy link

Copilot AI Feb 13, 2026

Choose a reason for hiding this comment

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

The README documentation states that the staging Worker deployment uses wrangler versions upload (line 258 and line 277), but the actual deploy:staging:wrangler script uses wrangler deploy. This creates a mismatch between documented behavior and actual implementation.

Should staging deployments use wrangler deploy (immediate traffic) or wrangler versions upload (gradual rollout)? The deploy:snapshot script exists for version uploads, suggesting deploy:staging should match the documented behavior and use versions upload instead.

Copilot uses AI. Check for mistakes.
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.

1 participant