-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathcircle.yml
44 lines (37 loc) · 1.17 KB
/
circle.yml
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
machine:
services:
- docker
environment:
RELEASE: 0.1.${CIRCLE_BUILD_NUM}
MAVEN_OPTS: "-Xmx1g -DbuildNumber=${CIRCLE_BUILD_NUM} "
JAVA_HOME: /usr/lib/jvm/jdk1.8.0
java:
version: oraclejdk8
dependencies:
cache_directories:
- "~/docker"
override:
- cd ~ && git clone https://github.com/sillelien/build-utils.git && chmod a+x ~/build-utils/*.sh
- sudo -H pip install docker-compose
- docker login -e $DOCKER_EMAIL -u $DOCKER_USER -p $DOCKER_PASS
- ./build.sh
- docker build -t sillelien/scheduler:${CIRCLE_BRANCH} .
test:
override:
- docker run -d sillelien/scheduler:${CIRCLE_BRANCH}
deployment:
staging:
branch: staging
commands:
- ~/build-utils/promote_from_staging.sh
production:
branch: master
commands:
- docker tag sillelien/scheduler:${CIRCLE_BRANCH} sillelien/scheduler
- docker push sillelien/scheduler
- docker tag sillelien/scheduler sillelien/scheduler:$(cat .release)
- docker push sillelien/scheduler:$(cat .release)
development:
branch: dev
commands:
- docker push sillelien/scheduler:${CIRCLE_BRANCH}