-
Notifications
You must be signed in to change notification settings - Fork 2.5k
Expand file tree
/
Copy pathconfig.yml
More file actions
27 lines (27 loc) · 923 Bytes
/
config.yml
File metadata and controls
27 lines (27 loc) · 923 Bytes
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
version: 2
jobs:
build:
working_directory: /dockerapp
docker:
- image: docker:17.05.0-ce-git
steps:
- checkout
- setup_remote_docker
- run:
name: Install dependencies
command: |
apk add --no-cache py-pip=9.0.0-r1
pip install docker-compose==1.15.0
- run:
name: Run tests
command: |
docker-compose up -d
docker-compose run dockerapp python test.py
- deploy:
name: Push application Docker image
command: |
docker login -u $DOCKER_HUB_USER_ID -p $DOCKER_HUB_PWD
docker tag dockerapp_dockerapp $DOCKER_HUB_USER_ID/dockerapp:$CIRCLE_SHA1
docker tag dockerapp_dockerapp $DOCKER_HUB_USER_ID/dockerapp:latest
docker push $DOCKER_HUB_USER_ID/dockerapp:$CIRCLE_SHA1
docker push $DOCKER_HUB_USER_ID/dockerapp:latest