This repository has been archived by the owner on Dec 3, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 79
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
WIP converting image build logic to pure GH actions
Signed-off-by: Matt Oswalt <[email protected]>
- Loading branch information
Showing
10 changed files
with
350 additions
and
80 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
#!/usr/bin/env bash | ||
|
||
set -e +o pipefail | ||
|
||
if [ -z "$1" ] | ||
then | ||
echo "Must pass JSON array of image names as first parameter to this script" | ||
fi | ||
|
||
if [ -z "$2" ] | ||
then | ||
echo "Must provide source tag as second parameter to this script" | ||
fi | ||
|
||
if [ -z "$3" ] | ||
then | ||
echo "Must provide preview ID as third parameter to this script" | ||
fi | ||
|
||
wget -q "https://raw.githubusercontent.com/nre-learning/docker-retag/d702a5a109af5e8f04baea2c80782dc107142f19/docker-retag" && chmod +x docker-retag | ||
|
||
for row in $(echo "$1" | jq -r '.[] | @base64'); do | ||
_getimage() { | ||
echo ${row} | base64 --decode | ||
} | ||
|
||
image=$(_getimage) | ||
|
||
if [ "$image" != "empty" ]; | ||
then | ||
$(pwd)/docker-retag antidotelabs/$image:$2 preview-$3 | ||
fi | ||
done | ||
|
||
rm -f $(pwd)/docker-retag |
File renamed without changes.
Oops, something went wrong.