Skip to content

Commit b4bee6f

Browse files
committed
I apolog
0 parents  commit b4bee6f

File tree

2 files changed

+59
-0
lines changed

2 files changed

+59
-0
lines changed
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
name: Create Docker Image
2+
3+
on:
4+
workflow_call:
5+
inputs:
6+
commit-ish:
7+
description: 'イメージを作りたいワークツリーを持つタグ名やコミットハッシュを指定する'
8+
type: string
9+
required: true
10+
target-component-name:
11+
description: '対象とするコンポーネント'
12+
type: string
13+
required: true
14+
workflow_dispatch:
15+
inputs:
16+
commit-ish:
17+
description: 'イメージを作りたいワークツリーを持つタグ名やコミットハッシュを指定する'
18+
type: string
19+
required: true
20+
21+
jobs:
22+
sample-job:
23+
runs-on: ubuntu-latest
24+
steps:
25+
- uses: actions/checkout@v4
26+
27+
- name: Create Docker Image
28+
run: echo "Create Docker Image ${{ inputs.commit-ish }} ${{ inputs.target-component-name }}"
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
name: Check Dockerfile Changes and Build
2+
3+
on:
4+
push:
5+
tags:
6+
- 'v*'
7+
8+
jobs:
9+
check-dockerfile-changes:
10+
runs-on: ubuntu-latest
11+
outputs:
12+
dockerfile_changed: ${{ steps.check-changes.outputs.dockerfile_changed }}
13+
14+
steps:
15+
- name: Checkout repository
16+
uses: actions/checkout@v4
17+
18+
- name: Check for Dockerfile changes
19+
id: check-changes
20+
run: |
21+
echo "dockerfile_changed=[\"hoge\", \"mogu\"]" >> $GITHUB_OUTPUT
22+
23+
call-docker-build:
24+
needs: check-dockerfile-changes
25+
strategy:
26+
matrix:
27+
target: ${{ fromJson(needs.check-dockerfile-changes.outputs.dockerfile_changed) }}
28+
uses: ./.github/workflows/create-docker-image.yml
29+
with:
30+
target-component-name: ${{ matrix.target }}
31+
commit-ish: ${{ github.ref }}

0 commit comments

Comments
 (0)