Compare commits
3 commits
27742db4fb
...
24560d2370
Author | SHA1 | Date | |
---|---|---|---|
|
24560d2370 | ||
|
faf55deb84 | ||
|
8e5b0ce928 |
3
.gitignore
vendored
3
.gitignore
vendored
|
@ -2,3 +2,6 @@
|
|||
.env
|
||||
# emacs
|
||||
*~
|
||||
|
||||
django-orchestra
|
||||
django-musician
|
||||
|
|
27
Makefile
27
Makefile
|
@ -1,12 +1,27 @@
|
|||
project := dkr-dsg.ac.upc.edu/trustchain-oc1-orchestral
|
||||
|
||||
branch := `git branch --show-current`
|
||||
commit := `git log -1 --format=%h`
|
||||
tag := ${branch}__${commit}
|
||||
|
||||
# docker images
|
||||
orchestra_image := ${project}/orchestra:${tag}
|
||||
musician_image := ${project}/musician:${tag}
|
||||
# docker images
|
||||
|
||||
orchestra_branch := `git -C django-orchestra branch --show-current`
|
||||
orchestra_commit := `git -C django-orchestra log -1 --format=%h`
|
||||
orchestra_tag := ${orchestra_branch}__${orchestra_commit}
|
||||
orchestra_image := ${project}/orchestra:${orchestra_tag}
|
||||
|
||||
musician_branch := `git -C django-musician branch --show-current`
|
||||
musician_commit := `git -C django-musician log -1 --format=%h`
|
||||
musician_tag := ${orchestra_branch}__${musician_commit}
|
||||
musician_image := ${project}/musician:${musician_tag}
|
||||
|
||||
orchestra_branch := `git -C django-orchestra branch --show-current`
|
||||
orchestra_commit := `git -C django-orchestra log -1 --format=%h`
|
||||
orchestra_tag := ${orchestra_branch}__${orchestra_commit}
|
||||
orchestra_image := ${project}/orchestra:${orchestra_tag}
|
||||
|
||||
musician_branch := `git -C django-musician branch --show-current`
|
||||
musician_commit := `git -C django-musician log -1 --format=%h`
|
||||
musician_tag := ${orchestra_branch}__${musician_commit}
|
||||
musician_image := ${project}/musician:${musician_tag}
|
||||
|
||||
docker_build:
|
||||
docker build -f docker/orchestra.Dockerfile -t ${orchestra_image} .
|
||||
|
|
|
@ -3,7 +3,7 @@ services:
|
|||
|
||||
orchestra:
|
||||
init: true
|
||||
image: dkr-dsg.ac.upc.edu/trustchain-oc1-orchestral/orchestra:add_musician__95b0ed93
|
||||
image: dkr-dsg.ac.upc.edu/trustchain-oc1-orchestral/orchestra:sso__533d749
|
||||
environment:
|
||||
- SECRET_KEY=${ORCHESTRA_SECRET_KEY:-123456}
|
||||
ports:
|
||||
|
@ -14,7 +14,7 @@ services:
|
|||
|
||||
musician:
|
||||
init: true
|
||||
image: dkr-dsg.ac.upc.edu/trustchain-oc1-orchestral/musician:add_musician__95b0ed93
|
||||
image: dkr-dsg.ac.upc.edu/trustchain-oc1-orchestral/musician:sso__addc4fe
|
||||
ports:
|
||||
- "8080:8080"
|
||||
environment:
|
||||
|
|
31
pull-repos.sh
Executable file
31
pull-repos.sh
Executable file
|
@ -0,0 +1,31 @@
|
|||
#!/bin/sh
|
||||
|
||||
set -e
|
||||
set -u
|
||||
# DEBUG
|
||||
set -x
|
||||
|
||||
# clone or pull git repo
|
||||
_pull() {
|
||||
myurl="${1}"
|
||||
mydir="$(basename "${myurl}")"
|
||||
mybranch="${2}"
|
||||
|
||||
if [ -d "${mydir}" ]; then
|
||||
cd "${mydir}"
|
||||
git checkout "${mybranch}"
|
||||
git pull
|
||||
cd -
|
||||
else
|
||||
git clone "${myurl}" "${mydir}"
|
||||
fi
|
||||
}
|
||||
|
||||
|
||||
main() {
|
||||
_pull 'https://gitea.pangea.org/pangea/django-orchestra' 'sso'
|
||||
_pull 'https://gitea.pangea.org/pangea/django-musician' 'sso'
|
||||
}
|
||||
|
||||
main "${@}"
|
||||
|
Reference in a new issue