Skip to content

Workflow file for this run

on: [push, pull_request]
name: Test and Release
jobs:
unit_tests:
strategy:
matrix:
platform: [ubuntu-latest]
runs-on: ${{ matrix.platform }}
steps:
- name: Install Go
uses: actions/setup-go@v2
with:
go-version: '>= 1.20'
- name: Checkout code
uses: actions/checkout@v2
- name: Unpack test GCP service account
env:
OTARU_GITHUB_CI: ${{ secrets.OTARU_GITHUB_CI }}
run: |
echo -n $OTARU_GITHUB_CI | base64 -d > /tmp/otaru-github-ci.json
- name: Test
run: go test ./...
env:
SKIP_FUSE_TEST: "1"
GOOGLE_APPLICATION_CREDENTIALS: "/tmp/otaru-github-ci.json"
release_docker:
needs: [unit_tests]
if: github.event_name == 'push'
runs-on: ubuntu-latest
steps:
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: '>= 1.20'
- name: Checkout
uses: actions/checkout@v2
- uses: imjasonh/[email protected]
- run: ko publish --bare ./cmd/otaru