mirror of
https://code.thetadev.de/actions/kaniko.git
synced 2026-04-28 18:51:43 +00:00
fix: backup IFS
This commit is contained in:
@@ -5,6 +5,8 @@ if [ "$INPUT_DEBUG" = "true" ]; then
|
|||||||
set -x
|
set -x
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
OLDIFS=$IFS
|
||||||
|
|
||||||
REGISTRY="${INPUT_REGISTRY:-"docker.io"}"
|
REGISTRY="${INPUT_REGISTRY:-"docker.io"}"
|
||||||
IMAGE="$INPUT_IMAGE"
|
IMAGE="$INPUT_IMAGE"
|
||||||
BRANCH=$(echo "$GITHUB_REF" | sed -E "s/refs\/(heads|tags)\///g" | sed -e "s/\//-/g")
|
BRANCH=$(echo "$GITHUB_REF" | sed -E "s/refs\/(heads|tags)\///g" | sed -e "s/\//-/g")
|
||||||
@@ -74,9 +76,11 @@ crane auth login "$REGISTRY" -u "$USERNAME" -p "$PASSWORD"
|
|||||||
runKaniko() {
|
runKaniko() {
|
||||||
# https://github.com/GoogleContainerTools/kaniko/issues/1803
|
# https://github.com/GoogleContainerTools/kaniko/issues/1803
|
||||||
# https://github.com/GoogleContainerTools/kaniko/issues/1349
|
# https://github.com/GoogleContainerTools/kaniko/issues/1349
|
||||||
|
IFS=''
|
||||||
kaniko_cmd="executor ${1} --reproducible --force"
|
kaniko_cmd="executor ${1} --reproducible --force"
|
||||||
echo "Running kaniko command: ${kaniko_cmd}"
|
echo "Running kaniko command: ${kaniko_cmd}"
|
||||||
IFS='' eval "${kaniko_cmd}"
|
eval "${kaniko_cmd}"
|
||||||
|
IFS=$OLDIFS
|
||||||
}
|
}
|
||||||
|
|
||||||
if [ -n "$INPUT_PLATFORMS" ]; then
|
if [ -n "$INPUT_PLATFORMS" ]; then
|
||||||
|
|||||||
Reference in New Issue
Block a user