From ae7ebf7a2dc1e770f1d219a1ade54bd87d23cef5 Mon Sep 17 00:00:00 2001 From: Gabisonfire Date: Sun, 4 Feb 2024 20:59:12 -0500 Subject: [PATCH] Builds and pushes various components images --- .github/workflows/build_images.yaml | 43 +++++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) create mode 100644 .github/workflows/build_images.yaml diff --git a/.github/workflows/build_images.yaml b/.github/workflows/build_images.yaml new file mode 100644 index 00000000..f79a122a --- /dev/null +++ b/.github/workflows/build_images.yaml @@ -0,0 +1,43 @@ +name: Build + +on: + push: + branches: + - 'master' + - 'feat/build_workflow' + +jobs: + build-and-push: + runs-on: ubuntu-latest + strategy: + matrix: + include: + - dockerfile: ./src/node/addon/Dockerfile + tag: gabisonfire/knightcrawler-addon:latest + - dockerfile: ./src/node/addon-jackett/Dockerfile + tag: gabisonfire/knightcrawler-addon-jackett:latest + - dockerfile: ./src/node/consumer/Dockerfile + tag: gabisonfire/knightcrawler-consumer:latest + - dockerfile: ./src/producer/Dockerfile + tag: gabisonfire/knightcrawler-producer:latest + steps: + - + name: Checkout repository + uses: actions/checkout@v4 + - + name: Set up Docker Buildx + uses: docker/setup-buildx-action@v3 + - + name: Login to Docker Hub + uses: docker/login-action@v3 + with: + username: ${{ vars.DOCKERHUB_USERNAME }} + password: ${{ secrets.DOCKERHUB_TOKEN }} + - + name: Build and push ${{ matrix.tag }} + uses: docker/build-push-action@v5 + with: + context: app + file: ${{ matrix.dockerfile }} + push: true + tags: ${{ matrix.tag }} \ No newline at end of file