This document describes the Woodpecker CI pipeline used to build, export, upload, and publish an Ebitengine game project.
The pipeline logic is almost entirely encapsulated within a Makefile, which is called by each pipeline step. This approach simplifies the CI configuration and keeps the build logic centralized.
The pipeline performs the following steps:
metadata.json or git commit hash.Each step corresponds to a make ci-* target.
- name: version
image: alpine
commands:
- 'apk add --no-cache make git jq'
- 'make ci-version'
What it does:
make, git, and jq for processing JSON.make ci-version, which:
metadata.json (if exists) or falls back to git short commit hash.main or master), prefixes the version as dev-<version>-<branch>..version file for subsequent steps to use.- name: build
image: golang:1.21
environment:
GOFLAGS: -mod=readonly
commands:
- 'apt-get update && apt-get install -y make curl zip'
- 'make ci-export'
What it does:
make, curl, and zip for packaging.make ci-export, which:
.version file.GOOS=js GOARCH=wasm).wasm_exec.js) to the output directory.index.html template from the remote ebitengine-tools repository.ebitenginedemo-<version>.html.zip.- name: artifact
image: alpine
environment:
DROPAREA_HOST: vps.teletype.hu
DROPAREA_PORT: 2223
DROPAREA_TARGET_PATH: /home/drop
DROPAREA_USER: drop
DROPAREA_SSH_PASSWORD:
from_secret: droparea_ssh_password
commands:
- 'apk add --no-cache make openssh-client sshpass'
- 'make ci-upload'
What it does:
make and SSH tooling (openssh-client, sshpass).make ci-upload, which:
.version file.metadata.json to ebitenginedemo-<version>.metadata.json..html.zip and .metadata.json files to a remote server using scp.- name: update
image: alpine
environment:
UPDATE_SERVER: https://games.vps.teletype.hu
UPDATE_SECRET:
from_secret: update_secret_key
commands:
- 'apk add --no-cache make curl'
- 'make ci-update'
What it does:
make and curl.make ci-update, which:
.version file.secret - Authorization tokenname - Project name (ebitenginedemo)platform - Platform identifier (ebitengine)version - Version from .version fileExample request:
https://games.vps.teletype.hu/update?secret=<SECRET>&name=ebitenginedemo&platform=ebitengine&version=1.0.0
After a successful run:
This pipeline enables fully automated Ebitengine releases where the entire build and release logic is managed by the project's Makefile.
https://git.teletype.hu/tools/ebitengine-tools/src/branch/master/example-woodpecker.yaml