on master help sign in
Include image.yml
commit6a33935d620421d75bf0d789ee497e357fa839ba authorMichael Snoyman <michael@snoyman.com> dateThu 19 Aug 2021, 11:14 (5 years ago) parentb1d40e1
1 file changed+25
.github/workflows/image.yml+25
.github/workflows/image.ymlnew file+25
@@ -0,0 +1,25 @@
1+name: image
2+
3+on:
4+ push:
5+ branches:
6+ - nightly
7+ - lts18
8+
9+jobs:
10+ push:
11+ runs-on: ubuntu-latest
12+ if: github.event_name == 'push'
13+
14+ steps:
15+ - uses: actions/checkout@v2
16+
17+ - name: Log into Github registry
18+ run: echo "${{ secrets.GITHUB_TOKEN }}" | docker login docker.pkg.github.com -u ${{ github.actor }} --password-stdin
19+
20+ - name: Build image
21+ run: |
22+ IMAGE_ID=docker.pkg.github.com/${{ github.repository }}/build:${GITHUB_REF#refs/heads/}
23+ docker build . -f Dockerfile --tag $IMAGE_ID
24+ docker push $IMAGE_ID
25+ echo Pushed new build image $IMAGE_ID