evolinux-base: improve hostname configuration

We can have a "real" hostname and domain, but also an "internal" hostnae 
and domain, used mostly for internal tools.
This commit is contained in:
Jérémy Lecour 2018-08-16 16:17:26 +02:00 committed by Jérémy Lecour
parent d07af3ca55
commit bc8858fc0a
3 changed files with 7 additions and 6 deletions

View File

@ -14,18 +14,16 @@ The **patch** part changes incrementally at each release.
* elasticsearch: tmpdir configuration compatible with 5.x also
* elasticsearch: add http.publish_host variable
* evoacme: disable old certbot cron also in cron.daily
* evoacme: support for SAN in self-signed certificates
* evolinux-base: add mail related aliases
* java: support for Oracle JRE
* kibana: log messages go to /var/log/kibana/kibana.log
* metricbeat: add a role (copied from filebeat)
* memcached: add support for multiple instances
* munin: properly rename Munin cache directory
* mysql: add an option to install the client development libraries (default: `False`)
* nagios-nrpe: add check_postgrey
### Changed
* evolinux-base: wider body for default page
* evolinux-base: improve hostname configuration (real vs. internal)
* evolinux-users: add sudo permission for bkctld check
* java8: renamed to java (java8 symlinked to java for backward compatibility)
* minifirewall: the tail file can be overwritten, or not (default: `True`)

View File

@ -37,9 +37,12 @@ evolinux_hostname_hosts: True
evolinux_hostname_mailname: True
evolinux_hostname: "{{ ansible_hostname }}"
evolinux_domain: "{{ ansible_domain }}"
evolinux_fqdn: "{{ ansible_fqdn }}"
evolinux_domain: "{{ ansible_domain }}"
evolinux_fqdn: "{{ evolinux_hostname }}.{{ evolinux_domain }}"
evolinux_internal_hostname: "{{ evolinux_hostname }}"
evolinux_internal_domain: "{{ evolinux_domain }}"
evolinux_internal_fqdn: "{{ evolinux_internal_hostname }}.{{ evolinux_internal_domain }}"
# kernel

View File

@ -26,7 +26,7 @@
lineinfile:
dest: /etc/postfix/main.cf
state: present
line: "mydestination = {{ evolinux_fqdn }} localhost.localdomain localhost"
line: "mydestination = {{ [evolinux_fqdn, evolinux_internal_fqdn] | unique | join(' ') }} localhost.localdomain localhost"
regexp: '^mydestination'
notify: reload postfix
tags: