summaryrefslogtreecommitdiff
path: root/contrib/cirrus/lib.sh
diff options
context:
space:
mode:
authorChris Evich <cevich@redhat.com>2019-05-10 19:02:01 -0400
committerChris Evich <cevich@redhat.com>2019-07-03 16:51:21 -0400
commit1ef8637ae31fa63f98e5edd32e01b090fd66c832 (patch)
treebd3f58288c0b0c33611325eacec245310df21880 /contrib/cirrus/lib.sh
parentf5593d305f68409cf093ea6b66a9d1f121ec0fd6 (diff)
downloadpodman-1ef8637ae31fa63f98e5edd32e01b090fd66c832.tar.gz
podman-1ef8637ae31fa63f98e5edd32e01b090fd66c832.tar.bz2
podman-1ef8637ae31fa63f98e5edd32e01b090fd66c832.zip
Cirrus: Automate releasing of tested binaries
It's desirable to make archives available of builds containing actual tested content. While not official distro-releases, these will enable third-party testing, experimentation, and development for both branches (e.g. "master") and pull requests (e.g. "pr3106"). * Add a Makefile targets for archiving both regular podman binaries and the remote-client. Encode release metadata within these archives so that their exact source can be identified. * Fix bug with cross-compiling remote clients for the Windows and Darwin platforms. * Add unit-testing of cross-compiles for Windows and Darwin platforms. * A few small CI-script typo-fixes * Add a script which operates in two modes: 1. Call Makefile targets which produce release archives. Upload the archive to Cirrus-CI's built-in caching system using reproducible cache keys. 2. Utilize reproduced cache keys to attempt download of cache from each tasks. When successful, parse the file's release metadata, using it to name the archive file. Upload all recovered archives to a publicly accessible storage bucket for future reference. * Update the main testing task to call the script in mode #1 for all primary platforms. * Add a new `$SPECIALMODE` task to call the script in mode #1 for Windows and Darwin targets. * Add a new 'release' task to the CI system, dependent upon all other tasks. This new tasks executes the script in mode #2. * Update CI documentation Signed-off-by: Chris Evich <cevich@redhat.com>
Diffstat (limited to 'contrib/cirrus/lib.sh')
-rw-r--r--contrib/cirrus/lib.sh10
1 files changed, 7 insertions, 3 deletions
diff --git a/contrib/cirrus/lib.sh b/contrib/cirrus/lib.sh
index 36751fbd7..67e858526 100644
--- a/contrib/cirrus/lib.sh
+++ b/contrib/cirrus/lib.sh
@@ -18,9 +18,8 @@ if type -P go &> /dev/null
then
# required for go 1.12+
export GOCACHE="${GOCACHE:-$HOME/.cache/go-build}"
- eval "$(go env)"
- # required by make and other tools
- export $(go env | cut -d '=' -f 1)
+ # called processes like `make` and other tools need these vars.
+ eval "export $(go env)"
# Ensure compiled tooling is reachable
export PATH="$PATH:$GOPATH/bin"
@@ -160,6 +159,11 @@ die() {
exit ${1:-1}
}
+warn() {
+ echo ">>>>> ${2:-WARNING (but no message given!) in ${FUNCNAME[1]}()}" > /dev/stderr
+ echo ${1:-1} > /dev/stdout
+}
+
bad_os_id_ver() {
echo "Unknown/Unsupported distro. $OS_RELEASE_ID and/or version $OS_RELEASE_VER for $(basename $0)"
exit 42