2015-12-30 17:11:33 +01:00
|
|
|
---
|
2018-06-21 06:17:03 +00:00
|
|
|
# Disable swap
|
2018-08-23 16:51:52 +02:00
|
|
|
- import_tasks: 0010-swapoff.yml
|
2018-11-01 18:08:50 +03:00
|
|
|
when:
|
|
|
|
- not dns_late
|
|
|
|
- disable_swap
|
2018-06-21 06:17:03 +00:00
|
|
|
|
2018-08-23 16:51:52 +02:00
|
|
|
- import_tasks: 0020-verify-settings.yml
|
2018-11-01 18:08:50 +03:00
|
|
|
when:
|
|
|
|
- not dns_late
|
2017-10-05 10:43:04 +03:00
|
|
|
tags:
|
|
|
|
- asserts
|
2017-01-02 12:14:03 +01:00
|
|
|
|
2018-08-23 16:51:52 +02:00
|
|
|
- import_tasks: 0040-set_facts.yml
|
2017-10-05 10:43:04 +03:00
|
|
|
tags:
|
2018-08-23 16:51:52 +02:00
|
|
|
- resolvconf
|
2017-10-05 10:43:04 +03:00
|
|
|
- facts
|
2016-08-26 13:24:47 -04:00
|
|
|
|
2018-08-23 16:51:52 +02:00
|
|
|
- import_tasks: 0050-create_directories.yml
|
2018-11-01 18:08:50 +03:00
|
|
|
when:
|
|
|
|
- not dns_late
|
2018-04-12 22:55:13 +03:00
|
|
|
|
2018-08-23 16:51:52 +02:00
|
|
|
- import_tasks: 0060-resolvconf.yml
|
2017-10-18 12:42:00 +02:00
|
|
|
when:
|
|
|
|
- dns_mode != 'none'
|
|
|
|
- resolvconf_mode == 'host_resolvconf'
|
2019-11-06 14:33:52 +03:00
|
|
|
- systemd_resolved_enabled.rc != 0
|
2022-02-26 13:29:23 -05:00
|
|
|
- networkmanager_enabled.rc != 0
|
2019-11-06 14:33:52 +03:00
|
|
|
tags:
|
|
|
|
- bootstrap-os
|
|
|
|
- resolvconf
|
|
|
|
|
|
|
|
- import_tasks: 0061-systemd-resolved.yml
|
|
|
|
when:
|
|
|
|
- dns_mode != 'none'
|
|
|
|
- resolvconf_mode == 'host_resolvconf'
|
|
|
|
- systemd_resolved_enabled.rc == 0
|
2017-10-18 12:42:00 +02:00
|
|
|
tags:
|
|
|
|
- bootstrap-os
|
|
|
|
- resolvconf
|
|
|
|
|
2021-03-03 10:27:20 -05:00
|
|
|
- import_tasks: 0062-networkmanager-unmanaged-devices.yml
|
2022-02-26 13:29:23 -05:00
|
|
|
when:
|
|
|
|
- networkmanager_enabled.rc == 0
|
2021-03-03 10:27:20 -05:00
|
|
|
tags:
|
|
|
|
- bootstrap-os
|
|
|
|
|
|
|
|
- import_tasks: 0063-networkmanager-dns.yml
|
2020-06-29 09:26:17 +02:00
|
|
|
when:
|
|
|
|
- dns_mode != 'none'
|
|
|
|
- resolvconf_mode == 'host_resolvconf'
|
2022-02-26 13:29:23 -05:00
|
|
|
- networkmanager_enabled.rc == 0
|
2020-06-29 09:26:17 +02:00
|
|
|
tags:
|
|
|
|
- bootstrap-os
|
|
|
|
- resolvconf
|
|
|
|
|
2018-08-23 16:51:52 +02:00
|
|
|
- import_tasks: 0070-system-packages.yml
|
2018-11-01 18:08:50 +03:00
|
|
|
when:
|
|
|
|
- not dns_late
|
2017-10-05 10:43:04 +03:00
|
|
|
tags:
|
|
|
|
- bootstrap-os
|
2017-02-09 18:16:52 +09:00
|
|
|
|
2018-08-23 16:51:52 +02:00
|
|
|
- import_tasks: 0080-system-configurations.yml
|
2018-11-01 18:08:50 +03:00
|
|
|
when:
|
|
|
|
- not dns_late
|
2017-10-05 10:43:04 +03:00
|
|
|
tags:
|
|
|
|
- bootstrap-os
|
2015-12-30 22:15:18 +01:00
|
|
|
|
2022-06-29 04:15:34 +08:00
|
|
|
- import_tasks: 0081-ntp-configurations.yml
|
|
|
|
when:
|
|
|
|
- not dns_late
|
|
|
|
- ntp_enabled
|
|
|
|
tags:
|
|
|
|
- bootstrap-os
|
|
|
|
|
2018-08-23 16:51:52 +02:00
|
|
|
- import_tasks: 0090-etchosts.yml
|
2018-11-01 18:08:50 +03:00
|
|
|
when:
|
|
|
|
- not dns_late
|
2017-10-05 10:43:04 +03:00
|
|
|
tags:
|
|
|
|
- bootstrap-os
|
|
|
|
- etchosts
|
2016-12-07 16:57:05 +01:00
|
|
|
|
2018-08-23 16:51:52 +02:00
|
|
|
- import_tasks: 0100-dhclient-hooks.yml
|
2017-04-26 14:11:13 +02:00
|
|
|
when:
|
|
|
|
- dns_mode != 'none'
|
|
|
|
- resolvconf_mode == 'host_resolvconf'
|
2022-03-29 00:11:11 -07:00
|
|
|
- dhclientconffile is defined
|
2021-10-01 18:11:23 +02:00
|
|
|
- not ansible_os_family in ["Flatcar", "Flatcar Container Linux by Kinvolk"]
|
2017-10-05 10:43:04 +03:00
|
|
|
tags:
|
|
|
|
- bootstrap-os
|
|
|
|
- resolvconf
|
2017-01-11 15:08:24 +01:00
|
|
|
|
2018-08-23 16:51:52 +02:00
|
|
|
- import_tasks: 0110-dhclient-hooks-undo.yml
|
2017-04-26 14:11:13 +02:00
|
|
|
when:
|
|
|
|
- dns_mode != 'none'
|
|
|
|
- resolvconf_mode != 'host_resolvconf'
|
2022-03-29 00:11:11 -07:00
|
|
|
- dhclientconffile is defined
|
2021-10-01 18:11:23 +02:00
|
|
|
- not ansible_os_family in ["Flatcar", "Flatcar Container Linux by Kinvolk"]
|
2017-10-05 10:43:04 +03:00
|
|
|
tags:
|
|
|
|
- bootstrap-os
|
|
|
|
- resolvconf
|
2017-01-11 15:08:24 +01:00
|
|
|
|
2018-10-17 21:27:11 +02:00
|
|
|
# We need to make sure the network is restarted early enough so that docker can later pick up the correct system
|
|
|
|
# nameservers and search domains
|
2021-07-12 10:00:47 +03:00
|
|
|
- name: Flush handlers
|
|
|
|
meta: flush_handlers
|
2018-10-17 21:27:11 +02:00
|
|
|
|
2016-12-12 14:14:22 +01:00
|
|
|
- name: Check if we are running inside a Azure VM
|
2017-02-17 16:22:34 -05:00
|
|
|
stat:
|
|
|
|
path: /var/lib/waagent/
|
2021-02-10 08:36:59 -05:00
|
|
|
get_attributes: no
|
|
|
|
get_checksum: no
|
|
|
|
get_mime: no
|
2016-12-12 14:14:22 +01:00
|
|
|
register: azure_check
|
2018-11-01 18:08:50 +03:00
|
|
|
when:
|
|
|
|
- not dns_late
|
2017-10-05 10:43:04 +03:00
|
|
|
tags:
|
|
|
|
- bootstrap-os
|
2016-12-12 14:14:22 +01:00
|
|
|
|
2018-08-23 16:51:52 +02:00
|
|
|
- import_tasks: 0120-growpart-azure-centos-7.yml
|
2017-04-26 14:11:13 +02:00
|
|
|
when:
|
2018-11-01 18:08:50 +03:00
|
|
|
- not dns_late
|
2017-04-26 14:11:13 +02:00
|
|
|
- azure_check.stat.exists
|
2021-04-23 09:50:03 +03:00
|
|
|
- ansible_os_family == "RedHat"
|
2017-10-05 10:43:04 +03:00
|
|
|
tags:
|
|
|
|
- bootstrap-os
|
2022-04-14 11:08:46 +03:00
|
|
|
|
|
|
|
- name: Run calico checks
|
|
|
|
include_role:
|
|
|
|
name: network_plugin/calico
|
|
|
|
tasks_from: check
|
|
|
|
when:
|
|
|
|
- kube_network_plugin == 'calico'
|
|
|
|
- not ignore_assert_errors
|