-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathcircle.yml
58 lines (56 loc) · 1.39 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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
version: 2
jobs:
build:
working_directory: ~/elastiquartz
docker:
- image: openfresh/java:8u111-jdk
steps:
- checkout
- run:
name: test
command: ./gradlew test
- run:
name: build
command: ./gradlew build
- persist_to_workspace:
root: .
paths:
- .
release:
working_directory: ~/elastiquartz
docker:
- image: java:8u111-jdk
steps:
- attach_workspace:
at: .
- setup_remote_docker:
version: 17.06.0-ce
reusable: true
- run:
name: install Docker clinet
command: |
set -x
VER="17.03.0-ce"
curl -L -o /tmp/docker-$VER.tgz https://get.docker.com/builds/Linux/x86_64/docker-$VER.tgz
tar -xz -C /tmp -f /tmp/docker-$VER.tgz
mv /tmp/docker/* /usr/bin
- run:
name: docker build
command: docker build -t stormcat24/elastiquartz:latest .
- run:
name: docker login
command: docker login -u $DOCKER_USER -p $DOCKER_PASS
- run:
name: release latest
command: docker push stormcat24/elastiquartz:latest
workflows:
version: 2
build_and_release:
jobs:
- build
- release:
requires:
- build
filters:
branches:
only: master