You've learned for 25 minutes. A short break helps your brain.
Sprint done! Great focus. Stretch for a minute?
CI/CD cheat sheet
The commands you learned, in one place.
Deploy and roll back (Cloudflare Wrangler)
npx wrangler deploy --dry-runCheck the config and files. Upload nothing.Risk: Carefulnpx wrangler deploy --env stagingShip to the staging copy (a Worker named <name>-staging).Risk: Carefulnpx wrangler versions uploadThe new version waits. Users still get the old one.npx wrangler versions deployAsks which versions get which share of traffic.Risk: Carefulnpx wrangler rollback --message "Smoke test failed"Go back to the version before the latest, with a note why.Risk: Carefulnpx wrangler rollback --env stagingRoll back the staging copy only.Risk: Carefulnpx wrangler preview --name "pr-7"Make or update the preview for pull request 7.npx wrangler preview delete --name "pr-7" --skip-confirmationDelete it when the pull request closes.
Check images and workflows
hadolint DockerfileCheck the recipe. A finding exits with code 1.hadolint --failure-threshold error DockerfileOnly errors fail; warnings are just printed.docker run --rm -v "$PWD:/repo" -w /repo rhysd/actionlint:1.7.12Run the official image on this repo. No install needed.trivy image --severity CRITICAL --exit-code 1 kedai-kancil:scanFail (exit code 1) if any critical hole is found.gh attestation verify oci://ghcr.io/you/kedai-kancil:1.2.0 -R you/kedai-kancilWas this image built by my repo's workflow?