From 6a33935d620421d75bf0d789ee497e357fa839ba Mon Sep 17 00:00:00 2001 From: Michael Snoyman Date: Thu, 19 Aug 2021 11:14:49 +0300 Subject: [PATCH] Include image.yml --- .github/workflows/image.yml | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 .github/workflows/image.yml diff --git a/.github/workflows/image.yml b/.github/workflows/image.yml new file mode 100644 index 00000000..71c917fd --- /dev/null +++ b/.github/workflows/image.yml @@ -0,0 +1,25 @@ +name: image + +on: + push: + branches: + - nightly + - lts18 + +jobs: + push: + runs-on: ubuntu-latest + if: github.event_name == 'push' + + steps: + - uses: actions/checkout@v2 + + - name: Log into Github registry + run: echo "${{ secrets.GITHUB_TOKEN }}" | docker login docker.pkg.github.com -u ${{ github.actor }} --password-stdin + + - name: Build image + run: | + IMAGE_ID=docker.pkg.github.com/${{ github.repository }}/build:${GITHUB_REF#refs/heads/} + docker build . -f Dockerfile --tag $IMAGE_ID + docker push $IMAGE_ID + echo Pushed new build image $IMAGE_ID