diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml new file mode 100644 index 0000000..ed7b030 --- /dev/null +++ b/.github/workflows/build.yml @@ -0,0 +1,21 @@ +name: Docker Build + +on: + push: + +permissions: + packages: write + +jobs: + docker-build: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v4 + - name: Build Image + run: docker build . -f Dockerfile -t ghcr.io/taucher2003/gitlab-pipeline-action:${{ github.sha }} + - name: Login to Registry + run: echo ${{ secrets.GITHUB_TOKEN }} | docker login -u $ --password-stdin ghcr.io + - name: Push image + run: | + docker push ghcr.io/taucher2003/gitlab-pipeline-action:${{ github.sha }}