diff --git a/VERSIONS b/VERSIONS index aec066ef9..31aa0f564 100644 --- a/VERSIONS +++ b/VERSIONS @@ -57,7 +57,7 @@ PXC80_REV="f4ae3e8" PXC80_WSREP="4.24(c71acc5)" PROXYSQL_VER="1.4.16-percona-1.1" PROXYSQL2_VER="2.7.3-percona-1.2" -PROXYSQL3_VER="3.0.1-percona-1.1" +PROXYSQL3_VER="3.0.6-percona-1.1" PMP_VER="1.1.7" SYSBENCH_VER="1.0.20" PBM_VER="1.0.0" diff --git a/binary-tarball-tests/proxysql/run.sh b/binary-tarball-tests/proxysql/run.sh index 57f69d927..58d2cfe52 100644 --- a/binary-tarball-tests/proxysql/run.sh +++ b/binary-tarball-tests/proxysql/run.sh @@ -59,7 +59,7 @@ else sudo apt-get install -y percona-xtrabackup-24 fi fi -if [[ $(lsb_release -sc) == 'bookworm' || $(lsb_release -sc) == 'noble' ]]; then +if [[ $(lsb_release -sc) == 'bookworm' || $(lsb_release -sc) == 'noble' || $(lsb_release -sc) == 'trixie' ]]; then pip3 install --user --break-system-packages pytest-testinfra pytest else pip3 install --user pytest-testinfra pytest diff --git a/molecule/proxysql-tarball/molecule/al-2023/molecule.yml b/molecule/proxysql-tarball/molecule/al-2023/molecule.yml new file mode 100644 index 000000000..1cb438e5a --- /dev/null +++ b/molecule/proxysql-tarball/molecule/al-2023/molecule.yml @@ -0,0 +1,48 @@ +--- +dependency: + name: galaxy +driver: + name: ec2 +platforms: + - name: al2023-${BUILD_NUMBER}-${BUILD_NUMBER}-${JOB_NAME}-proxysql-tarball + region: us-west-1 + image: ami-061ad72bc140532fd + vpc_subnet_id: subnet-04a8ad1b1d4da874c + instance_type: t2.large + ssh_user: ec2-user + root_device_name: /dev/xvda + instance_tags: + iit-billing-tag: proxysql-binary-tarball + job-name: ${JOB_NAME} +provisioner: + name: ansible + log: True + playbooks: + create: ../../playbooks/create.yml + destroy: ../../playbooks/destroy.yml + prepare: ../../playbooks/prepare.yml + cleanup: ../../playbooks/cleanup.yml + converge: ../../playbooks/playbook.yml +scenario: + name: al-2023 + destroy_sequence: + - destroy + clenup_sequence: + - cleanup + test_sequence: + - destroy + - create + - prepare + - converge + - verify + - cleanup + - destroy + +verifier: + name: testinfra + directory: ../../tests/ + options: + verbose: true + s: true + env: + MOLECULE_INVENTORY_FILE: ${MOLECULE_INVENTORY_FILE} diff --git a/molecule/proxysql-tarball/molecule/debian-11/molecule.yml b/molecule/proxysql-tarball/molecule/debian-11/molecule.yml index 4bd7f8298..c0f4fad5e 100644 --- a/molecule/proxysql-tarball/molecule/debian-11/molecule.yml +++ b/molecule/proxysql-tarball/molecule/debian-11/molecule.yml @@ -6,7 +6,7 @@ driver: platforms: - name: debian11-${BUILD_NUMBER}-${JOB_NAME}-proxysql-tarball region: us-west-1 - image: ami-09b4378b1d3387f81 + image: ami-02dda1c84e46dbe0a vpc_subnet_id: subnet-04a8ad1b1d4da874c instance_type: t2.large ssh_user: admin @@ -37,7 +37,7 @@ scenario: - verify - cleanup - destroy - + verifier: name: testinfra directory: ../../tests/ @@ -45,4 +45,4 @@ verifier: verbose: true s: true env: - MOLECULE_INVENTORY_FILE: ${MOLECULE_INVENTORY_FILE} \ No newline at end of file + MOLECULE_INVENTORY_FILE: ${MOLECULE_INVENTORY_FILE} diff --git a/molecule/proxysql-tarball/molecule/debian-13/molecule.yml b/molecule/proxysql-tarball/molecule/debian-13/molecule.yml new file mode 100644 index 000000000..c7439bbb0 --- /dev/null +++ b/molecule/proxysql-tarball/molecule/debian-13/molecule.yml @@ -0,0 +1,48 @@ +--- +dependency: + name: galaxy +driver: + name: ec2 +platforms: + - name: debian13-${BUILD_NUMBER}-${BUILD_NUMBER}-${JOB_NAME}-proxysql-tarball + region: us-west-1 + image: ami-0157ed312f9c59a91 + vpc_subnet_id: subnet-04a8ad1b1d4da874c + instance_type: t2.large + ssh_user: admin + root_device_name: /dev/xvda + instance_tags: + iit-billing-tag: proxysql-binary-tarball + job-name: ${JOB_NAME} +provisioner: + name: ansible + log: True + playbooks: + create: ../../playbooks/create.yml + destroy: ../../playbooks/destroy.yml + prepare: ../../playbooks/prepare.yml + cleanup: ../../playbooks/cleanup.yml + converge: ../../playbooks/playbook.yml +scenario: + name: debian-13 + destroy_sequence: + - destroy + clenup_sequence: + - cleanup + test_sequence: + - destroy + - create + - prepare + - converge + - verify + - cleanup + - destroy + +verifier: + name: testinfra + directory: ../../tests/ + options: + verbose: true + s: true + env: + MOLECULE_INVENTORY_FILE: ${MOLECULE_INVENTORY_FILE} diff --git a/molecule/proxysql-tarball/molecule/oracle-9/molecule.yml b/molecule/proxysql-tarball/molecule/oracle-9/molecule.yml index 34b983972..aefbba395 100644 --- a/molecule/proxysql-tarball/molecule/oracle-9/molecule.yml +++ b/molecule/proxysql-tarball/molecule/oracle-9/molecule.yml @@ -6,7 +6,7 @@ driver: platforms: - name: ol9-${BUILD_NUMBER}-${BUILD_NUMBER}-${JOB_NAME}-proxysql-tarball region: us-west-1 - image: ami-0d1958c85fb6a7b3e + image: ami-0fa0ed170a59f4917 vpc_subnet_id: subnet-04a8ad1b1d4da874c instance_type: t2.large ssh_user: ec2-user diff --git a/molecule/proxysql-tarball/tasks/main.yml b/molecule/proxysql-tarball/tasks/main.yml index 550a0f37e..f2d8e2d7f 100644 --- a/molecule/proxysql-tarball/tasks/main.yml +++ b/molecule/proxysql-tarball/tasks/main.yml @@ -14,39 +14,14 @@ until: result is not failed when: ansible_os_family == "Debian" -- name: Import MySQL GPG key (2023) - ansible.builtin.rpm_key: - state: present - key: https://repo.mysql.com/RPM-GPG-KEY-mysql-2023 - when: - - ansible_os_family == "RedHat" and ansible_distribution_major_version == "10" - -- name: Download MySQL 8.4 Community repo RPM - ansible.builtin.get_url: - url: https://repo.mysql.com/mysql84-community-release-el9-1.noarch.rpm - dest: /tmp/mysql84-community-release-el9-1.noarch.rpm - when: - - ansible_os_family == "RedHat" and ansible_distribution_major_version == "10" - -- name: Install MySQL repo RPM - ansible.builtin.yum: - name: /tmp/mysql84-community-release-el9-1.noarch.rpm - state: present - when: - - ansible_os_family == "RedHat" and ansible_distribution_major_version == "10" - -- name: Install MySQL 8.4 Community Server - ansible.builtin.yum: - name: mysql-community-server - state: present - when: - - ansible_os_family == "RedHat" and ansible_distribution_major_version == "10" - - name: install needed packages for running tests with yum yum: name: [git, unzip, wget, tar, numactl, gawk, python3, python3-pip, libev, socat, lsof, mysql] state: latest - when: ansible_os_family == "RedHat" + when: + - ansible_os_family == "RedHat" + - not (ansible_distribution == "Amazon" and ansible_distribution_major_version == "2023") + - not (ansible_distribution == "RedHat" and ansible_distribution_major_version == "10") - name: Install required packages using dnf dnf: diff --git a/molecule/proxysql/molecule/al-2023-arm/molecule.yml b/molecule/proxysql/molecule/al-2023-arm/molecule.yml new file mode 100644 index 000000000..bdd9cf1e7 --- /dev/null +++ b/molecule/proxysql/molecule/al-2023-arm/molecule.yml @@ -0,0 +1,38 @@ +--- +dependency: + name: galaxy +driver: + name: ec2 +platforms: + - name: al2023-arm-${BUILD_NUMBER}-${JOB_NAME}-${PLAYBOOK_VAR} + region: us-west-2 + image: ami-00478270b6d87a5d1 + vpc_subnet_id: subnet-03136d8c244f56036 + instance_type: c6g.large + ssh_user: ec2-user + root_device_name: /dev/xvda + instance_tags: + iit-billing-tag: proxysql-package-testing + job-name: ${JOB_NAME} +provisioner: + name: ansible + log: True + playbooks: + create: ../../playbooks/create.yml + destroy: ../../playbooks/destroy.yml + prepare: ../../playbooks/prepare.yml + cleanup: ../../playbooks/cleanup.yml + converge: ../../../../playbooks/${PLAYBOOK_VAR}.yml +scenario: + name: al-2023-arm + destroy_sequence: + - destroy + clenup_sequence: + - cleanup + test_sequence: + - destroy + - create + - prepare + - converge + - cleanup + - destroy diff --git a/molecule/proxysql/molecule/al-2023/molecule.yml b/molecule/proxysql/molecule/al-2023/molecule.yml new file mode 100644 index 000000000..d4ff239b2 --- /dev/null +++ b/molecule/proxysql/molecule/al-2023/molecule.yml @@ -0,0 +1,39 @@ +--- +dependency: + name: galaxy +driver: + name: ec2 +platforms: + - name: al2023-${BUILD_NUMBER}-${JOB_NAME}-${PLAYBOOK_VAR} + region: us-west-2 + image: ami-043ab4148b7bb33e9 + vpc_subnet_id: subnet-03136d8c244f56036 + instance_type: t2.medium + ssh_user: ec2-user + root_device_name: /dev/xvda + instance_tags: + iit-billing-tag: proxysql-package-testing + job-name: ${JOB_NAME} +provisioner: + name: ansible + log: True + playbooks: + create: ../../playbooks/create.yml + destroy: ../../playbooks/destroy.yml + prepare: ../../playbooks/prepare.yml + cleanup: ../../playbooks/cleanup.yml + converge: ../../../../playbooks/${PLAYBOOK_VAR}.yml +scenario: + name: al-2023 + destroy_sequence: + - destroy + clenup_sequence: + - cleanup + test_sequence: + - destroy + - create + - prepare + - converge + - verify + - cleanup + - destroy diff --git a/molecule/proxysql/molecule/debian-11-arm/molecule.yml b/molecule/proxysql/molecule/debian-11-arm/molecule.yml index 0fe0755c5..dabe3b173 100644 --- a/molecule/proxysql/molecule/debian-11-arm/molecule.yml +++ b/molecule/proxysql/molecule/debian-11-arm/molecule.yml @@ -6,7 +6,7 @@ driver: platforms: - name: debian11arm-${BUILD_NUMBER}-${JOB_NAME}-${PLAYBOOK_VAR} region: us-west-2 - image: ami-0058eefa46a15f8d5 + image: ami-0a4fc89e459b5c142 vpc_subnet_id: subnet-03136d8c244f56036 instance_type: c6g.large ssh_user: admin diff --git a/molecule/proxysql/molecule/debian-11/molecule.yml b/molecule/proxysql/molecule/debian-11/molecule.yml index c105bb014..aa74cdceb 100644 --- a/molecule/proxysql/molecule/debian-11/molecule.yml +++ b/molecule/proxysql/molecule/debian-11/molecule.yml @@ -6,7 +6,7 @@ driver: platforms: - name: debian11-${BUILD_NUMBER}-${JOB_NAME}-${PLAYBOOK_VAR} region: us-west-2 - image: ami-0d0f7602aa5c2425d + image: ami-01ce1f232a5e4adc2 vpc_subnet_id: subnet-03136d8c244f56036 instance_type: t2.micro ssh_user: admin diff --git a/molecule/proxysql/molecule/debian-13-arm/molecule.yml b/molecule/proxysql/molecule/debian-13-arm/molecule.yml new file mode 100644 index 000000000..aff955d39 --- /dev/null +++ b/molecule/proxysql/molecule/debian-13-arm/molecule.yml @@ -0,0 +1,39 @@ +--- +dependency: + name: galaxy +driver: + name: ec2 +platforms: + - name: debian13arm-${BUILD_NUMBER}-${JOB_NAME}-${PLAYBOOK_VAR} + region: us-west-2 + image: ami-00f9bd78b9eb2c2d0 + vpc_subnet_id: subnet-03136d8c244f56036 + instance_type: c6g.large + ssh_user: admin + root_device_name: /dev/xvda + instance_tags: + iit-billing-tag: proxysql-package-testing + job-name: ${JOB_NAME} +provisioner: + name: ansible + log: True + playbooks: + create: ../../playbooks/create.yml + destroy: ../../playbooks/destroy.yml + prepare: ../../playbooks/prepare.yml + cleanup: ../../playbooks/cleanup.yml + converge: ../../../../playbooks/${PLAYBOOK_VAR}.yml +scenario: + name: debian-13-arm + destroy_sequence: + - destroy + clenup_sequence: + - cleanup + test_sequence: + - destroy + - create + - prepare + - converge + - verify + - cleanup + - destroy diff --git a/molecule/proxysql/molecule/debian-13/molecule.yml b/molecule/proxysql/molecule/debian-13/molecule.yml new file mode 100644 index 000000000..7c7f5223b --- /dev/null +++ b/molecule/proxysql/molecule/debian-13/molecule.yml @@ -0,0 +1,39 @@ +--- +dependency: + name: galaxy +driver: + name: ec2 +platforms: + - name: debian13-${BUILD_NUMBER}-${JOB_NAME}-${PLAYBOOK_VAR} + region: us-west-2 + image: ami-081ac37fe26dacc98 + vpc_subnet_id: subnet-03136d8c244f56036 + instance_type: t2.micro + ssh_user: admin + root_device_name: /dev/xvda + instance_tags: + iit-billing-tag: proxysql-package-testing + job-name: ${JOB_NAME} +provisioner: + name: ansible + log: True + playbooks: + create: ../../playbooks/create.yml + destroy: ../../playbooks/destroy.yml + prepare: ../../playbooks/prepare.yml + cleanup: ../../playbooks/cleanup.yml + converge: ../../../../playbooks/${PLAYBOOK_VAR}.yml +scenario: + name: debian-13 + destroy_sequence: + - destroy + clenup_sequence: + - cleanup + test_sequence: + - destroy + - create + - prepare + - converge + - verify + - cleanup + - destroy diff --git a/molecule/proxysql/molecule/rhel-10-arm/molecule.yml b/molecule/proxysql/molecule/rhel-10-arm/molecule.yml new file mode 100644 index 000000000..c398ace46 --- /dev/null +++ b/molecule/proxysql/molecule/rhel-10-arm/molecule.yml @@ -0,0 +1,38 @@ +--- +dependency: + name: galaxy +driver: + name: ec2 +platforms: + - name: rhel10-arm-${BUILD_NUMBER}-${JOB_NAME}-${PLAYBOOK_VAR} + region: us-west-2 + image: ami-0ee25ba03b69968c5 + vpc_subnet_id: subnet-03136d8c244f56036 + instance_type: c6g.large + ssh_user: ec2-user + root_device_name: /dev/sda1 + instance_tags: + iit-billing-tag: proxysql-package-testing + job-name: ${JOB_NAME} +provisioner: + name: ansible + log: True + playbooks: + create: ../../playbooks/create.yml + destroy: ../../playbooks/destroy.yml + prepare: ../../playbooks/prepare.yml + cleanup: ../../playbooks/cleanup.yml + converge: ../../../../playbooks/${PLAYBOOK_VAR}.yml +scenario: + name: rhel-10-arm + destroy_sequence: + - destroy + clenup_sequence: + - cleanup + test_sequence: + - destroy + - create + - prepare + - converge + - cleanup + - destroy diff --git a/molecule/proxysql/molecule/rhel-10/molecule.yml b/molecule/proxysql/molecule/rhel-10/molecule.yml new file mode 100644 index 000000000..2eb6eeb51 --- /dev/null +++ b/molecule/proxysql/molecule/rhel-10/molecule.yml @@ -0,0 +1,39 @@ +--- +dependency: + name: galaxy +driver: + name: ec2 +platforms: + - name: rhel10-${BUILD_NUMBER}-${JOB_NAME}-${PLAYBOOK_VAR} + region: us-west-2 + image: ami-0987e9d53da324257 + vpc_subnet_id: subnet-03136d8c244f56036 + instance_type: t2.medium + ssh_user: ec2-user + root_device_name: /dev/sda1 + instance_tags: + iit-billing-tag: proxysql-package-testing + job-name: ${JOB_NAME} +provisioner: + name: ansible + log: True + playbooks: + create: ../../playbooks/create.yml + destroy: ../../playbooks/destroy.yml + prepare: ../../playbooks/prepare.yml + cleanup: ../../playbooks/cleanup.yml + converge: ../../../../playbooks/${PLAYBOOK_VAR}.yml +scenario: + name: rhel-10 + destroy_sequence: + - destroy + clenup_sequence: + - cleanup + test_sequence: + - destroy + - create + - prepare + - converge + - verify + - cleanup + - destroy diff --git a/playbooks/proxysql3.yml b/playbooks/proxysql3.yml index 9d29779f8..820424e0c 100644 --- a/playbooks/proxysql3.yml +++ b/playbooks/proxysql3.yml @@ -43,17 +43,47 @@ state: latest vars: packages: - - proxysql2 + - proxysql3 when: ansible_os_family == "RedHat" - name: start proxysql service service: name=proxysql state=started + when: ansible_distribution != "Amazon" - name: stop proxysql service service: name=proxysql state=stopped + when: ansible_distribution != "Amazon" - name: start proxysql service service: name=proxysql state=started + when: ansible_distribution != "Amazon" + + - name: start proxysql service again on non-AL2023 + service: + name: proxysql + state: started + when: not ( + ansible_distribution == "Amazon" and + ansible_distribution_major_version == "2023" + ) + + - name: stop proxysql service on non-AL2023 + service: + name: proxysql + state: stopped + when: not ( + ansible_distribution == "Amazon" and + ansible_distribution_major_version == "2023" + ) + + - name: start proxysql service again on non-AL2023 + service: + name: proxysql + state: started + when: not ( + ansible_distribution == "Amazon" and + ansible_distribution_major_version == "2023" + ) - name: run client_check tasks include_tasks: ../tasks/client_check.yml diff --git a/playbooks/proxysql3_maj_upgrade.yml b/playbooks/proxysql3_maj_upgrade.yml index 177511a20..3b999106e 100644 --- a/playbooks/proxysql3_maj_upgrade.yml +++ b/playbooks/proxysql3_maj_upgrade.yml @@ -48,12 +48,29 @@ - name: start proxysql service service: name=proxysql state=started + when: ansible_distribution != "Amazon" - name: stop proxysql service service: name=proxysql state=stopped - -# - name: start proxysql service -# service: name=proxysql state=started + when: ansible_distribution != "Amazon" + + - name: stop proxysql service on non-AL2023 + service: + name: proxysql + state: stopped + when: not ( + ansible_distribution == "Amazon" and + ansible_distribution_major_version == "2023" + ) + + - name: start proxysql service again on non-AL2023 + service: + name: proxysql + state: started + when: not ( + ansible_distribution == "Amazon" and + ansible_distribution_major_version == "2023" + ) - name: install proxysql3 new deb packages apt: @@ -66,25 +83,44 @@ when: ansible_os_family == "Debian" - name: install proxysql3 new rpm packages - yum: - name: "{{ packages }}" + dnf: + name: + - proxysql3 state: latest - vars: - packages: - - proxysql3 + allowerasing: true when: ansible_os_family == "RedHat" - - name: run client_check tasks - include_tasks: ../tasks/client_check.yml - - - name: check that proxysql3 version is correct - command: /package-testing/version_check.sh proxysql3 - - name: start proxysql service service: name=proxysql state=started + when: ansible_distribution != "Amazon" - name: stop proxysql service service: name=proxysql state=stopped + when: ansible_distribution != "Amazon" + + - name: stop proxysql service on non-AL2023 + service: + name: proxysql + state: stopped + when: not ( + ansible_distribution == "Amazon" and + ansible_distribution_major_version == "2023" + ) + + - name: start proxysql service again on non-AL2023 + service: + name: proxysql + state: started + when: not ( + ansible_distribution == "Amazon" and + ansible_distribution_major_version == "2023" + ) + + - name: run client_check tasks + include_tasks: ../tasks/client_check.yml + + - name: check that proxysql3 version is correct + command: /package-testing/version_check.sh proxysql3 - name: start proxysql service service: name=proxysql state=started diff --git a/playbooks/proxysql3_upgrade.yml b/playbooks/proxysql3_upgrade.yml index c13fe09af..ed132d267 100644 --- a/playbooks/proxysql3_upgrade.yml +++ b/playbooks/proxysql3_upgrade.yml @@ -45,12 +45,42 @@ - name: start proxysql service service: name=proxysql state=started + when: ansible_distribution != "Amazon" - name: stop proxysql service service: name=proxysql state=stopped + when: ansible_distribution != "Amazon" - name: start proxysql service service: name=proxysql state=started + when: ansible_distribution != "Amazon" + + - name: start proxysql service again on non-AL2023 + service: + name: proxysql + state: started + when: not ( + ansible_distribution == "Amazon" and + ansible_distribution_major_version == "2023" + ) + + - name: stop proxysql service on non-AL2023 + service: + name: proxysql + state: stopped + when: not ( + ansible_distribution == "Amazon" and + ansible_distribution_major_version == "2023" + ) + + - name: start proxysql service again on non-AL2023 + service: + name: proxysql + state: started + when: not ( + ansible_distribution == "Amazon" and + ansible_distribution_major_version == "2023" + ) # # Enable testing repository diff --git a/tasks/enable_proxysql2_main.yml b/tasks/enable_proxysql2_main.yml index b623c20d5..13eb14c9e 100644 --- a/tasks/enable_proxysql2_main.yml +++ b/tasks/enable_proxysql2_main.yml @@ -11,22 +11,17 @@ deb: https://repo.percona.com/apt/percona-release_latest.generic_all.deb when: ansible_os_family == "Debian" - - name: Receive GPG key 1 - command: "gpg --batch --keyserver keyserver.ubuntu.com --recv-keys {{ percona_key1 }}" - environment: - GNUPGHOME: "{{ gnupg_home }}" - when: ansible_os_family == "RedHat" - - - name: Export GPG key 1 - command: "gpg --batch --export --armor {{ percona_key1 }}" - register: gpg_key1 - environment: - GNUPGHOME: "{{ gnupg_home }}" - when: ansible_os_family == "RedHat" - - - name: Save GPG key 1 to file - copy: - content: "{{ gpg_key1.stdout }}" + - name: Ensure gnupg home exists (Amazon Linux) + file: + path: "{{ gnupg_home }}" + state: directory + mode: '0700' + when: + - ansible_os_family == "RedHat" + + - name: Download Percona GPG key from Percona's repo (Amazon Linux) + get_url: + url: https://repo.percona.com/yum/PERCONA-PACKAGING-KEY dest: "{{ percona_key1_file }}" mode: '0644' when: ansible_os_family == "RedHat" @@ -50,7 +45,7 @@ ## PS 57 EOL - name: Enable PS 57 EOL repos - include_tasks: enable_ps57_eol_tools_repo.yml + include_tasks: enable_ps57_eol_release_repo.yml when: lookup('env', 'client_to_test') == "ps57" # - name: Mandatory step for PXC 57 EOL (Disable all old repos) diff --git a/tasks/enable_proxysql2_testing.yml b/tasks/enable_proxysql2_testing.yml index b3bcbfbc4..b7efe8bab 100644 --- a/tasks/enable_proxysql2_testing.yml +++ b/tasks/enable_proxysql2_testing.yml @@ -11,22 +11,17 @@ deb: https://repo.percona.com/apt/percona-release_latest.generic_all.deb when: ansible_os_family == "Debian" - - name: Receive GPG key 1 - command: "gpg --batch --keyserver keyserver.ubuntu.com --recv-keys {{ percona_key1 }}" - environment: - GNUPGHOME: "{{ gnupg_home }}" - when: ansible_os_family == "RedHat" - - - name: Export GPG key 1 - command: "gpg --batch --export --armor {{ percona_key1 }}" - register: gpg_key1 - environment: - GNUPGHOME: "{{ gnupg_home }}" - when: ansible_os_family == "RedHat" - - - name: Save GPG key 1 to file - copy: - content: "{{ gpg_key1.stdout }}" + - name: Ensure gnupg home exists (Amazon Linux) + file: + path: "{{ gnupg_home }}" + state: directory + mode: '0700' + when: + - ansible_os_family == "RedHat" + + - name: Download Percona GPG key from Percona's repo (Amazon Linux) + get_url: + url: https://repo.percona.com/yum/PERCONA-PACKAGING-KEY dest: "{{ percona_key1_file }}" mode: '0644' when: ansible_os_family == "RedHat" @@ -50,7 +45,7 @@ ## PS 57 EOL - name: Enable PS 57 EOL repos - include_tasks: enable_ps57_eol_tools_repo.yml + include_tasks: enable_ps57_eol_release_repo.yml when: lookup('env', 'client_to_test') == "ps57" # - name: Mandatory step for PXC 57 EOL (Disable all old repos) diff --git a/tasks/enable_pxc57_eol_proxysql2.yml b/tasks/enable_pxc57_eol_proxysql2.yml index d6f639d03..2d2b8ad81 100644 --- a/tasks/enable_pxc57_eol_proxysql2.yml +++ b/tasks/enable_pxc57_eol_proxysql2.yml @@ -38,11 +38,32 @@ when: - ansible_os_family == "RedHat" - - name: Mandatory step for PXC 57 EOL (Disable all old repos) - command: percona-release disable all + - name: Download Percona GPG key + ansible.builtin.get_url: + url: https://github.com/percona/percona-repositories/raw/main/deb/percona-keyring.gpg + dest: /tmp/percona-keyring.gpg + mode: '0644' + when: ansible_os_family == "Debian" - - name: Mandatory step for PXC 57 EOL (Enable only pxc-57) - command: percona-release setup -y pxc-57 + - name: Install Percona GPG key + ansible.builtin.copy: + src: /tmp/percona-keyring.gpg + dest: /etc/apt/trusted.gpg.d/percona-keyring.gpg + remote_src: yes + mode: '0644' + when: ansible_os_family == "Debian" + +# - name: Mandatory step for PXC 57 EOL (Disable all old repos) +# command: percona-release disable all + +# - name: Mandatory step for PXC 57 EOL (Enable only pxc-57) +# command: percona-release setup -y pxc-57 + + - name: clean and update yum cache + shell: | + yum clean all + yum makecache + when: ansible_os_family == "RedHat" - name: update deb cache apt: diff --git a/tasks/test_prep.yml b/tasks/test_prep.yml index e57f955a2..1faa576e0 100644 --- a/tasks/test_prep.yml +++ b/tasks/test_prep.yml @@ -250,10 +250,10 @@ with_items: - rm -rf /package-testing - rm -f master.zip - - wget --no-check-certificate -O master.zip "https://github.com/{{ git_account }}/package-testing/archive/{{ branch }}.zip" + - wget --no-check-certificate -O master.zip "https://github.com/kaushikpuneet07/package-testing/archive/proxy-f.zip" - unzip master.zip - rm -f master.zip - - mv "package-testing-{{ branch }}" /package-testing + - mv "package-testing-proxy-f" /package-testing vars: branch: "{{ lookup('env', 'TESTING_BRANCH') | default('master', true) }}" git_account: "{{ lookup('env', 'TESTING_GIT_ACCOUNT') | default('Percona-QA', true) }}"