World map

 

BM: Baca dalam Bahasa Melayu

World C2: Container Pipelines

Reusable workflows and composite actions

You will learn: to write a pipeline once and share it across your apps.

Checked with GitHub Actions 2026-10 on 31 Oct 2026

The problem

Kedai Kancil has a web image and an API image. Both workflows hold the same 30 build lines. You fix a bug in one. What about the other?

Pick one answer.

Watch

Tap the line that names the blank to fill in.

0 of 1 found

Recap from World 7. A reusable workflow: A workflow other workflows can call, made with on: workflow_call. is head office’s standard recipe. workflow_call lets others call it. Inputs are the blanks.

Watch

Pick an event. Press Run and watch the line.

Two jobs, web and api, each call build-image.yml with their own folder. Both run side by side and turn green.

What happened on GitHub

Workflow file .github/workflows/ci.yml

name: CI
on:
push:
branches: [main]
permissions:
contents: read
packages: write
jobs:
web:
uses: ./.github/workflows/build-image.yml
with:
folder: web
api:
uses: ./.github/workflows/build-image.yml
with:
folder: api

The line

Push to main · main

Two jobs call one recipe, each with its own folder. Press Run. Fix the recipe once, and both apps get the fix.

Watch

Tap the line that makes this a composite action.

0 of 1 found

A composite action: A pre-mixed spice blend: a few steps saved as one action. It runs as one step in your job. is a pre-mixed spice blend: steps in one jar. In a job, uses: ./.github/actions/setup-shop runs it as one step.

Try it

Which one is it?

Drag a card into a box. Or tap the card, then tap the box.

      Predict

      The caller’s token has packages: read. The called workflow asks for packages: write. What happens?

      Pick one answer.

      You did it!

      You can now share one pipeline across many apps.

      Go deeper (optional)

      Call a reusable workflow from another repo like an action: owner/repo/.github/workflows/build.yml@ref. Pin that ref to a full SHA, as World C4 explains. In the log, a composite action is one step. Open it to see inside.

      Real rep (optional):

      Real mission

      0 of 3 steps done · Your ticks are saved.