File tree Expand file tree Collapse file tree 1 file changed +6
-5
lines changed
Expand file tree Collapse file tree 1 file changed +6
-5
lines changed Original file line number Diff line number Diff line change @@ -12,11 +12,6 @@ BUILDCTL_OPTS="$@"
1212DEFAULT_REGISTRY=builds-registry.ystack.svc.cluster.local
1313[ -z " $BUILDS_REGISTRY " ] && BUILDS_REGISTRY=$DEFAULT_REGISTRY
1414[ -z " $PUSH_REGISTRY " ] && PUSH_REGISTRY=$DEFAULT_REGISTRY
15- [ -z " $BUILDKIT_CACHE " ] && BUILDKIT_CACHE=" type=registry,ref=$BUILDS_REGISTRY /ystack:buildcache"
16- [ -z " $IMPORT_CACHE " ] && IMPORT_CACHE=" --import-cache=$BUILDKIT_CACHE "
17- [ -z " $EXPORT_CACHE " ] && EXPORT_CACHE=" --export-cache=$BUILDKIT_CACHE ,mode=max"
18- [ " $IMPORT_CACHE " = " false" ] && IMPORT_CACHE=" "
19- [ " $EXPORT_CACHE " = " false" ] && EXPORT_CACHE=" "
2015[ -z " $BUILDKIT_HOST " ] && BUILDKIT_HOST=tcp://buildkitd.ystack.svc.cluster.local:8547
2116
2217if [ " $( curl -s --connect-timeout 3 http://$BUILDS_REGISTRY /v2/) " != " {}" ]
@@ -65,6 +60,12 @@ if [[ ! -z "$GIT_COMMIT" ]]; then
6560 fi
6661fi
6762
63+ [ -z " $BUILDKIT_CACHE " ] && BUILDKIT_CACHE=" type=registry,ref=$( echo $IMAGE | sed ' s|/|/ystack-buildcache/|' | sed s/:$BUILD_TAG //) "
64+ [ -z " $IMPORT_CACHE " ] && IMPORT_CACHE=" --import-cache=$BUILDKIT_CACHE "
65+ [ -z " $EXPORT_CACHE " ] && EXPORT_CACHE=" --export-cache=$BUILDKIT_CACHE ,mode=max"
66+ [ " $IMPORT_CACHE " = " false" ] && IMPORT_CACHE=" "
67+ [ " $EXPORT_CACHE " = " false" ] && EXPORT_CACHE=" "
68+
6869echo " Build command:"
6970set -x
7071y-buildctl \
You can’t perform that action at this time.
0 commit comments