remove user_data which may mess up /etc/hosts
parent
74fd975b57
commit
ba7b1d74d0
|
@ -1,14 +1,3 @@
|
|||
variable user_data {
|
||||
type = "string"
|
||||
|
||||
default = <<EOF
|
||||
#cloud-config
|
||||
manage_etc_hosts: localhost
|
||||
package_update: true
|
||||
package_upgrade: true
|
||||
EOF
|
||||
}
|
||||
|
||||
resource "openstack_compute_keypair_v2" "k8s" {
|
||||
name = "kubernetes-${var.cluster_name}"
|
||||
public_key = "${chomp(file(var.public_key_path))}"
|
||||
|
@ -97,7 +86,6 @@ resource "openstack_compute_instance_v2" "bastion" {
|
|||
command = "sed s/USER/${var.ssh_user}/ contrib/terraform/openstack/ansible_bastion_template.txt | sed s/BASTION_ADDRESS/${var.bastion_fips[0]}/ > contrib/terraform/openstack/group_vars/no-floating.yml"
|
||||
}
|
||||
|
||||
user_data = "${var.user_data}"
|
||||
}
|
||||
|
||||
resource "openstack_compute_instance_v2" "k8s_master" {
|
||||
|
@ -123,7 +111,6 @@ resource "openstack_compute_instance_v2" "k8s_master" {
|
|||
depends_on = "${var.network_id}"
|
||||
}
|
||||
|
||||
user_data = "${var.user_data}"
|
||||
}
|
||||
|
||||
resource "openstack_compute_instance_v2" "k8s_master_no_etcd" {
|
||||
|
@ -147,7 +134,6 @@ resource "openstack_compute_instance_v2" "k8s_master_no_etcd" {
|
|||
depends_on = "${var.network_id}"
|
||||
}
|
||||
|
||||
user_data = "${var.user_data}"
|
||||
}
|
||||
|
||||
resource "openstack_compute_instance_v2" "etcd" {
|
||||
|
@ -169,7 +155,6 @@ resource "openstack_compute_instance_v2" "etcd" {
|
|||
depends_on = "${var.network_id}"
|
||||
}
|
||||
|
||||
user_data = "${var.user_data}"
|
||||
}
|
||||
|
||||
resource "openstack_compute_instance_v2" "k8s_master_no_floating_ip" {
|
||||
|
@ -194,7 +179,6 @@ resource "openstack_compute_instance_v2" "k8s_master_no_floating_ip" {
|
|||
depends_on = "${var.network_id}"
|
||||
}
|
||||
|
||||
user_data = "${var.user_data}"
|
||||
}
|
||||
|
||||
resource "openstack_compute_instance_v2" "k8s_master_no_floating_ip_no_etcd" {
|
||||
|
@ -218,7 +202,6 @@ resource "openstack_compute_instance_v2" "k8s_master_no_floating_ip_no_etcd" {
|
|||
depends_on = "${var.network_id}"
|
||||
}
|
||||
|
||||
user_data = "${var.user_data}"
|
||||
}
|
||||
|
||||
resource "openstack_compute_instance_v2" "k8s_node" {
|
||||
|
@ -243,7 +226,6 @@ resource "openstack_compute_instance_v2" "k8s_node" {
|
|||
depends_on = "${var.network_id}"
|
||||
}
|
||||
|
||||
user_data = "${var.user_data}"
|
||||
}
|
||||
|
||||
resource "openstack_compute_instance_v2" "k8s_node_no_floating_ip" {
|
||||
|
@ -267,7 +249,6 @@ resource "openstack_compute_instance_v2" "k8s_node_no_floating_ip" {
|
|||
depends_on = "${var.network_id}"
|
||||
}
|
||||
|
||||
user_data = "${var.user_data}"
|
||||
}
|
||||
|
||||
resource "openstack_compute_floatingip_associate_v2" "bastion" {
|
||||
|
@ -316,7 +297,6 @@ resource "openstack_compute_instance_v2" "glusterfs_node_no_floating_ip" {
|
|||
depends_on = "${var.network_id}"
|
||||
}
|
||||
|
||||
user_data = "#cloud-config\nmanage_etc_hosts: localhost\npackage_update: true\npackage_upgrade: true"
|
||||
}
|
||||
|
||||
resource "openstack_compute_volume_attach_v2" "glusterfs_volume" {
|
||||
|
|
Loading…
Reference in New Issue