-
Notifications
You must be signed in to change notification settings - Fork 7
/
.drone.yml
86 lines (76 loc) · 1.74 KB
/
.drone.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
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
name: build
kind: pipeline
type: docker
volumes:
- name: rubygems
host:
path: /home/data/drone/rubygems
- name: images
host:
path: /home/data/drone/images
- name: bundle
host:
path: /home/data/drone/gems
- name: keys
host:
path: /home/data/drone/key_cache
spec_step_common: &spec_step_common
image: abakpress/dind-testing:1.0.3
pull: if-not-exists
privileged: true
volumes:
- name: images
path: /images
- name: bundle
path: /bundle
- name: keys
path: /ssh_keys
commands:
- prepare-build
- fetch-images
--image whilp/ssh-agent
--image abakpress/ruby-app:$RUBY_IMAGE_TAG
- dip ssh add -T -v /ssh_keys -k /ssh_keys/id_rsa
- dip provision
- dip rspec
steps:
- name: Tests Ruby 2.2
environment:
COMPOSE_FILE_EXT: drone
DOCKER_RUBY_VERSION: 2.2
RUBY_IMAGE_TAG: 2.2-latest
RAILS_ENV: test
<<: *spec_step_common
- name: Tests Ruby 2.3
environment:
COMPOSE_FILE_EXT: drone
DOCKER_RUBY_VERSION: 2.3
RUBY_IMAGE_TAG: 2.3-latest
RAILS_ENV: test
<<: *spec_step_common
- name: Tests Ruby 2.4
environment:
COMPOSE_FILE_EXT: drone
DOCKER_RUBY_VERSION: 2.4
RUBY_IMAGE_TAG: 2.4-latest
RAILS_ENV: test
<<: *spec_step_common
- name: Tests Ruby 2.5
environment:
COMPOSE_FILE_EXT: drone
DOCKER_RUBY_VERSION: 2.5
RUBY_IMAGE_TAG: 2.5-latest
RAILS_ENV: test
<<: *spec_step_common
- name: release
image: abakpress/gem-publication:latest
pull: if-not-exists
when:
event: push
branch: master
status: success
volumes:
- name: rubygems
path: /root/.gem
commands:
- release-gem --public