fix(bootstrap): unify resolv.conf to live environment DNS symlink

This commit is contained in:
2026-02-20 20:12:42 +01:00
parent 23a798a63a
commit 42cb5071c2
10 changed files with 7 additions and 75 deletions

View File

@@ -55,18 +55,6 @@
register: bootstrap_debian_base_result
changed_when: bootstrap_debian_base_result.rc == 0
- name: Generate resolv.conf for chroot
ansible.builtin.copy:
content: |
{% for ns in system_cfg.network.dns.servers | default(['1.1.1.1', '8.8.8.8']) %}
nameserver {{ ns }}
{% endfor %}
{% if system_cfg.network.dns.search | default([]) | length > 0 %}
search {{ system_cfg.network.dns.search | join(' ') }}
{% endif %}
dest: /mnt/etc/resolv.conf
mode: "0644"
- name: Install extra packages
when: bootstrap_debian_extra_packages | length > 0
ansible.builtin.command: "{{ chroot_command }} apt install -y {{ bootstrap_debian_extra_args }}"