Skip to content

Commit

Permalink
Update docker-publish.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
ibz authored Dec 19, 2023
1 parent 0feff4d commit 22592b9
Showing 1 changed file with 46 additions and 1 deletion.
47 changes: 46 additions & 1 deletion .github/workflows/docker-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ jobs:
# Build and push Docker image with Buildx
# https://github.com/docker/build-push-action
- name: Build and push Docker image (api)
id: build-and-push
id: build-and-push-api
uses: docker/build-push-action@0565240e2d4ab88bba5387d719585280857ece09 # v5.0.0
with:
context: ./
Expand All @@ -103,6 +103,29 @@ jobs:
cache-from: type=gha
cache-to: type=gha,mode=max

# Extract metadata (tags, labels) for Docker
# https://github.com/docker/metadata-action
- name: Extract Docker metadata (web)
id: meta-web
uses: docker/metadata-action@96383f45573cb7f253c731d3b3ab81c87ef81934 # v5.0.0
with:
images: ${{ env.REGISTRY }}/plebeiantech/plebeian-market-web

# Build and push Docker image with Buildx
# https://github.com/docker/build-push-action
- name: Build and push Docker image (web)
id: build-and-push-web
uses: docker/build-push-action@0565240e2d4ab88bba5387d719585280857ece09 # v5.0.0
with:
context: ./
file: ./web/Dockerfile
push: true
tags: ${{ steps.meta-web.outputs.tags }}
labels: ${{ steps.meta-web.outputs.labels }}
cache-from: type=gha
cache-to: type=gha,mode=max
build-args: BUILD_MODE=-production

# Extract metadata (tags, labels) for Docker
# https://github.com/docker/metadata-action
- name: Extract Docker metadata (birdwatcher)
Expand All @@ -124,3 +147,25 @@ jobs:
labels: ${{ steps.meta-birdwatcher.outputs.labels }}
cache-from: type=gha
cache-to: type=gha,mode=max

# Extract metadata (tags, labels) for Docker
# https://github.com/docker/metadata-action
- name: Extract Docker metadata (nginx)
id: meta-nginx
uses: docker/metadata-action@96383f45573cb7f253c731d3b3ab81c87ef81934 # v5.0.0
with:
images: ${{ env.REGISTRY }}/plebeiantech/plebeian-market-nginx

# Build and push Docker image with Buildx
# https://github.com/docker/build-push-action
- name: Build and push Docker image (nginx)
id: build-and-push-nginx
uses: docker/build-push-action@0565240e2d4ab88bba5387d719585280857ece09 # v5.0.0
with:
context: ./
file: ./services/nginx/Dockerfile
push: true
tags: ${{ steps.meta-nginx.outputs.tags }}
labels: ${{ steps.meta-nginx.outputs.labels }}
cache-from: type=gha
cache-to: type=gha,mode=max

0 comments on commit 22592b9

Please sign in to comment.