Skip to content

implement the activator: hold, wake, splice, idle-down #1

implement the activator: hold, wake, splice, idle-down

implement the activator: hold, wake, splice, idle-down #1

Workflow file for this run

# Tests run on every push and PR. Merges to main publish the image to
# ghcr.io/controlplane-com/scale-to-zero-proxy (:latest + :sha-<commit>);
# version tags (v*) publish that version tag as well.
name: CI
on:
push:
branches: ['**']
tags: ['v*']
pull_request:
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: '1.24'
- name: gofmt
run: test -z "$(gofmt -l .)" || (gofmt -l . && exit 1)
- name: vet
run: go vet ./...
- name: test
run: go test -race ./...
publish:
needs: [test]
if: github.event_name == 'push' && (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/tags/v'))
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
steps:
- uses: actions/checkout@v4
- uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- uses: docker/metadata-action@v5
id: meta
with:
images: ghcr.io/${{ github.repository }}
tags: |
type=raw,value=latest,enable={{is_default_branch}}
type=sha,prefix=sha-
type=semver,pattern={{version}}
- uses: docker/build-push-action@v6
with:
context: .
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}