Skip to content

Commit f7e39e6

Browse files
committed
Merge remote-tracking branch 'origin/master' into SAN-3043-cache
* origin/master: (101 commits) Update main.yml run khronos at 10:30 am add mavis to khronos configs Freude, schöner Götterfunken Tochter aus Elysium... navi mongodb and navi connecting to services really fixed this time typo in key mgmt task for hipache add new swarm certs Ignore private keys see if this merges with anand's change sort configs, add krain and filibuster sync delta and prod configs, add log to registy Added metis to delta. add certs to hipache deploy Began work on new delta staging environment. old bastion for beta ressurected temporarily Added delta vault config. whoopsies Fix delta docks inventory lookup. Added suaron host, removed empty docks. ...
2 parents 91f633d + 89f61c1 commit f7e39e6

68 files changed

Lines changed: 1533 additions & 89 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.gitignore

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,10 @@
11
node_modules
2-
ca-key.pem
2+
*.pem
33
pass
44
hellorunnable
55
dump.rdb
66
erl_crash.dump
77
npm-debug.log
8+
ca.srl
9+
.DS_Store
10+
ansible/roles/hipache/templates/runnable*

README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,8 @@ If, for some reason, the new deploy is not operating as expected you can quickly
7373

7474
It is the custom at Runnable to play a song to the entire team when deploying. For each of the repositories here are the respective songs:
7575

76+
*NEW JUAREZ* [stack: The Cleveland Orchestra (George Szell conducting) Ludwig von Beethoven Symphony No. 9 "Chorale (Ode To Joy)" Opus 125 IV. Presto; Allegro molto assai (Alla marcia); Andante maestroso; Allegro energico, sempre ben marcato.] (https://www.youtube.com/watch?v=4g5770gaais)
77+
7678
[api: Push it - Rick Ross](https://www.youtube.com/watch?v=qk2jeE1LOn8)
7779

7880
[runnable-angular: Push it to the limit - Scarface](https://www.youtube.com/watch?v=9D-QD_HIfjA)
@@ -101,4 +103,6 @@ It is the custom at Runnable to play a song to the entire team when deploying. F
101103

102104
[vault / vault-values: Seal - Kiss From A Rose](https://www.youtube.com/watch?v=zP3so2hY4CM)
103105

106+
[Sauron: Sauron theme song from LOTR](https://www.youtube.com/watch?v=V_rk9VBrXMY)
107+
104108
**IMPORTANT:** Make sure the play the song loud and proud when deploying!

ansible/beta-hosts/variables

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,3 +60,22 @@ registry_host=10.20.1.55
6060
swarm_token=d363b783f03a845a2c82b081bfe8443e
6161
user_content_domain=runnablecloud.com
6262
api_hello_runnable_github_token=88ddc423c2312d02a8bbcaad76dd4c374a30e4af
63+
64+
[ec2:vars]
65+
env=beta
66+
aws_custid=437258487404
67+
vpc_id=vpc-9e84e1fb
68+
sg_api=sg-a6e684c2
69+
sg_bastion=sg-6bc8060f
70+
sg_dock=sg-d6e684b2
71+
sg_hipache=sg-1935727d
72+
sg_mongo=sg-13c30d77
73+
sg_nat=sg-4f07742b
74+
sg_navi=sg-8de684e9
75+
sg_neo4j=sg-78dd131c
76+
sg_rabbit=sg-42a76e26
77+
sg_rds=sg-a27f36c6
78+
sg_redis=sg-81d01ee5
79+
sg_services=sg-950172f1
80+
sg_userland=sg-5a28663e
81+
sg_web=sg-58da143c

ansible/delta-hosts/docks.js

Lines changed: 75 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,75 @@
1+
#!/usr/bin/env node
2+
3+
'use strict';
4+
5+
var aws = require('aws-sdk');
6+
var ec2 = new aws.EC2({
7+
accessKeyId: 'AKIAJ3RCYU6FCULAJP2Q',
8+
secretAccessKey: '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',
9+
region: 'us-west-2'
10+
});
11+
12+
var params = {
13+
Filters: [
14+
// Only search for docks in the cluster security group
15+
{
16+
Name: 'instance.group-id',
17+
Values: ['sg-6cd7fb08']
18+
},
19+
// Only fetch instances that are tagged as docks
20+
{
21+
Name: 'tag:role',
22+
Values: ['dock']
23+
},
24+
// Only fetch running instances
25+
{
26+
Name: 'instance-state-name',
27+
Values: ['running']
28+
}
29+
]
30+
};
31+
32+
ec2.describeInstances(params, function (err, data) {
33+
if (err) {
34+
console.error("An error occurred: ", err);
35+
process.exit(1);
36+
}
37+
38+
// Get a set of instances from the describe response
39+
var instances = [];
40+
data.Reservations.forEach(function (res) {
41+
res.Instances.forEach(function (instance) {
42+
instances.push(instance);
43+
});
44+
});
45+
46+
// Map the instances to their private ip addresses
47+
// NOTE This will work locally because of the wilcard ssh proxy in the config
48+
var hosts = instances.map(function (instance) {
49+
return instance.PrivateIpAddress;
50+
});
51+
52+
var hostVars = {};
53+
instances.forEach(function (instance) {
54+
for (var i = 0; i < instance.Tags.length; i++) {
55+
if (instance.Tags[i].Key === 'org') {
56+
hostVars[instance.PrivateIpAddress] = {
57+
host_tags: instance.Tags[i].Value + ',build,run'
58+
};
59+
}
60+
}
61+
});
62+
63+
// Output the resulting JSON
64+
// NOTE http://docs.ansible.com/ansible/developing_inventory.html
65+
console.log(JSON.stringify(
66+
{
67+
docks: {
68+
hosts: hosts
69+
},
70+
_meta : {
71+
hostvars : hostVars
72+
}
73+
}
74+
));
75+
});

ansible/delta-hosts/hosts

Lines changed: 123 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,123 @@
1+
[bastion]
2+
delta-bastion
3+
4+
[hipache]
5+
delta-hipache httpsCheckForBackend80=false prependIncomingPort=true subDomainDepth=4
6+
delta-userland domain=runnableapp.com httpsCheckForBackend80=true prependIncomingPort=true subDomainDepth=3
7+
8+
[mongodb]
9+
delta-mongo-a
10+
delta-mongo-b
11+
delta-mongo-c
12+
13+
[neo4j]
14+
delta-neo4j
15+
16+
[api_group:children]
17+
worker
18+
api
19+
20+
[api]
21+
delta-api
22+
23+
[consul]
24+
delta-services
25+
delta-api
26+
delta-web
27+
28+
[vault]
29+
delta-services
30+
31+
[worker]
32+
delta-api
33+
34+
[docks]
35+
36+
[eru]
37+
delta-services
38+
39+
[navi]
40+
delta-navi
41+
42+
[mongo-navi]
43+
delta-navi
44+
45+
[link]
46+
delta-navi
47+
48+
[charon]
49+
delta-services
50+
51+
[khronos]
52+
delta-services
53+
54+
[mavis]
55+
delta-services
56+
57+
[optimus]
58+
delta-services
59+
60+
[detention]
61+
delta-services
62+
63+
[palantiri]
64+
delta-services
65+
66+
[rabbitmq]
67+
delta-rabbit
68+
69+
[web]
70+
delta-web
71+
72+
[redis]
73+
delta-redis
74+
75+
[redis-slave]
76+
delta-redis-slave
77+
78+
[shiva]
79+
delta-services
80+
81+
[registry]
82+
delta-registry
83+
84+
[sauron]
85+
delta-services
86+
87+
[swarm-manager]
88+
delta-services
89+
90+
[metis]
91+
delta-services
92+
93+
[delta:children]
94+
bastion
95+
hipache
96+
mongodb
97+
api
98+
web
99+
redis
100+
redis-slave
101+
docks
102+
registry
103+
neo4j
104+
navi
105+
charon
106+
khronos
107+
mavis
108+
optimus
109+
rabbitmq
110+
eru
111+
sauron
112+
shiva
113+
metis
114+
swarm-manager
115+
116+
[local]
117+
127.0.0.1
118+
119+
[ec2]
120+
local
121+
122+
[targets]
123+
localhost ansible_connection=local bastion_name=delta-bastion

ansible/delta-hosts/variables

Lines changed: 91 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,91 @@
1+
[api_group:vars]
2+
api_aws_access_key_id=AKIAJWSSSJYUXKNW2ZDA
3+
api_aws_secret_access_key=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
4+
api_github_client_id=d42d6634d4070c9d9bf9
5+
api_github_client_secret=d6cfde38fef5723e25e52629e3d25825c8a704c9
6+
api_github_deploy_keys_bucket=runnable.deploykeys.production
7+
api_mixpanel_app_id=57260a5b6fc972e9c69184882efd009e
8+
api_mongo_auth=api:72192e5a-a5e1-11e5-add9-0270db32f7ad
9+
api_mongo_database=delta
10+
api_mongo_replset_name=delta-rs0
11+
api_neo4j_auth=neo4j:oqGlRV1KTpaqbHDkdlJz
12+
api_new_relic_app_name=delta-api-production
13+
api_rollbar_key=a90d9c262c7c48cfabbd32fd0a1bc61c
14+
api_s3_context_bucket=runnable.context.resources.production
15+
16+
[docks:vars]
17+
docker_config=docks
18+
19+
[eru:vars]
20+
eru_github_id=46a23f5f99f0aa9460f8
21+
eru_github_secret=a0336d72e3d540fb9fbbed2c123a81e1cb329dab
22+
23+
[khronos:vars]
24+
khronos_mongo_auth=api:oW4c7x9Wiv28oiNBy2Bc
25+
khronos_mongo_database=delta
26+
khronos_mongo_replset_name=delta
27+
28+
[optimus:vars]
29+
optimus_aws_access_id=AKIAJWSSSJYUXKNW2ZDA
30+
optimus_aws_secret_id=tyvGiCbj5jWCiQnMLvfrfD64dFo8i6prkdcga86y
31+
optimus_github_deploy_keys_bucket=runnable.deploykeys.production
32+
33+
[palantiri:vars]
34+
palantiri_rollbar_key=f675e9090d6f483ca4e742af2c7f2f83
35+
36+
[registry:vars]
37+
registry_s3_access_key=AKIAJKCSFJCHFDITLBUQ
38+
registry_s3_bucket=runnableimages.alpha
39+
registry_s3_secret_key=LXxpb4F7Kxum1HvYkG0P20Yb/9Qpr+e5Gtt/0bIY
40+
registry_s3_region=us-west-2
41+
42+
[shiva:vars]
43+
aws_access_key_id=AKIAJ3RCYU6FCULAJP2Q
44+
aws_secret_access_key=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
45+
shiva_rollbar_key=0526a90faec845d796e1ef5361a00526
46+
47+
[vault:vars]
48+
vault_auth_token=578c9767-5af8-8490-0954-5d330f27b088
49+
vault_token_01=0d324dc7d4cbd94790fd08809d06fb1e28e21e185910081c7646e3e49924f6ed01
50+
vault_token_02=42dc8a69df174e77eb47a63b6ef4709bec57101cb1bff11a71c91b73b8bc046102
51+
vault_token_03=47f3cb74f5374fa3c51c90fd25e3d4cc851034de97584995fce5fc5382342f1f03
52+
vault_hello_runnable_github_token=88ddc423c2312d02a8bbcaad76dd4c374a30e4af
53+
vault_aws_access_key_id=AKIAJ7R4UIM45KH2WGWQ
54+
vault_aws_secret_key=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
55+
vault_aws_region=us-east-1
56+
57+
[delta:vars]
58+
ansible_ssh_private_key_file=~/.ssh/delta.pem
59+
api_hello_runnable_github_token=88ddc423c2312d02a8bbcaad76dd4c374a30e4af
60+
datadog_host_address=10.8.5.63
61+
datadog_tags=env:delta
62+
domain=runnable.io
63+
mongo_port=27017
64+
new_relic_license_key=338516e0826451c297d44dc60aeaf0a0ca4bfead
65+
node_env=production-delta
66+
pg_host=delta-infrastructure-db.cnksgdqarobf.us-west-2.rds.amazonaws.com
67+
pg_pass=59a5524e-a772-11e5-bedc-1bdc0db458b3
68+
rabbit_password=wKK7g7NWKpQXEeSzyWB7mIpxZIL8H2mDSf3Q6czR3Vk
69+
rabbit_username=o2mdLh9N9Ke2GzhoK8xsruYPhIQFN7iEL44dQJoq7OM
70+
registry_host=10.8.4.126
71+
user_content_domain=runnableapp.com
72+
73+
[ec2:vars]
74+
aws_custid=437258487404
75+
sg_hipache=sg-7fd7fb1b
76+
sg_api=sg-0bf7db6f
77+
sg_neo4j=sg-a9d0fccd
78+
sg_bastion=sg-99d6fafd
79+
sg_dock=sg-6cd7fb08
80+
sg_mongo=sg-00d7fb64
81+
sg_rds=sg-65d2fe01
82+
sg_web=sg-51d2fe35
83+
sg_services=sg-71d2fe15
84+
sg_userland=sg-41d2fe25
85+
sg_nat=sg-3082cc54
86+
sg_rabbit=sg-92d1fdf6
87+
sg_redis=sg-6ed2fe0a
88+
sg_navi=sg-e5d7fb81
89+
env=delta
90+
region=us-west-2
91+
vpc_id=vpc-864c6be3

ansible/dock-init.yml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
---
2+
- hosts: consul
3+
vars_files:
4+
- group_vars/alpha-dock-init.yml
5+
roles:
6+
- { role: notify, tags: [notify] }
7+
- { role: consul_value, tags: [deploy, consul_value] }

ansible/docker-listener.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,4 +11,5 @@
1111
- { role: build_essential }
1212
- { role: docker_client }
1313
- { role: git_node_service, tags: [deploy] }
14+
- { role: loggly-rotate }
1415
- { role: consul_value, tags: [deploy, consul_value] }

ansible/filibuster.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,4 +7,5 @@
77
roles:
88
- { role: notify, tags: [notify] }
99
- { role: git_node_service, tags: [deploy] }
10+
- { role: loggly-rotate }
1011
- { role: consul_value, tags: [deploy, consul_value] }

ansible/gamma-hosts/hosts

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,12 @@ gamma-services
3737
[navi]
3838
gamma-navi
3939

40+
[link]
41+
gamma-navi
42+
43+
[mongo-navi]
44+
gamma-navi
45+
4046
[charon]
4147
gamma-services
4248

@@ -103,5 +109,8 @@ sauron
103109
shiva
104110
swarm-manager
105111

112+
[ec2]
113+
127.0.0.1
114+
106115
[targets]
107116
localhost ansible_connection=local bastion_name=gamma-bastion

0 commit comments

Comments
 (0)