diff options
author | Zach Marano <zmarano@google.com> | 2017-01-20 10:40:11 -0800 |
---|---|---|
committer | Zach Marano <zmarano@google.com> | 2017-01-20 10:40:11 -0800 |
commit | 34af307df541edca4eee58b1d8be64888550a674 (patch) | |
tree | 6b2d652c7155ef09532861fe2ed797841ce66fdf | |
parent | ddea656b087c140ae58dc00e7b1e823c80b66f22 (diff) | |
parent | bec0c16e2f0c5964bcead2ac1e5cafd03d0a2628 (diff) | |
download | google-compute-image-packages-34af307df541edca4eee58b1d8be64888550a674.tar.gz |
Merge branch 'development'20170120
-rwxr-xr-x | google_config/bin/set_hostname | 7 | ||||
-rwxr-xr-x | google_config/build_packages.sh | 2 |
2 files changed, 8 insertions, 1 deletions
diff --git a/google_config/bin/set_hostname b/google_config/bin/set_hostname index 01a11ad..64aa091 100755 --- a/google_config/bin/set_hostname +++ b/google_config/bin/set_hostname @@ -39,6 +39,13 @@ fi if [ -n "$new_host_name" ]; then hostname "${new_host_name%%.*}" + # If NetworkManager is installed set the hostname with nmcli. + # to resolve issues with NetworkManager resetting the hostname + # to the FQDN on DHCP renew. + if [ -x /bin/nmcli ]; then + nmcli general hostname "${new_host_name%%.*}" + fi + # Restart syslog to update the hostname if we're not using systemd. # systemd rsyslog jobs wait for networking to finish starting and consequently # syslog or rsyslog is running with the correct hostname. diff --git a/google_config/build_packages.sh b/google_config/build_packages.sh index ae19def..1ebec14 100755 --- a/google_config/build_packages.sh +++ b/google_config/build_packages.sh @@ -46,7 +46,7 @@ function build_distro() { --rpm-dist "${distro}" \ --url 'https://github.com/GoogleCloudPlatform/compute-image-packages' \ --vendor 'Google Compute Engine Team' \ - --version '2.1.1' \ + --version '2.1.2' \ "${COMMON_FILES[@]}" \ "${files[@]:2}" } |