* Add TODO-proper fix for state - native salt fun.
But due bug[1] in saltstack - we can't enable
proper solution now
[1] 74599bbdfc
Related-PROD: PROD-20730
Change-Id: I11b6d81ae0f9a7864518f638e8fc423e4e087285
pull/165/head
@@ -1,8 +1,8 @@ | |||
--- | |||
driver: | |||
name: docker | |||
hostname: linux.ci.local | |||
use_sudo: false | |||
hostname: linux-formula | |||
run_options: -v /dev/log:/dev/log:ro | |||
provisioner: | |||
name: salt_solo |
@@ -16,18 +16,22 @@ linux_hostname_file: | |||
{%- endif %} | |||
{# Change state to proper one, after releasing patch: | |||
https://github.com/saltstack/salt/pull/45748/files/74599bbdfcf99f45d3a31296887097fade31cbf1 | |||
linux_enforce_hostname: | |||
cmd.wait: | |||
network.system: | |||
- enabled: True | |||
- hostname: {{ network.hostname }} | |||
- apply_hostname: True | |||
- retain_settings: True | |||
#} | |||
linux_enforce_hostname: | |||
cmd.run: | |||
- name: hostname {{ network.hostname }} | |||
- unless: test "$(hostname)" = "{{ network.hostname }}" | |||
{# | |||
linux_hostname_hosts: | |||
host.present: | |||
- ip: {{ grains.ip4_interfaces[network.get('default_interface', 'eth0')][0] }} | |||
- names: | |||
- {{ network.fqdn }} | |||
- {{ network.hostname }} | |||
#} | |||
{%- if grains.get('noservices') %} | |||
- onlyif: /bin/false | |||
{%- endif %} | |||
{%- endif %} |
@@ -1,6 +1,8 @@ | |||
{%- from "linux/map.jinja" import network with context %} | |||
include: | |||
{%- if network.hostname is defined %} | |||
- linux.network.hostname | |||
{%- endif %} | |||
{%- if network.host|length > 0 or network.get('purge_hosts', True) %} | |||
- linux.network.host | |||
{%- endif %} |
@@ -1,11 +1,14 @@ | |||
linux: | |||
network: | |||
enabled: true | |||
hostname: linux | |||
fqdn: linux.ci.local | |||
system: | |||
enabled: true | |||
cluster: default | |||
name: linux | |||
domain: local | |||
domain: ci.local | |||
environment: prd | |||
hostname: system.pillar.local | |||
purge_repos: true | |||
directory: | |||
/tmp/test: |