-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathpost_checks.tf
95 lines (90 loc) · 2.4 KB
/
post_checks.tf
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
resource "null_resource" "post_checks_monitor1" {
triggers {
cluster_instance_ids = "${openstack_compute_instance_v2.monitor1.id}"
}
connection {
host = "${openstack_compute_instance_v2.monitor1.network.0.floating_ip}"
user = "ubuntu"
private_key = "~/.ssh/id_rsa.terraform"
}
provisioner "remote-exec" {
script = "wait_provision.sh"
}
provisioner "remote-exec" {
inline = [
"sudo /opt/puppetlabs/puppet/bin/rspec /usr/local/rspec_tests/ -f d"
]
}
}
resource "null_resource" "post_checks_appl1" {
triggers {
cluster_instance_ids = "${openstack_compute_instance_v2.appl1.id}"
}
connection {
host = "${openstack_compute_instance_v2.appl1.network.0.floating_ip}"
user = "debian"
private_key = "~/.ssh/id_rsa.terraform"
}
provisioner "remote-exec" {
script = "wait_provision.sh"
}
provisioner "remote-exec" {
inline = [
"sudo /opt/puppetlabs/puppet/bin/rspec /usr/local/rspec_tests/ -f d"
]
}
}
resource "null_resource" "post_checks_appl2" {
triggers {
cluster_instance_ids = "${openstack_compute_instance_v2.appl2.id}"
}
connection {
host = "${openstack_compute_instance_v2.appl2.network.0.floating_ip}"
user = "debian"
private_key = "~/.ssh/id_rsa.terraform"
}
provisioner "remote-exec" {
script = "wait_provision.sh"
}
provisioner "remote-exec" {
inline = [
"sudo /opt/puppetlabs/puppet/bin/rspec /usr/local/rspec_tests/ -f d"
]
}
}
resource "null_resource" "post_checks_lb1" {
triggers {
cluster_instance_ids = "${openstack_compute_instance_v2.lb1.id}"
}
connection {
host = "${openstack_compute_instance_v2.lb1.network.0.floating_ip}"
user = "ubuntu"
private_key = "~/.ssh/id_rsa.terraform"
}
provisioner "remote-exec" {
script = "wait_provision.sh"
}
provisioner "remote-exec" {
inline = [
"sudo /opt/puppetlabs/puppet/bin/rspec /usr/local/rspec_tests/ -f d"
]
}
}
resource "null_resource" "post_checks_db1" {
triggers {
cluster_instance_ids = "${openstack_compute_instance_v2.db1.id}"
}
connection {
host = "${openstack_compute_instance_v2.db1.network.0.floating_ip}"
user = "debian"
private_key = "~/.ssh/id_rsa.terraform"
}
provisioner "remote-exec" {
script = "wait_provision.sh"
}
provisioner "remote-exec" {
inline = [
"sudo /opt/puppetlabs/puppet/bin/rspec /usr/local/rspec_tests/ -f d"
]
}
}