-
Notifications
You must be signed in to change notification settings - Fork 0
/
start.sh
executable file
·28 lines (22 loc) · 844 Bytes
/
start.sh
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
#!/bin/sh
# Azure credentials
export TF_VAR_arm_subscription_id=
export TF_VAR_arm_client_id=
export TF_VAR_arm_client_secret=
export TF_VAR_arm_tenant_id=
# VMs SSH public key
export TF_VAR_ssh_public_key=
echo '-----------------------DevOps Test------------------------'
echo 'Author: Eduardo Espinoza Perez <eduardo.espinoza@tenpo.cl>'
echo '----------------------------------------------------------'
echo '[PostgreSQL image configuration] Starting'
packer build -force packer-postgresql.json
echo '[PostgreSQL image configuration] Finished'
echo '[Docker + TestAPI image configuration] Starting'
packer build -force packer-docker.json
echo '[Docker + TestAPI image configuration] Finished'
echo '[Infrastructure creation] Starting'
terraform init
terraform plan
terraform apply -auto-approve
echo '[Infrastructure creation] Finished'