File tree Expand file tree Collapse file tree 4 files changed +21
-12
lines changed
Expand file tree Collapse file tree 4 files changed +21
-12
lines changed Original file line number Diff line number Diff line change 11services :
22 - docker
33
4+ env :
5+ - DOCKER_ORG='opensciencegrid' DOCKER_REPOS='xcache stash-cache stash-origin atlas-xcache cms-xcache'
6+
47script :
5- - ./travis/build_docker.sh
6- - ./travis/test_stashcache_origin.sh
7- - ./travis/test_stashcache.sh
8- - ./travis/push_docker.sh
8+ - ./travis/travis-wrapper.sh
99
1010branches :
1111 only :
Original file line number Diff line number Diff line change 11#! /bin/bash -xe
22# Script for building and pushing XCache docker images
33
4- org=' opensciencegrid'
5- timestamp=` date +%Y%m%d-%H%M`
6- docker_repos=' xcache stash-cache stash-origin atlas-xcache cms-xcache'
4+ timestamp=" $1 "
75
8- for repo in $docker_repos ; do
6+ for repo in $DOCKER_REPOS ; do
97 docker build \
10- -t $org /$repo :fresh \
11- -t $org /$repo :$timestamp \
8+ -t $DOCKER_ORG /$repo :fresh \
9+ -t $DOCKER_ORG /$repo :$timestamp \
1210 $repo
1311done
1412
Original file line number Diff line number Diff line change @@ -6,11 +6,13 @@ if [[ "${TRAVIS_PULL_REQUEST}" != "false" ]]; then
66 exit 0
77fi
88
9+ timestamp=" $1 "
10+
911# Credentials for docker push
1012echo " $DOCKER_PASSWORD " | docker login -u " $DOCKER_USERNAME " --password-stdin
1113
12- for repo in $docker_repos ; do
14+ for repo in $DOCKER_REPOS ; do
1315 for tag in $timestamp fresh; do
14- docker push $org /$repo :$tag
16+ docker push $DOCKER_ORG /$repo :$tag
1517 done
1618done
Original file line number Diff line number Diff line change 1+ #! /bin/bash -xe
2+ # Wrapper script for building and testing XCache container images
3+
4+ timestamp=` date +%Y%m%d-%H%M`
5+
6+ ./travis/build_docker.sh $timestamp
7+ ./travis/test_stashcache_origin.sh
8+ ./travis/test_stashcache.sh
9+ ./travis/push_docker.sh $timestamp
You can’t perform that action at this time.
0 commit comments