mirror of https://github.com/zulip/zulip.git
puppet: Stop automatically creating hiera.yaml on newer distros.
This fixes some unnecessary warnings on systems running Ubuntu bionic.
This commit is contained in:
parent
42da4522a9
commit
37335960a0
|
@ -17,8 +17,10 @@ config = configparser.RawConfigParser()
|
||||||
config.read("/etc/zulip/zulip.conf")
|
config.read("/etc/zulip/zulip.conf")
|
||||||
|
|
||||||
if not os.path.exists("/etc/puppet/hiera.yaml"):
|
if not os.path.exists("/etc/puppet/hiera.yaml"):
|
||||||
# Suppress warnings about hiera.yaml not existing.
|
codename = subprocess.check_output(["lsb_release", "-cs"]).strip().decode("utf-8")
|
||||||
subprocess.check_call(["touch", "/etc/puppet/hiera.yaml"])
|
if codename in ["trusty", "stretch", "xenial"]:
|
||||||
|
# Suppress warnings in old puppet about hiera.yaml not existing.
|
||||||
|
subprocess.check_call(["touch", "/etc/puppet/hiera.yaml"])
|
||||||
|
|
||||||
puppet_config = """
|
puppet_config = """
|
||||||
Exec { path => "/usr/sbin:/usr/bin:/sbin:/bin" }
|
Exec { path => "/usr/sbin:/usr/bin:/sbin:/bin" }
|
||||||
|
|
Loading…
Reference in New Issue