Merge branch 'main' of [email protected]:Cdaprod/cda-deploy-to-swarm.git #23
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build and Push Docker Images | |
on: | |
push: | |
branches: [main] | |
paths: | |
- 'minio/**' | |
- 'weaviate/**' | |
- 'nginx/**' | |
- 'jupyter/**' | |
- 'tailscale/**' | |
pull_request: | |
branches: [main] | |
paths: | |
- 'minio/**' | |
- 'weaviate/**' | |
- 'nginx/**' | |
- 'jupyter/**' | |
- 'tailscale/**' | |
workflow_dispatch: | |
jobs: | |
build-and-push: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v2 | |
- name: Login to Docker Hub | |
uses: docker/login-action@v2 | |
with: | |
username: ${{ secrets.DOCKERHUB_USERNAME }} | |
password: ${{ secrets.DOCKERHUB_TOKEN }} | |
- name: Build and push custom MinIO image | |
uses: docker/build-push-action@v3 | |
with: | |
context: ./minio | |
file: ./minio/Dockerfile | |
push: true | |
tags: cdaprod/cda-minio:${{ github.sha }} | |
platforms: linux/amd64,linux/arm64 | |
- name: Build and push custom Weaviate image | |
uses: docker/build-push-action@v3 | |
with: | |
context: ./weaviate | |
file: ./weaviate/Dockerfile | |
push: true | |
tags: cdaprod/cda-weaviate:${{ github.sha }} | |
platforms: linux/amd64,linux/arm64 | |
- name: Build and push custom NGINX image | |
uses: docker/build-push-action@v3 | |
with: | |
context: ./nginx | |
file: ./nginx/Dockerfile | |
push: true | |
tags: cdaprod/cda-nginx:${{ github.sha }} | |
platforms: linux/amd64,linux/arm64 | |
- name: Build and push custom JupyterLab image | |
uses: docker/build-push-action@v3 | |
with: | |
context: ./jupyter | |
file: ./jupyter/Dockerfile | |
push: true | |
tags: cdaprod/cda-jupyterlab:${{ github.sha }} | |
platforms: linux/amd64,linux/arm64 | |
- name: Build and push Tailscale image | |
uses: docker/build-push-action@v3 | |
with: | |
context: ./tailscale | |
file: ./tailscale/Dockerfile | |
push: true | |
tags: cdaprod/cda-tailscale:${{ github.sha }} | |
platforms: linux/amd64,linux/arm64 |