Commit 223c322a authored by Kerim Satirli's avatar Kerim Satirli

make `opstheater` a first-level citizen-variable

parent d2d7f706
......@@ -5,7 +5,7 @@ resource "digitalocean_ssh_key" "opstheater" {
resource "digitalocean_droplet" "host" {
image = "${var.do_droplet_images.centos}"
name = "${var.meta_opstheater_host}.${var.meta_opstheater_domain}"
name = "${var.opstheater_host}.${var.opstheater_domain}"
region = "${var.do_regions.global}"
size = "512mb"
......@@ -30,7 +30,7 @@ resource "digitalocean_droplet" "host" {
"yum update --assumeyes --quiet",
"yum install --assumeyes --quiet epel-release https://yum.puppetlabs.com/puppetlabs-release-pc1-el-7.noarch.rpm",
"yum install --assumeyes --quiet puppet-agent",
"/opt/puppetlabs/bin/puppet config set --section main server ${var.meta_opstheater_host}.${var.meta_opstheater_domain}",
"/opt/puppetlabs/bin/puppet config set --section main server ${var.opstheater_host}.${var.opstheater_domain}",
"/opt/puppetlabs/bin/puppet agent --test || true"
]
}
......
......@@ -50,12 +50,12 @@ variable "meta_key_material" {
}
}
variable "meta_opstheater_domain" {
variable "opstheater_domain" {
description = "Domain to use for OpsTheater"
default = "opstheater.vm"
}
variable "meta_opstheater_host" {
variable "opstheater_host" {
description = "Host to use for OpsTheater"
default = "puppet"
}
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment