-
Notifications
You must be signed in to change notification settings - Fork 5
/
create
executable file
·56 lines (48 loc) · 1.65 KB
/
create
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
#!/bin/bash
set -e -u
lpass show 'Shared-Concourse/Prod GCP Key' --notes > keypair/id_rsa
chmod 0600 keypair/id_rsa
lpass show 'Shared-Concourse/Prod GCP Credentials' --notes > iaas/terraform.key.json
pushd iaas
terraform init
terraform apply
popd
./scripts/generate-bosh-tf-vars \
> bosh/bosh-tf-vars.yml
lpass show 'Shared-Concourse/Prod bosh-deployment-vars.yml' --notes \
> bosh/bosh-deployment-vars.yml
BOSH_GENERATED_CREDS=$(mktemp /tmp/bosh_generated_vars.XXXXXX)
bosh create-env bosh-deployment/bosh.yml \
--state bosh/bosh-state.json \
--vars-store $BOSH_GENERATED_CREDS \
-o bosh-deployment/gcp/cpi.yml \
-v director_name=concourse-prod-bosh \
-v internal_cidr=10.0.0.0/29 \
-v internal_gw=10.0.0.1 \
-v internal_ip=10.0.0.6 \
-v project_id=cf-concourse-production \
-v zone=us-central1-a \
-v network=bosh \
-v subnetwork=director \
-v tags=[director] \
-v director_workers=24 \
-v postgres_max_connections=300 \
--var-file gcp_credentials_json=iaas/terraform.key.json \
-o bosh-deployment/syslog.yml \
-o bosh-deployment/uaa.yml \
-o bosh-deployment/credhub.yml \
-o bosh-deployment/local-dns.yml \
-o bosh-deployment/external-ip-not-recommended.yml \
-o bosh-deployment/misc/powerdns.yml \
-v dns_recursor_ip=169.254.169.254 \
-o bosh/ops/ci-client.yml \
-o bosh/ops/credhub-cli-user.yml \
-o bosh/ops/director-vm-size.yml \
-o bosh/ops/director-disk-size.yml \
-o bosh/ops/os-conf-users.yml \
-o bosh/ops/uaa-external-dns.yml \
-o bosh/ops/unset-config-server-uaa-ca.yml \
-o bosh/ops/workers.yml \
-o bosh/ops/director-db.yml \
-l bosh/bosh-deployment-vars.yml \
-l bosh/bosh-tf-vars.yml