Switch to Rocky Linux
This commit is contained in:
parent
bf5c7a526e
commit
b8e18cdbe9
|
@ -2,25 +2,30 @@
|
||||||
# code: language=ansible
|
# code: language=ansible
|
||||||
---
|
---
|
||||||
- name: Add Docker PGP key
|
- name: Add Docker PGP key
|
||||||
ansible.builtin.apt_key:
|
ansible.builtin.rpm_key:
|
||||||
keyserver: keyserver.ubuntu.com
|
key: https://download.docker.com/linux/centos/gpg
|
||||||
id: '0x8D81803C0EBFCD88'
|
fingerprint: 060A 61C5 1B55 8A7F 742B 77AA C52F EB6B 621E 9F35
|
||||||
state: present
|
state: present
|
||||||
|
|
||||||
- name: Add Docker apt repository
|
- name: Add Docker repository
|
||||||
ansible.builtin.apt_repository:
|
ansible.builtin.yum_repository:
|
||||||
repo: 'deb [arch=amd64 signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] https://download.docker.com/linux/debian bullseye stable'
|
name: docker-ce-stable
|
||||||
update_cache: true
|
description: Docker CE Stable - $basearch
|
||||||
|
file: docker-ce
|
||||||
|
baseurl: https://download.docker.com/linux/centos/$releasever/$basearch/stable
|
||||||
|
gpgkey: https://download.docker.com/linux/centos/gpg
|
||||||
|
gpgcheck: true
|
||||||
|
enabled: true
|
||||||
state: present
|
state: present
|
||||||
|
|
||||||
- name: Install Docker
|
- name: Install Docker and Docker Compose
|
||||||
ansible.builtin.apt:
|
ansible.builtin.dnf:
|
||||||
name: "{{ pkgs }}"
|
name:
|
||||||
state: present
|
|
||||||
vars:
|
|
||||||
pkgs:
|
|
||||||
- docker-ce
|
- docker-ce
|
||||||
|
- docker-ce-cli
|
||||||
- docker-compose-plugin
|
- docker-compose-plugin
|
||||||
|
- containerd.io
|
||||||
|
state: present
|
||||||
|
|
||||||
- name: Copy Docker daemon config file
|
- name: Copy Docker daemon config file
|
||||||
ansible.builtin.template:
|
ansible.builtin.template:
|
||||||
|
|
|
@ -35,18 +35,25 @@
|
||||||
state: present
|
state: present
|
||||||
notify: Restart systemd-resolved
|
notify: Restart systemd-resolved
|
||||||
|
|
||||||
- name: Ensure UFW is absent
|
- name: Enable Security SIG repositories
|
||||||
ansible.builtin.apt:
|
ansible.builtin.dnf:
|
||||||
name: ufw
|
name: rocky-release-security
|
||||||
state: absent
|
state: present
|
||||||
|
|
||||||
- name: Install system packages
|
- name: Install system packages
|
||||||
ansible.builtin.apt:
|
ansible.builtin.dnf:
|
||||||
name: "{{ pkgs }}"
|
name:
|
||||||
update_cache: true
|
|
||||||
state: present
|
|
||||||
vars:
|
|
||||||
pkgs:
|
|
||||||
- apparmor
|
|
||||||
- haveged
|
- haveged
|
||||||
- firewalld
|
- firewalld
|
||||||
|
- lkrg
|
||||||
|
state: present
|
||||||
|
|
||||||
|
- name: Ensure services are enabled and running
|
||||||
|
ansible.builtin.service:
|
||||||
|
name: "{{ item }}"
|
||||||
|
enabled: true
|
||||||
|
state: started
|
||||||
|
loop:
|
||||||
|
- haveged
|
||||||
|
- firewalld
|
||||||
|
- lkrg
|
||||||
|
|
Loading…
Reference in a new issue