Skip to content

Speed up AWS deployment workflows by removing duplicate frontend build and slimming backend security scan#4

Draft
Copilot wants to merge 4 commits into
mainfrom
copilot/check-github-actions-deployment
Draft

Speed up AWS deployment workflows by removing duplicate frontend build and slimming backend security scan#4
Copilot wants to merge 4 commits into
mainfrom
copilot/check-github-actions-deployment

Conversation

Copy link
Copy Markdown

Copilot AI commented Feb 24, 2026

Deployment workflows were spending avoidable time on repeated work: frontend rebuilt in the deploy job after already building in pre-deploy checks, and backend security scan installed heavy native/runtime deps before auditing. This change reduces end-to-end deploy latency by reusing artifacts and trimming expensive setup in the security path.

  • Frontend: reuse verified build output in deploy

    • deploy-frontend-aws.yml now deploys from the Build Verification artifact instead of reinstalling Node deps and running next build again.
    • Added explicit artifact download path and integrity checks (frontend-build/out, frontend-build/out/index.html) before S3 sync.
    • Artifact upload is narrowed to static export output (frontend/out) used by deployment.
  • Backend: faster vulnerability audit path

    • deploy-backend-aws.yml removes OS-level native package installation from Security Scan.
    • Replaced full dependency install + audit with requirements-based audit:
      • pip-audit -r requirements.txt
    • Added inline note documenting tradeoff (faster CI, potentially less transitive coverage than auditing a fully installed env).
  • Operational effect

    • Frontend deploy job no longer duplicates install/build work.
    • Backend security stage avoids costly native/toolchain setup.
# frontend deploy job
- uses: actions/download-artifact@v4
  with:
    name: frontend-build
    path: frontend-build

- name: Verify build artifact
  run: |
    test -d frontend-build/out
    test -f frontend-build/out/index.html
Original prompt

check GitHub actions deployment, how can it be sped up? suggest improvements


🔒 GitHub Advanced Security automatically protects Copilot coding agent pull requests. You can protect all pull requests by enabling Advanced Security for your repositories. Learn more about Advanced Security.

Copilot AI and others added 3 commits February 24, 2026 08:36
Co-authored-by: owenisas <74884300+owenisas@users.noreply.github.com>
Co-authored-by: owenisas <74884300+owenisas@users.noreply.github.com>
Co-authored-by: owenisas <74884300+owenisas@users.noreply.github.com>
Copilot AI changed the title [WIP] Analyze and suggest improvements for GitHub Actions deployment Speed up AWS deployment workflows by removing duplicate frontend build and slimming backend security scan Feb 24, 2026
Copilot AI requested a review from owenisas February 24, 2026 08:42
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.

2 participants