Skip to content

Commit

Permalink
Merge pull request #79 from uswitch/airship-3070/migrate-to-gha
Browse files Browse the repository at this point in the history
airship-3070: migrate to github actions
  • Loading branch information
mmcgarr committed Dec 1, 2023
2 parents 7b34337 + d7f9cbb commit 185bead
Show file tree
Hide file tree
Showing 3 changed files with 58 additions and 40 deletions.
40 changes: 0 additions & 40 deletions .drone.yml

This file was deleted.

1 change: 1 addition & 0 deletions .github/rvu/labels.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
service.rvu.co.uk/brand: airship
57 changes: 57 additions & 0 deletions .github/workflows/push.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
name: push
on: push
permissions:
contents: read
id-token: write
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v4
with:
go-version: "1.17"
- run: make test
build:
runs-on: ubuntu-latest
needs: test
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v4
with:
go-version: "1.17"
- run: make build-linux
- uses: actions/upload-artifact@v3
with:
name: bin
path: bin/
docker-build-push:
if: github.ref_name == 'master' || startsWith(github.ref, 'refs/tags/v')
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/download-artifact@v3
with:
name: bin
path: bin/
- name: Login to Quay.io
uses: docker/login-action@v3
with:
registry: quay.io
username: ${{ secrets.QUAY_USERNAME }}
password: ${{ secrets.QUAY_PASSWORD }}
- id: meta
uses: docker/metadata-action@v5
with:
images: quay.io/uswitch/yggdrasil
tags: |
type=semver,pattern={{version}}
type=sha,prefix=,format=long,
- uses: docker/build-push-action@v5
with:
context: .
labels: ${{ steps.meta.outputs.labels }}
push: true
tags: ${{ steps.meta.outputs.tags }}

0 comments on commit 185bead

Please sign in to comment.