name: promote on: workflow_dispatch: inputs: version: description: "release the canary is expected to run; must match what it runs" required: true type: string concurrency: group: promote cancel-in-progress: true permissions: contents: read packages: write jobs: promote: if: vars.CANARY_URL != '' runs-on: self-hosted steps: - name: Log in to the Gitea registry run: echo "${{ secrets.DEPLOY_TOKEN }}" | docker login git.catlow.cloud -u "${{ github.actor }}" --password-stdin - name: Fetch the published archied # The deploy workflow already built this binary. edge is the newest # main that passed the gate. run: | set -e image=git.catlow.cloud/sam/archied:edge docker pull -q "$image" container="$(docker create "$image")" docker cp "$container:/usr/local/bin/archied" "$RUNNER_TEMP/archied" docker rm "$container" >/dev/null - name: Promote the canary's release env: ARCHIE_CANARY_TOKEN: ${{ secrets.CANARY_TOKEN }} run: | "$RUNNER_TEMP/archied" release canary promote -dashboard "${{ vars.CANARY_URL }}" \ -version "${{ inputs.version }}" \ -latest git.catlow.cloud/sam/archied,git.catlow.cloud/sam/archie-agent