mirror of
https://github.com/containers/podman.git
synced 2025-06-29 15:08:09 +08:00
Merge pull request #21777 from cevich/fix_mac_clone
Cirrus: Reuse shared clone script on Mac
This commit is contained in:
@ -133,6 +133,7 @@ build_task:
|
|||||||
# the 'origin' remote must be defined, and all remote branches/tags
|
# the 'origin' remote must be defined, and all remote branches/tags
|
||||||
# must be available for reference from CI scripts.
|
# must be available for reference from CI scripts.
|
||||||
clone_script: &full_clone |
|
clone_script: &full_clone |
|
||||||
|
set -exuo pipefail
|
||||||
cd /
|
cd /
|
||||||
rm -rf $CIRRUS_WORKING_DIR
|
rm -rf $CIRRUS_WORKING_DIR
|
||||||
mkdir -p $CIRRUS_WORKING_DIR
|
mkdir -p $CIRRUS_WORKING_DIR
|
||||||
@ -145,10 +146,6 @@ build_task:
|
|||||||
else
|
else
|
||||||
git reset --hard $CIRRUS_CHANGE_IN_REPO
|
git reset --hard $CIRRUS_CHANGE_IN_REPO
|
||||||
fi
|
fi
|
||||||
# Some test operations & checks require a git "identity"
|
|
||||||
_gc='git config --file /root/.gitconfig'
|
|
||||||
$_gc user.email "TMcTestFace@example.com"
|
|
||||||
$_gc user.name "Testy McTestface"
|
|
||||||
# Attempt to prevent flakes by confirming basic environment expectations,
|
# Attempt to prevent flakes by confirming basic environment expectations,
|
||||||
# network service connectivity and essential container image availability.
|
# network service connectivity and essential container image availability.
|
||||||
prebuild_script: &prebuild $SCRIPT_BASE/prebuild.sh
|
prebuild_script: &prebuild $SCRIPT_BASE/prebuild.sh
|
||||||
@ -462,6 +459,7 @@ osx_alt_build_task:
|
|||||||
GOCACHE: "$CIRRUS_WORKING_DIR/.go/cache"
|
GOCACHE: "$CIRRUS_WORKING_DIR/.go/cache"
|
||||||
GOENV: "$CIRRUS_WORKING_DIR/.go/support"
|
GOENV: "$CIRRUS_WORKING_DIR/.go/support"
|
||||||
GOSRC: "$HOME/ci/task-${CIRRUS_TASK_ID}"
|
GOSRC: "$HOME/ci/task-${CIRRUS_TASK_ID}"
|
||||||
|
clone_script: *full_clone
|
||||||
# This host is/was shared with potentially many other CI tasks.
|
# This host is/was shared with potentially many other CI tasks.
|
||||||
# The previous task may have been canceled or aborted.
|
# The previous task may have been canceled or aborted.
|
||||||
prep_script: &mac_cleanup "contrib/cirrus/mac_cleanup.sh"
|
prep_script: &mac_cleanup "contrib/cirrus/mac_cleanup.sh"
|
||||||
|
@ -31,3 +31,10 @@ echo "TMPDIR=/private/tmp/ci" >> $CIRRUS_ENV
|
|||||||
|
|
||||||
# Removed completely during cleanup.
|
# Removed completely during cleanup.
|
||||||
mkdir -p /private/tmp/ci
|
mkdir -p /private/tmp/ci
|
||||||
|
|
||||||
|
# Some test operations & checks require a git "identity"
|
||||||
|
# N/B: $HOME in this context does not include the /ci part automatically
|
||||||
|
# (see above) but it will when the next Cirrus-CI "_script" section
|
||||||
|
# takes over.
|
||||||
|
git config --file "$HOME/ci/.gitconfig" \
|
||||||
|
--add safe.directory $CIRRUS_WORKING_DIR
|
||||||
|
@ -40,12 +40,8 @@ done
|
|||||||
|
|
||||||
cp hack/podman-registry /bin
|
cp hack/podman-registry /bin
|
||||||
|
|
||||||
# Some test operations & checks require a git "identity"
|
|
||||||
_gc='git config --file /root/.gitconfig'
|
|
||||||
showrun $_gc user.email "TMcTestFace@example.com"
|
|
||||||
showrun $_gc user.name "Testy McTestface"
|
|
||||||
# Bypass git safety/security checks when operating in a throwaway environment
|
# Bypass git safety/security checks when operating in a throwaway environment
|
||||||
showrun git config --system --add safe.directory $GOSRC
|
showrun git config --global --add safe.directory $GOSRC
|
||||||
|
|
||||||
# Ensure that all lower-level contexts and child-processes have
|
# Ensure that all lower-level contexts and child-processes have
|
||||||
# ready access to higher level orchestration (e.g Cirrus-CI)
|
# ready access to higher level orchestration (e.g Cirrus-CI)
|
||||||
|
Reference in New Issue
Block a user