Build a Node.js CI Workflow With a Manual Run Option
Admin ·
Generate a workflow that checks a Node.js project before changes enter main or a release branch. The default uses a lockfile, npm caching and a manual trigger.
GitHub Actions Workflow Generator
Generate checks for main and a release branch
Keep Project stack on Node.js and Runtime version on 24. Set Target branches to main, release/v1, leave the three triggers and three quality checks selected, then choose Generate workflow YAML.
The summary reports one job. Check that push and pull_request both list main and release/v1, and workflow_dispatch is present. The Ubuntu job installs with npm ci, runs the lint and test scripts, and runs a build script if one exists.
GitHub Actions workflow syntaxactions/setup-node caching and dependency setup
Inspect the optional container publishing job
Open Optional publishing and deployment and select GitHub Container Registry. Enter example-org/site as Container image and generate again. The publish job needs checks, restricts itself to pushes to main and receives packages: write. It tags the image with the commit SHA.
Use an authorized image namespace and a repository-root Dockerfile before enabling delivery. Workflow secret names stay as references in the downloaded file.
GitHub Actions workflow syntaxGitHub Actions guide to publishing Docker images
Save the workflow under .github/workflows
Select Download ci.yml. Check the file against your project scripts, lockfile, runner and any registry or production environment settings before saving it to .github/workflows/ci.yml.
GitHub Actions workflow syntaxactions/setup-node caching and dependency setup
Common questions
Where does Vercel deploy from?
The optional Node.js or Next.js deployment uses a locked Vercel CLI dependency and a production environment with the project, organization and token secrets.
Which branch can run optional delivery?
The first configured target branch. Run the workflow checks on other target branches through the chosen triggers.