diff --git a/build/ansible/roles/pmm-images/tasks/main.yml b/build/ansible/roles/pmm-images/tasks/main.yml index 769a344be6..f07ac17571 100644 --- a/build/ansible/roles/pmm-images/tasks/main.yml +++ b/build/ansible/roles/pmm-images/tasks/main.yml @@ -144,6 +144,38 @@ state: installed enablerepo: "{{ pmm_client_repo_name }}" +- name: Remove ansible RPM if installed | EL9 + when: + - ansible_distribution == 'OracleLinux' or ansible_distribution == 'AlmaLinux' + - ansible_distribution_major_version == '9' + yum: + name: ansible + state: absent + ignore_errors: true + +- name: Install ansible-core RPM | EL9 + when: + - ansible_distribution == 'OracleLinux' or ansible_distribution == 'AlmaLinux' + - ansible_distribution_major_version == '9' + yum: + name: + - ansible-core + - ansible-collection-community-general + - ansible-collection-community-postgresql + - ansible-collection-ansible-posix + state: present + +- name: Update system packages EL9 + when: + - ansible_distribution == 'OracleLinux' or ansible_distribution == 'AlmaLinux' + - ansible_distribution_major_version == '9' + - not ansible_check_mode + yum: + name: "*" + state: latest + exclude: + - nginx* + - name: Disable pmm-agent service | Disable pmm-agent when: ansible_virtualization_type != "docker" service: name=pmm-agent state=stopped enabled=no diff --git a/update/ansible/playbook/tasks/roles/clickhouse/tasks/main.yml b/update/ansible/playbook/tasks/roles/clickhouse/tasks/main.yml index cdd4ddeeea..40607368e0 100644 --- a/update/ansible/playbook/tasks/roles/clickhouse/tasks/main.yml +++ b/update/ansible/playbook/tasks/roles/clickhouse/tasks/main.yml @@ -97,7 +97,7 @@ path: "/usr/bin/clickhouse-odbc-bridge" state: absent -- name: Change ownership for clickhouse directory +- name: Change ownership of clickhouse directory file: path: /srv/clickhouse/ owner: root diff --git a/update/ansible/playbook/tasks/update.yml b/update/ansible/playbook/tasks/update.yml index c84b100af6..099a75ac49 100644 --- a/update/ansible/playbook/tasks/update.yml +++ b/update/ansible/playbook/tasks/update.yml @@ -81,14 +81,6 @@ include_role: name: postgres - - name: Install nginx - include_role: - name: nginx - - - name: Install clickhouse - include_role: - name: clickhouse - # Set forking type to 'simple' - name: Configure systemd when: not is_docker @@ -184,37 +176,13 @@ - name: Wait for pmm-managed pause: seconds=10 - - name: Remove ansible RPM if installed | EL9 - when: - - ansible_distribution == 'OracleLinux' or ansible_distribution == 'AlmaLinux' - - ansible_distribution_major_version == '9' - yum: - name: ansible - state: absent - ignore_errors: true - - - name: Install ansible-core RPM | EL9 - when: - - ansible_distribution == 'OracleLinux' or ansible_distribution == 'AlmaLinux' - - ansible_distribution_major_version == '9' - yum: - name: - - ansible-core - - ansible-collection-community-general - - ansible-collection-community-postgresql - - ansible-collection-ansible-posix - state: present + - name: Install nginx + include_role: + name: nginx - - name: Update system packages EL9 - when: - - ansible_distribution == 'OracleLinux' or ansible_distribution == 'AlmaLinux' - - ansible_distribution_major_version == '9' - - not ansible_check_mode - yum: - name: "*" - state: latest - exclude: - - nginx* + - name: Install clickhouse + include_role: + name: clickhouse # Fix things that should be fixed before restarts.