Skip to content
This repository has been archived by the owner on Nov 16, 2019. It is now read-only.

Commit

Permalink
publish artefact
Browse files Browse the repository at this point in the history
  • Loading branch information
ThibautGery committed Aug 9, 2016
1 parent cb42a8b commit ebbd152
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 6 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
node_modules
coverage
cbData
export
10 changes: 4 additions & 6 deletions bin/publish.sh
Original file line number Diff line number Diff line change
Expand Up @@ -23,22 +23,20 @@ echo "##### Import data"
./bin/import

echo "##### Tag images"
docker commit couchbasePublish betagouv/api-meds-db:$VERSION
docker tag api-meds-api betagouv/api-meds-api:$VERSION

docker tag -f betagouv/api-meds-db:$VERSION betagouv/api-meds-db:latest
docker tag -f betagouv/api-meds-api:$VERSION betagouv/api-meds-api:latest

echo "##### Log into docker hub wit $DOCKER_USER"
docker login -e $DOCKER_EMAIL -u $DOCKER_USER -p $DOCKER_PASS


echo "##### Push images"
docker push betagouv/api-meds-db:latest
docker push betagouv/api-meds-api:latest

docker push betagouv/api-meds-db:$VERSION
docker push betagouv/api-meds-api:$VERSION

echo '##### Create backup data'
docker run --link couchbasePublish:couchbase.meds -v $(pwd)/export:/var/export -it couchbase:community cbbackup http://couchbase.meds:8091 /var/export/ -u admin -p tototiti
tar -cvzf meds-db.tar.gz ./export

echo "##### Clean containers"
docker stop couchbasePublish configCbPublish
3 changes: 3 additions & 0 deletions circle.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ machine:
version: 6.3.0
services:
- docker
general:
artifacts:
- meds-db.tar.gz

dependencies:
cache_directories:
Expand Down

0 comments on commit ebbd152

Please sign in to comment.