From aa21fa3a7725575e31ad89ee5800534222d307b9 Mon Sep 17 00:00:00 2001 From: neverbot Date: Wed, 7 Feb 2024 23:54:25 +0100 Subject: [PATCH] feat: auto build and publish image on push --- .github/workflows/publish-ghcr.yaml | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 .github/workflows/publish-ghcr.yaml diff --git a/.github/workflows/publish-ghcr.yaml b/.github/workflows/publish-ghcr.yaml new file mode 100644 index 0000000..8546ef8 --- /dev/null +++ b/.github/workflows/publish-ghcr.yaml @@ -0,0 +1,19 @@ +name: Build and Publish to Github Container Registry + +on: + push + +jobs: + build_and_publish: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - name: Login onto ghcr + run: | + docker login --user maldorne-bot --password ${{ secrets.MALDORNE_BOT_GHCR_TOKEN }} ghcr.io + - name: Build image + run: | + docker build --no-cache . -t ghcr.io/maldorne/mudos:v21.7 + - name: Publish image + run: | + docker push ghcr.io/maldorne/mudos:v21.7