Moved builds to be triggered on a release and not a push to araxia-main

This commit is contained in:
2024-05-18 13:03:14 -04:00
parent d48c3e392d
commit 62e66db5bb

View File

@@ -1,8 +1,11 @@
name: araxia-docker-test
# on:
# push:
# branches:
# - 'araxia-main'
on:
push:
branches:
- 'araxia-main'
release:
types: [published]
concurrency:
group: ${{ github.head_ref }} || concat(${{ github.ref }}, ${{ github.workflow }})
@@ -27,13 +30,19 @@ jobs:
buildkitd-flags: --debug
- name: Build Skeleton Container
run: docker build -t ghcr.io/araxiaonline/acore-skeleton:${{ github.sha }} --target skeleton --file ./apps/docker/Dockerfile .
run: docker build -t ghcr.io/araxiaonline/acore-skeleton:${{ github.event.release.tag_name }} --target skeleton --file ./apps/docker/Dockerfile .
- name: Build Worldserver Container
run: docker build -t ghcr.io/araxiaonline/araxia-worldserver:${{ github.sha }} --target worldserver --file ./apps/docker/Dockerfile .
run: docker build -t ghcr.io/araxiaonline/araxia-worldserver:${{ github.event.release.tag_name }} --target worldserver --file ./apps/docker/Dockerfile .
- name: Build Authserver Container
run: docker build -t ghcr.io/araxiaonline/araxia-authserver:${{ github.sha }} --target authserver --file ./apps/docker/Dockerfile .
run: docker build -t ghcr.io/araxiaonline/araxia-authserver:${{ github.event.release.tag_name }} --target authserver --file ./apps/docker/Dockerfile .
- name: Build db-import Container
run: docker build -t ghcr.io/araxiaonline/araxia-authserver:${{ github.event.release.tag_name }} --target db-import --file ./apps/docker/Dockerfile .
- name: Build client-data Container
run: docker build -t ghcr.io/araxiaonline/araxia-authserver:${{ github.event.release.tag_name }} --target client-data --file ./apps/docker/Dockerfile .
- name: Login to GitHub Docker Registry
uses: docker/login-action@v2
@@ -43,18 +52,24 @@ jobs:
password: ${{ secrets.GITHUB_TOKEN }}
- name: Push skeleton image
run: docker push ghcr.io/araxiaonline/acore-skeleton:${{ github.sha }}
run: docker push ghcr.io/araxiaonline/acore-skeleton:${{ github.event.release.tag_name }}
- name: Push Worldserver image
run: docker push ghcr.io/araxiaonline/araxia-worldserver:${{ github.sha }}
run: docker push ghcr.io/araxiaonline/araxia-worldserver:${{ github.event.release.tag_name }}
- name: Push Authserver image
run: docker push ghcr.io/araxiaonline/araxia-authserver:${{ github.sha }}
run: docker push ghcr.io/araxiaonline/araxia-authserver:${{ github.event.release.tag_name }}
- name: Push db-import image
run: docker push ghcr.io/araxiaonline/araxia-authserver:${{ github.event.release.tag_name }}
- name: Push client-data image
run: docker push ghcr.io/araxiaonline/araxia-authserver:${{ github.event.release.tag_name }}
# - name: build worldserver
# uses: ./.github/actions/docker-tag-and-build
# with:
# component-name: worldserver
# tags: ghcr.io/araxiaonline/azerothcore-worldserver:${{ github.sha }}
# tags: ghcr.io/araxiaonline/azerothcore-worldserver:${{ github.event.release.tag_name }}
# push: true