forked from INGInious/containers
-
Notifications
You must be signed in to change notification settings - Fork 0
/
push-registry-images.sh
executable file
·56 lines (52 loc) · 2.17 KB
/
push-registry-images.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
#!/usr/bin/env bash
set -e
tag="latest";
while getopts ":t:" opt; do
case $opt in
t)
echo "tag flag was triggered, Tag: $OPTARG" >&2;
tag="$OPTARG"
;;
\?)
echo "Invalid option: -$OPTARG" >&2
exit 1
;;
:)
echo "Option -$OPTARG requires an argument." >&2
exit 1
;;
esac
done
read -p "Are you sure to push main container images with tag:"$tag" ? " -n 1 -r
echo # (optional) move to a new line
if [[ $REPLY =~ ^[Yy]$ ]]
then
echo "-------------------------------------------------------"
echo "- Pushing registry image: inginious-c-base:"$tag""
echo "-------------------------------------------------------"
docker push unjudge/inginious-c-base:"$tag"
echo "-------------------------------------------------------"
echo "- Pushing registry image: inginious-c-default:"$tag""
echo "-------------------------------------------------------"
docker push unjudge/inginious-c-default:"$tag"
echo "-------------------------------------------------------"
echo "- Pushing registry image: uncode-c-base:"$tag""
echo "-------------------------------------------------------"
docker push unjudge/uncode-c-base:"$tag"
echo "-------------------------------------------------------"
echo "- Pushing registry image: inginious-c-multilang:"$tag""
echo "-------------------------------------------------------"
docker push unjudge/inginious-c-multilang:"$tag"
echo "-------------------------------------------------------"
echo "- Pushing registry image: inginious-c-datascience:"$tag""
echo "-------------------------------------------------------"
docker push unjudge/inginious-c-datascience:"$tag"
echo "-------------------------------------------------------"
echo "- Pushing registry image: hdl-uncode:"$tag""
echo "-------------------------------------------------------"
docker push unjudge/hdl-uncode:"$tag"
echo "-------------------------------------------------------"
echo "- Pushing registry image: inginious-c-notebook:"$tag""
echo "-------------------------------------------------------"
docker push unjudge/inginious-c-notebook:"$tag"
fi