From 0685ffb71519b60df927b152a40c85be05b62d15 Mon Sep 17 00:00:00 2001 From: bjoernellens1 <64093272+bjoernellens1@users.noreply.github.com> Date: Mon, 16 Oct 2023 16:08:28 +0200 Subject: [PATCH] Create buildx-bake.yml --- .github/workflows/buildx-bake.yml | 45 +++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) create mode 100644 .github/workflows/buildx-bake.yml diff --git a/.github/workflows/buildx-bake.yml b/.github/workflows/buildx-bake.yml new file mode 100644 index 0000000..03c46c1 --- /dev/null +++ b/.github/workflows/buildx-bake.yml @@ -0,0 +1,45 @@ +name: Docker Compose Build + +on: + push: + branches: + - main # Change this to your main branch name + +jobs: + build: + runs-on: ubuntu-latest + + steps: + - name: Checkout code + uses: actions/checkout@v4 + + #- name: Set up QEMU + # run: docker run --rm --privileged multiarch/qemu-user-static --reset -p yes + + - name: Set up QEMU + uses: docker/setup-qemu-action@v3 + + # - name: Login to Docker Hub (if needed) + # uses: docker/login-action@v1 + # with: + # username: ${{ secrets.DOCKER_USERNAME }} + # password: ${{ secrets.DOCKER_PASSWORD }} + + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v3 + + #- name: Login to GitHub Container Registry + # run: echo ${{ secrets.GHCR_PAT }} | docker login ghcr.io -u ${{ github.repository_owner }} --password-stdin + - name: 'Login to GitHub Container Registry' + uses: docker/login-action@v3 + with: + registry: ghcr.io + username: ${{github.actor}} + password: ${{secrets.GHCR_PAT}} + + - name: Build and Push Docker Compose Services + run: | + docker buildx bake --push + docker buildx bake -f docker-compose.yml --push + #env: + # COMPOSE_FILE: docker-compose.yml