From 21e2d7150ea6e3f24da640cb63f831502043d84d Mon Sep 17 00:00:00 2001 From: Zsolt Tasnadi Date: Wed, 5 Aug 2026 20:32:32 +0200 Subject: [PATCH] Switch the CI templates to the /build HTTP endpoints --- README.md | 10 +++++----- example-makefile.make | 10 ++++++---- example-woodpecker.yaml | 11 ++++------- 3 files changed, 15 insertions(+), 16 deletions(-) diff --git a/README.md b/README.md index 15a5d05..272a53e 100644 --- a/README.md +++ b/README.md @@ -12,8 +12,8 @@ and [tic80-tools](../tic80-tools). `ci-upload`, `ci-update`). - `example-woodpecker.yaml` — Woodpecker pipeline: version → build (headless web export + desktop binaries in the `barichello/godot-ci` - image) → upload (scp to the droparea) → update (calls the - teletypegames `/update` endpoint with `platform=godot`). + image) → upload (HTTP POST to `/build/upload`) → update (calls the + teletypegames `/build/publish` endpoint with `platform=godot`). - `example-export_presets.cfg` — `export_presets.cfg` with the **Web** preset the Makefile exports plus the desktop presets (**Windows x86**, **Windows x64**, **Linux x64**, **Mac universal**). Web @@ -41,7 +41,7 @@ and [tic80-tools](../tic80-tools). textures/vram_compression/import_etc2_astc=true ``` 3. Copy `example-woodpecker.yaml` to `.woodpecker.yaml` and add the - `droparea_ssh_password` / `update_secret_key` secrets in Woodpecker. + `update_secret_key` secret in Woodpecker. Match the `godot-builder` image tag to the Godot version the project is made with (e.g. `4.6`) — the underlying `barichello/godot-ci` image ships the matching export templates. @@ -49,8 +49,8 @@ and [tic80-tools](../tic80-tools). The pipeline uploads `$(PROJECT)-$(VERSION).html.zip` and the desktop binary zips (`$(PROJECT)-$(VERSION)-.zip`, targets: `win-x86`, -`win-x64`, `linux-x64`, `mac-universal`) to the droparea, then triggers -`/update?platform=godot&name=$(PROJECT)&version=$(VERSION)`, which +`win-x64`, `linux-x64`, `mac-universal`) via `/build/upload`, then triggers +`/build/publish?platform=godot&name=$(PROJECT)&version=$(VERSION)`, which attaches them to the release as ReleaseAssets. Godot cross-exports all desktop platforms from the linux CI image with the official export templates; mac is a single universal (intel + arm) build with Godot's diff --git a/example-makefile.make b/example-makefile.make index 2276df8..957ef52 100644 --- a/example-makefile.make +++ b/example-makefile.make @@ -129,12 +129,14 @@ ci-upload: META_DST="$(PROJECT)-$$VERSION.metadata.json"; \ BINS=$$(ls $(PROJECT)-$$VERSION-*.zip 2>/dev/null || true); \ cp $$META_SRC $$META_DST; \ - sshpass -p "$(DROPAREA_SSH_PASSWORD)" scp -o StrictHostKeyChecking=no -P $(DROPAREA_PORT) \ - $$FILE $$META_DST $$BINS \ - $(DROPAREA_USER)@$(DROPAREA_HOST):$(DROPAREA_TARGET_PATH)/ + 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-update: @VERSION=$$(cat $(VERSION_FILE)); \ - curl "$(UPDATE_SERVER)/update?secret=$(UPDATE_SECRET)&name=$(PROJECT)&platform=godot&version=$$VERSION" + curl -fsS -X POST -H "X-Update-Secret: $(UPDATE_SECRET)" "$(UPDATE_SERVER)/build/publish?name=$(PROJECT)&platform=godot&version=$$VERSION" .PHONY: all build run web export watch clean binaries binary-win-x86 binary-win-x64 binary-linux-x64 binary-mac-universal binary-build binary-build-mac ci-version ci-export ci-binaries ci-upload ci-update diff --git a/example-woodpecker.yaml b/example-woodpecker.yaml index 6d0abd6..212e6d9 100644 --- a/example-woodpecker.yaml +++ b/example-woodpecker.yaml @@ -14,14 +14,11 @@ steps: - 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 + UPDATE_SERVER: https://teletypegames.org + UPDATE_SECRET: + from_secret: update_secret_key commands: - - apk add --no-cache make openssh-client sshpass + - apk add --no-cache make curl - make ci-upload - name: update