From 55336110333c4a483b225b46ff2ac58757042126 Mon Sep 17 00:00:00 2001 From: Karim Naufal Date: Tue, 22 Feb 2022 04:11:24 +0100 Subject: [PATCH] fixed hostname and readme --- README.md | 2 ++ modules/host/main.tf | 10 ++++++---- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index d317c73..408d248 100644 --- a/README.md +++ b/README.md @@ -22,6 +22,8 @@ ## About The Project +ℹ️ _This project is still in development and changing rapidly. Soon enough we will have a stable release with semver-compliant versions. Thank you for your patience._ + [Hetzner Cloud](https://hetzner.com) is a good cloud provider that offers very affordable prices for cloud instances, with data center locations in both Europe and the US. The goal of this project is to create an optimal and highly optimized Kubernetes installation that is easily maintained, secure, and automatically upgrades. We aimed for functionality as close as possible to GKE's auto-pilot. diff --git a/modules/host/main.tf b/modules/host/main.tf index c5b3b86..0aa14cb 100644 --- a/modules/host/main.tf +++ b/modules/host/main.tf @@ -56,13 +56,15 @@ resource "hcloud_server" "server" { EOT } - # Run the agent provisioner "remote-exec" { inline = [ - # set the hostname in a persistent fashion - "hostnamectl set-hostname ${self.name}", # Disable automatic reboot (after transactional updates), and configure the reboot method as kured - "rebootmgrctl set-strategy off && echo 'REBOOT_METHOD=kured' > /etc/transactional-update.conf" + "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 ] } }