Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion playbooks/pmm3-client_integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@
# mysql_service_name: "mysql_{{ rnd }}_{{ instance_ip }}"

- name: Install and start Percona Server 8.0
when: '"ps-5.7" in enabled_db'
when: '"ps-8.0" in enabled_db'
include_tasks: ../tasks/install_and_add_to_pmm_ps_80.yml

- name: Verify if Metric Endpoint with Auth works for Mysqld Exporter
Expand Down
16 changes: 10 additions & 6 deletions tasks/install_and_add_to_pmm_ps_80.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
# This task installs and starts Percona Server 5.7 on CentOS and Debian/Ubuntu
---
# This task installs and starts Percona Server 8.0 on CentOS and Debian/Ubuntu
#
# Task adjustments are handled by parent playbook vars:
# var "port_flag" : to access agent with custom port
# ex: port_flag: "--pmm-agent-listen-port={{ custom_port }}"
#

- name: enable ps-80 release repo
include_tasks: ./enable_repo.yml
vars:
Expand All @@ -30,13 +31,16 @@
shell: |
init_pass=$(grep "temporary password" /var/log/mysqld.log | awk '{print $NF}' | tail -1)
mysql --connect-expired-password -uroot --password="$init_pass" -e "ALTER USER 'root'@'localhost' IDENTIFIED BY 'U?fY)9s7|3gxUm';"
cp ../templates/my_57.j2 /root/.my.cnf
cp ../templates/my_80.j2 /root/.my.cnf

- name: copy .my.cnf with credentials on centos
when: ansible_os_family == "RedHat"
template: src=../templates/my_57.j2
dest=/root/.my.cnf
mode=0640 owner=root group=root
template:
src: ../templates/my_80.j2
dest: /root/.my.cnf
mode: 0640
owner: root
group: root

- name: add mysql instance for monitoring
when: ansible_os_family == "RedHat"
Expand Down
3 changes: 1 addition & 2 deletions tasks/pmm2-client_test_enabled_db.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,7 @@
enabled_db: "{{ db_list|select|list }}"
vars:
db_list:
- "{{ (ansible_os_family == 'RedHat' and ansible_distribution_major_version < '9') | ternary('ps-8.0','') }}"
- "{{ (ansible_os_family == 'Debian') | ternary('ps-8.0','') }}"
- "ps-8.0"
- "{{ (ansible_distribution == 'Debian' and ansible_distribution_major_version > '10') | ternary('psmdb-70','') }}"
- "{{ (ansible_distribution == 'Ubuntu' and ansible_distribution_major_version <= '18') | ternary('psmdb-60','') }}"
- "{{ (ansible_distribution == 'Ubuntu' and ansible_distribution_major_version > '18') | ternary('psmdb-70','') }}"
Expand Down
3 changes: 3 additions & 0 deletions templates/my_80.j2
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[client]
user=root
password=U?fY)9s7|3gxUm