-
Notifications
You must be signed in to change notification settings - Fork 0
/
circle.yml
91 lines (86 loc) · 3.79 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
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
87
88
89
90
91
machine:
pre:
- gem update --system 2.7.6
- curl -sSL https://s3.amazonaws.com/circle-downloads/install-circleci-docker.sh | bash -s -- 1.10.0
environment:
LOCALDEV: true
DDSURL: http://0.0.0.0:3001
COMPOSE_FILE: 'docker-compose.circle.yml:docker-compose.swift.yml'
GRAPHENEDB_URL: http://neo4j.db.host:7474
BONSAI_URL: elastic.local:9200
CLOUDAMQP_URL: amqp://rabbitmq.local:12345
OPENID_CLIENT_ID: test
OPENID_CLIENT_SECRET: testpass
OPENID_URL: http://oit.oauth.edu
hosts:
swift.local: 0.0.0.0
neo4j.db.host: 0.0.0.0
elastic.local: 0.0.0.0
rabbitmq.local: 0.0.0.0
services:
- docker
# Version of ruby to use
ruby:
version:
2.6.3
dependencies:
cache_directories:
- "docker/circle"
pre:
- ./docker/circle/cache_docker_image.sh neo4j 3.1.6
- ./docker/circle/cache_docker_image.sh elasticsearch 5.4.3
- ./docker/circle/cache_docker_image.sh rabbitmq 3.5-management
# - curl -L https://github.com/stedolan/jq/releases/download/jq-1.5/jq-linux64 > jq; sudo mv jq /usr/bin/jq; sudo chmod +x /usr/bin/jq
- sudo apt-get install python-dev
- sudo pip install --upgrade docker-compose==1.8.0
- docker-compose up -d neo4j elasticsearch rabbitmq
database:
post:
- bundle exec rake neo4j:schema:load --trace
deployment:
development:
branch: develop
commands:
- wget -qO- https://cli-assets.heroku.com/install-ubuntu.sh | sh
- heroku maintenance:on --app 'dukeds-dev'
# - heroku run --exit-code rake assets:clobber --app 'dukeds-dev'
- "[[ ! -s \"$(git rev-parse --git-dir)/shallow\" ]] || git fetch --unshallow"
- git push [email protected]:dukeds-dev.git $CIRCLE_SHA1:refs/heads/master:
timeout: 54000
- heroku run rake --exit-code db:migrate --app 'dukeds-dev'
- heroku run --exit-code rake neo4j:schema:load --app 'dukeds-dev'
- heroku run rake --exit-code db:seed --app 'dukeds-dev'
- heroku run --exit-code rake db:data:migrate --app 'dukeds-dev'
- heroku run --exit-code rake elasticsearch:index:rebuild --app 'dukeds-dev'
- heroku config:unset RECREATE_SEARCH_MAPPINGS --app 'dukeds-dev'
- heroku maintenance:off --app 'dukeds-dev'
ua_test:
branch: ua_test
commands:
- wget -qO- https://cli-assets.heroku.com/install-ubuntu.sh | sh
- heroku maintenance:on --app 'dukeds-uatest'
# - heroku run --exit-code rake assets:clobber --app 'dukeds-uatest'
- "[[ ! -s \"$(git rev-parse --git-dir)/shallow\" ]] || git fetch --unshallow"
- git push [email protected]:dukeds-uatest.git $CIRCLE_SHA1:refs/heads/master:
timeout: 54000
- heroku run --exit-code rake db:migrate --app 'dukeds-uatest'
- heroku run --exit-code rake neo4j:schema:load --app 'dukeds-uatest'
- heroku run --exit-code rake db:seed --app 'dukeds-uatest'
- heroku run --exit-code rake db:data:migrate --app 'dukeds-uatest'
- heroku run --exit-code rake elasticsearch:index:rebuild --app 'dukeds-uatest'
- heroku config:unset RECREATE_SEARCH_MAPPINGS --app 'dukeds-uatest'
- heroku maintenance:off --app 'dukeds-uatest'
production:
branch: production
commands:
- wget -qO- https://cli-assets.heroku.com/install-ubuntu.sh | sh
# - heroku run --exit-code rake assets:clobber --app 'dukeds'
- "[[ ! -s \"$(git rev-parse --git-dir)/shallow\" ]] || git fetch --unshallow"
- git push [email protected]:dukeds.git $CIRCLE_SHA1:refs/heads/master:
timeout: 54000
- heroku run --exit-code rake db:migrate --app 'dukeds'
- heroku run --exit-code rake neo4j:schema:load --app 'dukeds'
- heroku run --exit-code rake db:seed --app 'dukeds'
- heroku run --exit-code rake db:data:migrate --app 'dukeds'
- heroku run --exit-code rake elasticsearch:index:rebuild --app 'dukeds'
- heroku config:unset RECREATE_SEARCH_MAPPINGS --app 'dukeds'