Skip to content

ci: introduce full-stack GitHub Actions for Next.js frontend and Docker infrastructure#34

Open
chinmayy777 wants to merge 2 commits intoOSIPI:mainfrom
chinmayy777:ci/frontend-docker-pipeline
Open

ci: introduce full-stack GitHub Actions for Next.js frontend and Docker infrastructure#34
chinmayy777 wants to merge 2 commits intoOSIPI:mainfrom
chinmayy777:ci/frontend-docker-pipeline

Conversation

@chinmayy777
Copy link

📦 Stacked PR Notice: > Note for Reviewers: This PR is branched off of my infrastructure fixes in PR #8 to ensure the GitHub Actions runners are testing against the corrected Node 20 and Docker multi-stage build environment. Once PR #8 is merged, the diff will update to only show the .github/workflows additions.

Motivation

With the recent migration of the repository and the establishment of backend regression tests, we need to ensure the Frontend UI and Deployment Infrastructure are equally protected.

Next.js is notoriously strict during production builds (e.g., failing on unused variables during ESLint checks), and Docker container environments can easily break from minor dependency mismatches. This PR introduces a CI pipeline to catch these "silent failures" before they can be merged into main.

What This PR Does

Adds a new .github/workflows/frontend-infrastructure-ci.yml workflow that automatically runs on every push/PR to main:

  1. Next.js Production Validation:
    • Sets up Node.js 20 and caches yarn dependencies.
    • Runs yarn lint to enforce strict React/Next.js code quality.
    • Runs yarn build to guarantee the static production bundle successfully compiles without fatal errors.
  2. Infrastructure/Docker Dry-Run:
    • Executes docker compose build to verify that the multi-stage Dockerfiles for both frontend and backend resolve correctly in an isolated Ubuntu environment.

Impact

This perfectly complements the backend API test coverage by providing 360-degree full-stack CI validation. Reviewers can now merge UI and Docker changes with absolute confidence that the local development environment and production builds will not break.

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