More ansible-lint fixes
This commit is contained in:
@ -1,12 +1,12 @@
|
||||
---
|
||||
|
||||
- include_tasks: "{{ role_path }}/tasks/server_base/setup_redhat.yml"
|
||||
- ansible.builtin.include_tasks: "{{ role_path }}/tasks/server_base/setup_redhat.yml"
|
||||
when: ansible_os_family == 'RedHat' and ansible_distribution_major_version|int < 8
|
||||
|
||||
- include_tasks: "{{ role_path }}/tasks/server_base/setup_redhat8.yml"
|
||||
- ansible.builtin.include_tasks: "{{ role_path }}/tasks/server_base/setup_redhat8.yml"
|
||||
when: ansible_os_family == 'RedHat' and ansible_distribution_major_version|int > 7 and ansible_distribution_major_version|int < 30
|
||||
|
||||
- include_tasks: "{{ role_path }}/tasks/server_base/setup_fedora.yml"
|
||||
- ansible.builtin.include_tasks: "{{ role_path }}/tasks/server_base/setup_fedora.yml"
|
||||
when: ansible_os_family == 'RedHat' and ansible_distribution_major_version|int > 30
|
||||
|
||||
- block:
|
||||
@ -23,14 +23,14 @@
|
||||
setup: filter=ansible_lsb*
|
||||
when: lsb_release_installation_result.changed
|
||||
|
||||
- include_tasks: "{{ role_path }}/tasks/server_base/setup_debian.yml"
|
||||
- ansible.builtin.include_tasks: "{{ role_path }}/tasks/server_base/setup_debian.yml"
|
||||
when: (ansible_os_family == 'Debian') and (ansible_lsb.id != 'Raspbian')
|
||||
|
||||
- include_tasks: "{{ role_path }}/tasks/server_base/setup_raspbian.yml"
|
||||
- ansible.builtin.include_tasks: "{{ role_path }}/tasks/server_base/setup_raspbian.yml"
|
||||
when: (ansible_os_family == 'Debian') and (ansible_lsb.id == 'Raspbian')
|
||||
when: ansible_os_family == 'Debian'
|
||||
|
||||
- include_tasks: "{{ role_path }}/tasks/server_base/setup_archlinux.yml"
|
||||
- ansible.builtin.include_tasks: "{{ role_path }}/tasks/server_base/setup_archlinux.yml"
|
||||
when: ansible_distribution == 'Archlinux'
|
||||
|
||||
- name: Ensure Docker is started and autoruns
|
||||
|
@ -13,4 +13,4 @@
|
||||
name:
|
||||
- docker
|
||||
state: latest
|
||||
when: matrix_docker_installation_enabled|bool
|
||||
when: matrix_docker_installation_enabled | bool
|
||||
|
@ -16,14 +16,14 @@
|
||||
state: present
|
||||
register: add_repository_key
|
||||
ignore_errors: true
|
||||
when: matrix_docker_installation_enabled|bool and matrix_docker_package_name == 'docker-ce'
|
||||
when: matrix_docker_installation_enabled | bool and matrix_docker_package_name == 'docker-ce'
|
||||
|
||||
- name: Ensure Docker repository is enabled
|
||||
apt_repository:
|
||||
repo: "deb [arch={{ matrix_debian_arch }}] https://download.docker.com/linux/{{ ansible_distribution|lower }} {{ ansible_distribution_release }} stable"
|
||||
state: present
|
||||
update_cache: true
|
||||
when: matrix_docker_installation_enabled|bool and matrix_docker_package_name == 'docker-ce'
|
||||
when: matrix_docker_installation_enabled | bool and matrix_docker_package_name == 'docker-ce'
|
||||
|
||||
- name: Ensure APT packages are installed
|
||||
ansible.builtin.apt:
|
||||
@ -38,4 +38,4 @@
|
||||
- "{{ matrix_docker_package_name }}"
|
||||
- "python{{'3' if ansible_python.version.major == 3 else ''}}-docker"
|
||||
state: latest
|
||||
when: matrix_docker_installation_enabled|bool
|
||||
when: matrix_docker_installation_enabled | bool
|
||||
|
@ -9,13 +9,13 @@
|
||||
mode: 0644
|
||||
with_items:
|
||||
- docker-ce-fedora.repo
|
||||
when: matrix_docker_installation_enabled|bool and matrix_docker_package_name == 'docker-ce'
|
||||
when: matrix_docker_installation_enabled | bool and matrix_docker_package_name == 'docker-ce'
|
||||
|
||||
- name: Ensure Docker's RPM key is trusted
|
||||
rpm_key:
|
||||
state: present
|
||||
key: https://download.docker.com/linux/fedora/gpg
|
||||
when: matrix_docker_installation_enabled|bool and matrix_docker_package_name == 'docker-ce'
|
||||
when: matrix_docker_installation_enabled | bool and matrix_docker_package_name == 'docker-ce'
|
||||
|
||||
- name: Ensure yum packages are installed
|
||||
ansible.builtin.yum:
|
||||
@ -30,10 +30,10 @@
|
||||
- "{{ matrix_docker_package_name }}"
|
||||
- python3-pip
|
||||
state: latest
|
||||
when: matrix_docker_installation_enabled|bool
|
||||
when: matrix_docker_installation_enabled | bool
|
||||
|
||||
- name: Ensure Docker-Py is installed
|
||||
pip:
|
||||
name: docker-py
|
||||
state: latest
|
||||
when: matrix_docker_installation_enabled|bool
|
||||
when: matrix_docker_installation_enabled | bool
|
||||
|
@ -16,14 +16,14 @@
|
||||
state: present
|
||||
register: add_repository_key
|
||||
ignore_errors: true
|
||||
when: matrix_docker_installation_enabled|bool and matrix_docker_package_name == 'docker-ce'
|
||||
when: matrix_docker_installation_enabled | bool and matrix_docker_package_name == 'docker-ce'
|
||||
|
||||
- name: Ensure Docker repository is enabled
|
||||
apt_repository:
|
||||
repo: "deb [arch={{ matrix_debian_arch }}] https://download.docker.com/linux/raspbian {{ ansible_distribution_release }} stable"
|
||||
state: present
|
||||
update_cache: true
|
||||
when: matrix_docker_installation_enabled|bool and matrix_docker_package_name == 'docker-ce'
|
||||
when: matrix_docker_installation_enabled | bool and matrix_docker_package_name == 'docker-ce'
|
||||
|
||||
- name: Ensure APT packages are installed
|
||||
ansible.builtin.apt:
|
||||
@ -38,4 +38,4 @@
|
||||
- "{{ matrix_docker_package_name }}"
|
||||
- "python{{'3' if ansible_python.version.major == 3 else ''}}-docker"
|
||||
state: latest
|
||||
when: matrix_docker_installation_enabled|bool
|
||||
when: matrix_docker_installation_enabled | bool
|
||||
|
@ -7,13 +7,13 @@
|
||||
owner: "root"
|
||||
group: "root"
|
||||
mode: 0644
|
||||
when: matrix_docker_installation_enabled|bool and matrix_docker_package_name == 'docker-ce'
|
||||
when: matrix_docker_installation_enabled | bool and matrix_docker_package_name == 'docker-ce'
|
||||
|
||||
- name: Ensure Docker's RPM key is trusted
|
||||
rpm_key:
|
||||
state: present
|
||||
key: https://download.docker.com/linux/centos/gpg
|
||||
when: matrix_docker_installation_enabled|bool and matrix_docker_package_name == 'docker-ce'
|
||||
when: matrix_docker_installation_enabled | bool and matrix_docker_package_name == 'docker-ce'
|
||||
|
||||
- name: Ensure yum packages are installed
|
||||
ansible.builtin.yum:
|
||||
@ -28,4 +28,4 @@
|
||||
- "{{ matrix_docker_package_name }}"
|
||||
- docker-python
|
||||
state: latest
|
||||
when: matrix_docker_installation_enabled|bool
|
||||
when: matrix_docker_installation_enabled | bool
|
||||
|
@ -7,13 +7,13 @@
|
||||
owner: "root"
|
||||
group: "root"
|
||||
mode: 0644
|
||||
when: matrix_docker_installation_enabled|bool and matrix_docker_package_name == 'docker-ce'
|
||||
when: matrix_docker_installation_enabled | bool and matrix_docker_package_name == 'docker-ce'
|
||||
|
||||
- name: Ensure Docker's RPM key is trusted
|
||||
rpm_key:
|
||||
state: present
|
||||
key: https://download.docker.com/linux/centos/gpg
|
||||
when: matrix_docker_installation_enabled|bool and matrix_docker_package_name == 'docker-ce'
|
||||
when: matrix_docker_installation_enabled | bool and matrix_docker_package_name == 'docker-ce'
|
||||
|
||||
- name: Ensure EPEL is installed
|
||||
ansible.builtin.yum:
|
||||
@ -35,10 +35,10 @@
|
||||
- "{{ matrix_docker_package_name }}"
|
||||
- python3-pip
|
||||
state: latest
|
||||
when: matrix_docker_installation_enabled|bool
|
||||
when: matrix_docker_installation_enabled | bool
|
||||
|
||||
- name: Ensure Docker-Py is installed
|
||||
pip:
|
||||
name: docker-py
|
||||
state: latest
|
||||
when: matrix_docker_installation_enabled|bool
|
||||
when: matrix_docker_installation_enabled | bool
|
||||
|
Reference in New Issue
Block a user