Skip to content

Commit

Permalink
naming for each CI should be more visible, add matrix for build_tool …
Browse files Browse the repository at this point in the history
…image base

Signed-off-by: hungran <[email protected]>
  • Loading branch information
hungran committed Dec 10, 2023
1 parent e8e26c3 commit abfa2c6
Show file tree
Hide file tree
Showing 5 changed files with 31 additions and 40 deletions.
61 changes: 26 additions & 35 deletions .github/workflows/build_tool.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: build
name: build_tool

on:
pull_request:
Expand All @@ -13,45 +13,36 @@ env:
jobs:
tool:
runs-on: ubuntu-latest
strategy:
matrix:
image:
- actions-gh-release
- actions-plan-preview
- codegen
- piped-base
- piped-base-okd
- firestore-emulator
include:
- image: actions-gh-release
context: tool/actions-gh-release
- image: actions-plan-preview
context: tool/actions-plan-preview
- image: codegen
context: tool/codegen
- image: piped-base
context: tool/piped-base
- image: piped-base-okd
context: tool/piped-base-okd
- image: firestore-emulator
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Determine version
run: echo "PIPECD_VERSION=$(git describe --tags --always --abbrev=7)" >> $GITHUB_ENV

- name: Build actions-gh-release image
uses: docker/build-push-action@ad44023a93711e3deb337508980b4b5e9bcdc5dc
- name: Build ${{ matrix.image }} image
uses: docker/build-push-action@0565240e2d4ab88bba5387d719585280857ece09 #v5.0.0
with:
context: tool/actions-gh-release
tags: ${{ env.REGISTRY }}/pipe-cd/actions-gh-release:${{ env.PIPECD_VERSION }}

- name: Build actions-plan-preview image
uses: docker/build-push-action@ad44023a93711e3deb337508980b4b5e9bcdc5dc
with:
context: tool/actions-plan-preview
tags: ${{ env.REGISTRY }}/pipe-cd/actions-plan-preview:${{ env.PIPECD_VERSION }}

- name: Build codegen image
uses: docker/build-push-action@ad44023a93711e3deb337508980b4b5e9bcdc5dc
with:
context: tool/codegen
tags: ${{ env.REGISTRY }}/pipe-cd/codegen:${{ env.PIPECD_VERSION }}

- name: Build piped-base image
uses: docker/build-push-action@ad44023a93711e3deb337508980b4b5e9bcdc5dc
with:
context: tool/piped-base
tags: ${{ env.REGISTRY }}/pipe-cd/piped-base:${{ env.PIPECD_VERSION }}

- name: Build piped-base-okd image
uses: docker/build-push-action@ad44023a93711e3deb337508980b4b5e9bcdc5dc
with:
context: tool/piped-base-okd
tags: ${{ env.REGISTRY }}/pipe-cd/piped-base-okd:${{ env.PIPECD_VERSION }}

- name: Build firestore-emulator image
uses: docker/build-push-action@ad44023a93711e3deb337508980b4b5e9bcdc5dc
with:
context: tool/firestore-emulator
tags: ${{ env.REGISTRY }}/pipe-cd/firestore-emulator:${{ env.PIPECD_VERSION }}
context: ${{ matrix.context }}
tags: ${{ env.REGISTRY }}/pipe-cd/${{ matrix.image }}:${{ env.PIPECD_VERSION }}
4 changes: 2 additions & 2 deletions .github/workflows/publish_image_chart.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: publish
name: publish_image_chart

on:
push:
Expand Down Expand Up @@ -103,7 +103,7 @@ jobs:

# Building and pushing container images.
- name: Build and push ${{ matrix.image }} image
uses: docker/build-push-action@ad44023a93711e3deb337508980b4b5e9bcdc5dc
uses: docker/build-push-action@0565240e2d4ab88bba5387d719585280857ece09 #v5.0.0
with:
push: true
context: .
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/publish_site.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: publish
name: publish_site

on:
push:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/publish_tool.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: publish
name: publish_tool

on:
push:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/test_tool.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: test
name: test_tool

on:
push:
Expand Down

0 comments on commit abfa2c6

Please sign in to comment.