# Temporary minimal pipeline for testing package linking when: - event: [push, pull_request, manual] steps: # Test package linking with proper variable escaping link-packages-test: image: alpine:3 environment: GITEA_TOKEN: from_secret: gitea_token commands: - apk add --no-cache curl - echo "Testing package linking with variable expansion..." - | link_package() { PKG="$$1" echo "" echo "Testing package: $$PKG" STATUS=$$(curl -s -o /tmp/link-response.txt -w "%{http_code}" -X POST \ -H "Authorization: token $$GITEA_TOKEN" \ "https://git.mosaicstack.dev/api/v1/packages/mosaic/container/$$PKG/-/link/stack") echo " URL: https://git.mosaicstack.dev/api/v1/packages/mosaic/container/$$PKG/-/link/stack" echo " Status: $$STATUS" if [ "$$STATUS" = "201" ] || [ "$$STATUS" = "204" ]; then echo " ✅ Successfully linked $$PKG to stack" elif [ "$$STATUS" = "400" ]; then echo " ✅ $$PKG already linked (OK)" cat /tmp/link-response.txt else echo " ❌ $$PKG link failed" echo " Response:" cat /tmp/link-response.txt fi } echo "=== Linking all stack packages ===" link_package "stack-api" link_package "stack-web" link_package "stack-postgres" link_package "stack-openbao" link_package "stack-orchestrator" echo "" echo "=== Test complete ===" when: - branch: [main, develop] event: [push, manual]