Skip to content

Commit

Permalink
Merge pull request #22 from caseydavenport/cd4-etc-hosts
Browse files Browse the repository at this point in the history
Don't configure /etc/hosts by default.
  • Loading branch information
tomdee committed Apr 18, 2016
2 parents f804adc + 980bb83 commit 26de923
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions policy_agent.py
Original file line number Diff line number Diff line change
Expand Up @@ -477,9 +477,12 @@ def configure_etc_hosts():
_log.addHandler(stdout_hdlr)
_log.setLevel(log_level)

# Configure /etc/hosts with Kubernetes API.
_log.info("Configuring /etc/hosts")
configure_etc_hosts()
if os.environ.get("CONFIGURE_ETC_HOSTS", "false").lower() == "true":
# Configure /etc/hosts with Kubernetes API.
# Don't do this by default, since it is recommended to run
# this pod using host networking on the master.
_log.info("Configuring /etc/hosts")
configure_etc_hosts()

_log.info("Beginning execution")
PolicyAgent().run()

0 comments on commit 26de923

Please sign in to comment.