Add optional fallback DNS servers to resolvconf

(cherry picked from commit 6f61a337d6335244dcf4946a4e460b822fb90c5f)
parent 0d0bd3ff
- Role: common
- Added `COMMON_FALLBACK_DNS_SERVERS`, which optionally adds additional `nameserver` entries to the resolvconf tail
- Explicitly added `resolvconf` as a dependency
- Role: edxapp
- Added creation of enterprise_worker user to provisioning. This user is used by the edx-enterprise package when making API requests to Open edX IDAs.
......
......@@ -145,6 +145,19 @@
shell: hostname -F /etc/hostname
when: COMMON_HOSTNAME|length >0 and (etc_hosts.changed or etc_hostname.changed)
- name: Add fallback DNS servers to resolvconf
lineinfile:
dest: /etc/resolvconf/resolv.conf.d/tail
line: "nameserver {{ item }}"
create: yes
state: present
with_items: "{{ COMMON_FALLBACK_DNS_SERVERS }}"
- name: restart networking
service:
name: networking
state: restarted
- name: Copy the templates to their respestive destination
template:
dest: "{{ item.dest }}"
......
......@@ -66,6 +66,9 @@ COMMON_GIT_PATH: 'edx' # git path prefix
# override this var to set a different hostname
COMMON_HOSTNAME: ""
# List of DNS server addresses to append to resolvconf
COMMON_FALLBACK_DNS_SERVERS: []
# Set to true to customize DNS search domains
COMMON_CUSTOM_DHCLIENT_CONFIG: false
# uncomment and specifity your domains.
......@@ -108,6 +111,7 @@ common_redhat_pkgs:
- git
- unzip
- acl
- resolvconf
common_debian_pkgs:
- apt-transport-https
- ntp
......@@ -119,6 +123,7 @@ common_debian_pkgs:
- unzip
- python-pip
- python2.7-dev
- resolvconf
# Packages that should be installed from our custom PPA, i.e. COMMON_EDX_PPA
old_python_debian_pkgs:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment