File tree Expand file tree Collapse file tree 2 files changed +24
-5
lines changed Expand file tree Collapse file tree 2 files changed +24
-5
lines changed Original file line number Diff line number Diff line change @@ -188,7 +188,10 @@ jobs:
188
188
strategy :
189
189
fail-fast : false
190
190
matrix :
191
- target-stage :
191
+ base :
192
+ - ' '
193
+ - alpine
194
+ target :
192
195
- ' '
193
196
- rootless
194
197
steps :
@@ -221,9 +224,10 @@ jobs:
221
224
./hack/images "${{ needs.prepare.outputs.tag }}" "$IMAGE_NAME" "${{ needs.prepare.outputs.push }}"
222
225
env :
223
226
RELEASE : ${{ github.ref == 'refs/heads/master' || startsWith(github.ref, 'refs/tags/v') }}
224
- TARGET : ${{ matrix.target-stage }}
225
- CACHE_FROM : type=gha,scope=image${{ matrix.target-stage }}
226
- CACHE_TO : type=gha,scope=image${{ matrix.target-stage }}
227
+ BASE : ${{ matrix.base }}
228
+ TARGET : ${{ matrix.target }}
229
+ CACHE_FROM : type=gha,scope=image${{ matrix.target }}
230
+ CACHE_TO : type=gha,scope=image${{ matrix.target }}
227
231
GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
228
232
229
233
scout :
Original file line number Diff line number Diff line change @@ -9,6 +9,7 @@ set -eu -o pipefail
9
9
10
10
: " ${RELEASE=false} "
11
11
: " ${PLATFORMS=} "
12
+ : " ${BASE=} "
12
13
: " ${TARGET=} "
13
14
14
15
versionTag=$( git describe --always --tags --match " v[0-9]*" )
@@ -70,16 +71,30 @@ if [ -n "$TARGET" ]; then
70
71
targetFlag=" --target=$TARGET "
71
72
fi
72
73
74
+ exportBaseArg=" "
75
+ if [ -n " $BASE " ]; then
76
+ exportBaseArg=" --build-arg=EXPORT_BASE=$BASE "
77
+ fi
78
+
73
79
tagNames=" $REPO :$TAG "
74
80
if [ -n " $TARGET " ]; then
75
81
tagNames=" $tagNames -$TARGET "
76
82
fi
83
+ if [ -n " $BASE " ]; then
84
+ tagNames=" $tagNames -$BASE "
85
+ fi
77
86
78
87
if [[ " $versionTag " == " $TAG " ]]; then
79
88
if [ -n " $TARGET " ]; then
80
89
tagNames=" $tagNames $REPO :$TARGET "
90
+ if [ -n " $BASE " ]; then
91
+ tagNames=" $tagNames -$BASE "
92
+ fi
81
93
else
82
94
tagNames=" $tagNames $REPO :latest"
95
+ if [ -n " $BASE " ]; then
96
+ tagNames=" $tagNames -$BASE "
97
+ fi
83
98
fi
84
99
fi
85
100
@@ -111,5 +126,5 @@ if [[ "$RELEASE" = "true" ]] && [[ "$GITHUB_ACTIONS" = "true" ]]; then
111
126
nocacheFilterFlag=" --no-cache-filter=buildkit-export,gobuild-base,rootless"
112
127
fi
113
128
114
- buildxCmd build --build-arg " BUILDKIT_CONTEXT_KEEP_GIT_DIR=1" --build-arg BUILDKITD_TAGS --build-arg BUILDKIT_DEBUG --build-arg EXPORT_BASE $platformFlag $targetFlag $importCacheFlags $exportCacheFlags $tagFlags $outputFlag $nocacheFilterFlag $attestFlags \
129
+ buildxCmd build --build-arg " BUILDKIT_CONTEXT_KEEP_GIT_DIR=1" --build-arg BUILDKITD_TAGS --build-arg BUILDKIT_DEBUG $exportBaseArg $platformFlag $targetFlag $importCacheFlags $exportCacheFlags $tagFlags $outputFlag $nocacheFilterFlag $attestFlags \
115
130
$currentcontext
You can’t perform that action at this time.
0 commit comments