From 46dd37383c845da5e3e15d6923b4e61242386633 Mon Sep 17 00:00:00 2001 From: Karim Naufal Date: Fri, 25 Feb 2022 15:30:39 +0100 Subject: [PATCH] network fix attempt --- main.tf | 1 - modules/host/locals.tf | 3 +++ modules/host/main.tf | 9 ++++----- 3 files changed, 7 insertions(+), 6 deletions(-) diff --git a/main.tf b/main.tf index cbab0cf..e66cedf 100644 --- a/main.tf +++ b/main.tf @@ -159,7 +159,6 @@ data "hcloud_load_balancer" "traefik" { depends_on = [null_resource.kustomization] } - resource "null_resource" "destroy_traefik_loadbalancer" { # this only gets triggered before total destruction of the cluster, but when the necessary elements to run the commands are still available triggers = { diff --git a/modules/host/locals.tf b/modules/host/locals.tf index 0547e70..08306d6 100644 --- a/modules/host/locals.tf +++ b/modules/host/locals.tf @@ -61,6 +61,9 @@ locals { combustion_script = < /etc/transactional-update.conf", + "set -ex", + "rebootmgrctl set-strategy off", + "echo 'REBOOT_METHOD=kured' > /etc/transactional-update.conf", # set the hostname - <<-EOT - hostnamectl set-hostname ${self.name} - sed -e 's#NETCONFIG_NIS_SETDOMAINNAME="yes"#NETCONFIG_NIS_SETDOMAINNAME="no"#g' /etc/sysconfig/network/config > /dev/null - EOT + "hostnamectl set-hostname ${self.name}" ] } }