Serve the CI pipeline from the update server (marker config)
ci/woodpecker/push/ebitengine Pipeline was successful

This commit is contained in:
2026-08-06 08:09:36 +02:00
parent 58f5f57606
commit 83d285e04a
3 changed files with 4 additions and 77 deletions
+3
View File
@@ -0,0 +1,3 @@
# The CI pipeline is served by the update server: GET /build/config?platform=ebitengine
platform: ebitengine
name: ebitenginedemo
-38
View File
@@ -1,38 +0,0 @@
steps:
- name: version
image: alpine
commands:
- apk add --no-cache git make jq
- make ci-version
- name: build
image: git.teletypegames.org/internal/ebitengine-builder:latest
pull: true
commands:
- make ci-export
- name: binaries
image: git.teletypegames.org/internal/ebitengine-builder:latest
pull: true
commands:
- make ci-binaries
- name: artifact
image: alpine
environment:
UPDATE_SERVER: https://teletypegames.org
UPDATE_SECRET:
from_secret: update_secret_key
commands:
- apk add --no-cache make curl
- make ci-upload
- name: publish
image: alpine
environment:
UPDATE_SERVER: https://teletypegames.org
UPDATE_SECRET:
from_secret: update_secret_key
commands:
- apk add --no-cache make curl
- make ci-publish
+1 -39
View File
@@ -12,7 +12,6 @@ OUTPUT_WASM = $(DIST_DIR)/$(WASM_NAME)
OUTPUT_JS = $(DIST_DIR)/wasm_exec.js
OUTPUT_ZIP = $(PROJECT)-$(VERSION).html.zip
VERSION_FILE = .version
INDEX_HTML_URL = https://git.teletypegames.org/tools/ebitengine-tools/raw/branch/master/web/index.html
all: build
@@ -80,41 +79,4 @@ watch:
clean:
rm -rf $(BIN_DIR) $(DIST_DIR)
ci-version:
@if [ -f metadata.json ]; then \
VERSION=$$(jq -r '.version' metadata.json); \
else \
VERSION=$$(git rev-parse --short HEAD); \
fi; \
BRANCH=$$(git rev-parse --abbrev-ref HEAD); \
if [ "$$BRANCH" != "main" ] && [ "$$BRANCH" != "master" ]; then \
VERSION="dev-$$VERSION-$$BRANCH"; \
fi; \
echo $$VERSION > $(VERSION_FILE)
ci-export:
@VERSION=$$(cat $(VERSION_FILE)); \
$(MAKE) export VERSION=$$VERSION
ci-binaries:
@VERSION=$$(cat $(VERSION_FILE)); \
$(MAKE) binaries VERSION=$$VERSION
ci-upload:
@VERSION=$$(cat $(VERSION_FILE)); \
FILE="$(PROJECT)-$$VERSION.html.zip"; \
META_SRC="metadata.json"; \
META_DST="$(PROJECT)-$$VERSION.metadata.json"; \
BINS=$$(ls $(PROJECT)-$$VERSION-*.zip 2>/dev/null || true); \
cp $$META_SRC $$META_DST; \
for f in $$FILE $$META_DST $$BINS; do \
curl -fsS -H "X-Update-Secret: $(UPDATE_SECRET)" \
-F "file=@$$f" \
"$(UPDATE_SERVER)/build/upload?name=$(PROJECT)&version=$$VERSION" || exit 1; \
done
ci-publish:
@VERSION=$$(cat $(VERSION_FILE)); \
curl -fsS -X POST -H "X-Update-Secret: $(UPDATE_SECRET)" "$(UPDATE_SERVER)/build/publish?name=$(PROJECT)&platform=ebitengine&version=$$VERSION"
.PHONY: all build wasm export watch clean binaries binary-win-x86 binary-win-x64 binary-linux-x64 binary-build ci-version ci-export ci-binaries ci-upload ci-publish
.PHONY: all build wasm export watch clean binaries binary-win-x86 binary-win-x64 binary-linux-x64 binary-build