-
Notifications
You must be signed in to change notification settings - Fork 3
/
docker-compose.yml
185 lines (179 loc) · 5.7 KB
/
docker-compose.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
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
---
services:
app:
build: .
working_dir: /app
environment:
DATAGOV_BACKUP_S3_SERVICE: datastore-backup-s3
DATASTORE_BUCKET_ENDPOINT: http://s3:9000
VCAP_APPLICATION: |
{
"cf_api": "https://api.fr.cloud.gov",
"limits": {
"fds": 16384,
"mem": 64,
"disk": 1024
},
"application_name": "backup-manager",
"application_uris": [],
"name": "backup-manager",
"space_name": "development",
"space_id": "eab3d327-7d9f-423b-9838-753c26fdb5a0",
"organization_id": "90047c5d-337f-4802-bd48-2149a4265040",
"organization_name": "gsa-datagov",
"uris": [],
"process_id": "6e443533-313f-4503-9cf9-a9e0fb410b0a",
"process_type": "web",
"application_id": "2c9987f0-9a4f-4590-b29a-cdc6d9d97d4a",
"version": "3a640698-3af3-4bde-8936-94440e8ca6fb",
"application_version": "3a640698-3af3-4bde-8936-94440e8ca6fb"
}
VCAP_SERVICES: |
{
"aws-rds": [
{
"binding_guid": "eda9d934-a935-492a-abf5-7a2bbd126d9b",
"binding_name": null,
"credentials": {
"db_name": "application_db",
"host": "postgres",
"name": "postgres",
"password": "psql",
"port": "5432",
"uri": "postgres://app:psql@postgres:5432/application_db",
"username": "app"
},
"instance_guid": "84ec223d-b3ba-4fd0-9648-08aebc8c9863",
"instance_name": "postgres",
"label": "aws-rds",
"name": "postgres",
"plan": "small-psql",
"provider": null,
"syslog_drain_url": null,
"tags": [
"database",
"RDS"
],
"volume_mounts": []
},
{
"binding_guid": "eda9d934-a935-492a-abf5-7a2bbd126d9b",
"binding_name": null,
"credentials": {
"db_name": "postgres_restore",
"host": "postgres-restore",
"name": "postgres-restore",
"password": "psql",
"port": "5432",
"uri": "postgres://app_restore:psql@postgres:5432/postgres_restore",
"username": "app_restore"
},
"instance_guid": "84ec223d-b3ba-4fd0-9648-08aebc8c9863",
"instance_name": "postgres-restore",
"label": "aws-rds",
"name": "postgres",
"plan": "small-psql",
"provider": null,
"syslog_drain_url": null,
"tags": [
"database",
"RDS"
],
"volume_mounts": []
},
{
"binding_guid": "eda9d934-a935-492a-abf5-7a2bbd126d9b",
"binding_name": null,
"credentials": {
"db_name": "application-mysql-db",
"host": "mysql",
"name": "application",
"password": "mysql-password",
"port": "3306",
"uri": "mysql://app:mysql-password@postgres:5432/application",
"username": "app"
},
"instance_guid": "84ec223d-b3ba-4fd0-9648-08aebc8c9863",
"instance_name": "application-mysql-db",
"label": "aws-rds",
"name": "application-mysql-db",
"plan": "small-mysql",
"provider": null,
"syslog_drain_url": null,
"tags": [
"database",
"RDS"
],
"volume_mounts": []
}
],
"s3": [
{
"label": "s3",
"provider": null,
"plan": "basic-sandbox",
"name": "datastore-backup-s3",
"tags": [
"AWS",
"S3",
"object-storage"
],
"instance_guid": "5a6f8b66-af7e-473a-bb5b-7c347d8fa164",
"instance_name": "datastore-backup-s3",
"binding_guid": "c74e306b-c02a-43be-877f-76b860b69dac",
"binding_name": null,
"credentials": {
"uri": "s3://minio:[email protected]/datagov-backup",
"access_key_id": "minio",
"secret_access_key": "miniopassword",
"region": "us-gov-west-1",
"bucket": "datagov-backup",
"fips_endpoint": "s3-fips.us-gov-west-1.amazonaws.com",
"additional_buckets": []
},
"syslog_drain_url": null,
"volume_mounts": [
]
}
]
}
depends_on:
- mysql
- postgres
- postgres-restore
- s3
volumes:
- .:/app
mysql:
image: mysql:5
environment:
MYSQL_USER: app
MYSQL_DATABASE: application-mysql-db
MYSQL_PASSWORD: mysql-password
MYSQL_ALLOW_EMPTY_PASSWORD: 1
ports:
- "3306:3306"
postgres:
image: postgres:10-alpine
environment:
POSTGRES_DB: application_db
POSTGRES_USER: app
POSTGRES_PASSWORD: psql
ports:
- "5432:5432"
postgres-restore:
image: postgres:10-alpine
environment:
POSTGRES_DB: application_restore_db
POSTGRES_USER: app_restore
POSTGRES_PASSWORD: psql
ports:
- "5432"
s3:
image: minio/minio
command: server /data
ports:
- "9000:9000"
environment:
- MINIO_ROOT_USER=minio
- MINIO_ROOT_PASSWORD=miniopassword