BM: Baca dalam Bahasa Melayu
World C1: Pipeline Thinking
Stations on the belt
You will learn: the six stations of a pipeline, and why their order matters.
Checked with GitHub Actions 2026-10 on 31 Oct 2026
The problem
Pick an event. Press Run and watch the line.
Workflow file .github/workflows/oops.yml
name: Oops on: push: branches: [main] permissions: contents: read jobs: line: runs-on: ubuntu-latest steps: - uses: actions/checkout@v7 - run: npm ci - run: npm run build - run: npm run deploy env: CLOUDFLARE_API_TOKEN: ${{ secrets.CLOUDFLARE_API_TOKEN }} - run: npm test
The line
Push to main · main
This line ships first and tastes last. Press Run. The test fails, but the bug is already live. Ouch!
Watch
Tap each point on the timeline.
Tap each station. Each one is a stage: One station on the belt, like lint, test, build, scan, publish or deploy.. Cheap checks come first. The van leaves last.
Try it
Put the stations in order. The first station goes at the top.
First station at the top. Put these in order. Use the arrows, or drag.
- Build
- Lint
- Scan
- Test
- Deploy
- Publish
Hint
Quick checks first. Nothing ships until it is checked.Watch
Pick an event. Press Run and watch the line.
Workflow file .github/workflows/shop.yml
name: Shop line on: push: branches: [main] permissions: contents: read packages: write jobs: line: runs-on: ubuntu-latest steps: - uses: actions/checkout@v7 - run: npm ci - run: npm run lint - run: npm test - run: docker build -t shop:${{ github.sha }} . - name: Scan the image uses: aquasecurity/trivy-action@v0.36.0 with: image-ref: shop:${{ github.sha }} severity: CRITICAL exit-code: '1' - name: Publish to GHCR run: | echo "$TOKEN" | docker login ghcr.io -u "$GITHUB_ACTOR" --password-stdin docker tag shop:${{ github.sha }} ghcr.io/kancil/shop:${{ github.sha }} docker push ghcr.io/kancil/shop:${{ github.sha }} env: TOKEN: ${{ secrets.GITHUB_TOKEN }} - run: npm run deploy env: CLOUDFLARE_API_TOKEN: ${{ secrets.CLOUDFLARE_API_TOKEN }}
The line
Push to main · main
Here is the whole line in one job. Press Run and watch every station turn green. Tap any station to read its log.
Try it
Your turn. Build a line that stops after build.
Tap blocks to add them. Put them in order.
Blocks
Your workflow
Tap a block above to start.
Workflow file .github/workflows/
name: CI
What runs
Nothing to run yet.
Hint
Get ready first: check out, then install. Then lint, test, build.Predict
This time, the image has a bad ingredient.
Which station will stop the line? Tap it, then press Run.
Workflow file .github/workflows/shop.yml
name: Shop line on: push: branches: [main] permissions: contents: read packages: write jobs: line: runs-on: ubuntu-latest steps: - uses: actions/checkout@v7 - run: npm ci - run: npm run lint - run: npm test - run: docker build -t shop:${{ github.sha }} . - name: Scan the image uses: aquasecurity/trivy-action@v0.36.0 with: image-ref: shop:${{ github.sha }} severity: CRITICAL exit-code: '1' - name: Publish to GHCR run: | echo "$TOKEN" | docker login ghcr.io -u "$GITHUB_ACTOR" --password-stdin docker tag shop:${{ github.sha }} ghcr.io/kancil/shop:${{ github.sha }} docker push ghcr.io/kancil/shop:${{ github.sha }} env: TOKEN: ${{ secrets.GITHUB_TOKEN }} - run: npm run deploy env: CLOUDFLARE_API_TOKEN: ${{ secrets.CLOUDFLARE_API_TOKEN }}
The line
Push to main · main
Check
Good line, or needs work? Swipe each one.
Swipe right for good, left for needs work. Or use the buttons.
Lint before the tests
You did it!
You can now name the six stations and put them in order.
Go deeper (optional)
Not every project needs every station. A small static site has no image to scan or publish. Stations can also run side by side. Jobs without needs: start at the same time. Jobs with needs: wait for the jobs they name.
Real rep (optional): open your own workflow file. Write the station name next to each step as a comment.
Bahasa Melayu
Tali sawat ini hantar dulu, rasa kemudian. Tekan Run. Ujian gagal, tapi pepijat dah pun live. Aduh!
Ketik setiap stesen. Setiap satu ialah stage (peringkat). Semakan murah datang dulu. Van keluar paling akhir.
Susun stesen ikut urutan. Stesen pertama di atas.
Ini seluruh tali sawat dalam satu job. Tekan Run dan tengok setiap stesen jadi hijau. Ketik mana-mana stesen untuk baca log.
Giliran anda. Bina tali sawat yang berhenti selepas build.
Kali ini image ada bahan buruk.
Tali sawat yang baik, atau perlu dibaiki? Leret setiap satu.
Kini anda boleh namakan enam stesen dan susun ikut urutan.
You finished this before. Practice is always welcome!
Official docs: Workflow syntax: jobs and needs · Continuous integration
You've learned for 25 minutes. A short break helps your brain.
Sprint done! Great focus. Stretch for a minute?