owl-blogs/.github/workflows/release.yml

46 lines
939 B
YAML
Raw Normal View History

2024-05-18 18:49:07 +00:00
on:
release:
types: [created]
permissions:
contents: write
packages: write
jobs:
release-linux-amd64:
name: release linux/amd64
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Go
uses: actions/setup-go@v4
with:
go-version: '1.22'
2024-05-18 19:59:32 +00:00
- uses: actions/setup-python@v5
with:
python-version: '3.11'
2024-05-18 18:49:07 +00:00
2024-05-18 19:59:32 +00:00
- name: Build
run: go build -v ./...
2024-05-18 18:49:07 +00:00
2024-05-18 19:59:32 +00:00
- name: Test
run: go test -v ./...
2024-05-18 18:49:07 +00:00
2024-05-18 19:59:32 +00:00
- name: E2E Test
run: |
cd e2e_tests
docker compose -f docker-compose.ci.yml up -d
pip install -r requirements.txt
pytest
2024-05-18 18:49:07 +00:00
2024-05-18 19:06:42 +00:00
- name: Build Release
env:
CGO_ENABLED: 1
GOOS: linux
GOARCH: amd64
2024-05-18 19:11:03 +00:00
GH_TOKEN: ${{ github.token }}
2024-05-18 19:06:42 +00:00
run: |
go build -o owl-linux-amd64 ./cmd/owl
gh release upload ${{github.event.release.tag_name}} owl-linux-amd64