Skip to content

Commit

Permalink
update php (#5422)
Browse files Browse the repository at this point in the history
* update php

update php from 8.1 to 8.3

* no idea what I was doing

talk later

* use specific version of mariadb

* python packages are included in mariadb server

* test for 8.3 version

* properly test for mariadb
  • Loading branch information
kayiwa authored Oct 7, 2024
1 parent 670def2 commit c00d161
Show file tree
Hide file tree
Showing 15 changed files with 33 additions and 38 deletions.
2 changes: 1 addition & 1 deletion roles/byzantine/molecule/default/verify.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
- name: Verify
hosts: all
vars:
- php_version: "8.1"
- php_version: "8.3"
gather_facts: false
tasks:
- name: test for presence byzantine sudoer commands
Expand Down
4 changes: 3 additions & 1 deletion roles/drupal/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -194,4 +194,6 @@
- gulp-cli
- gulp
become: true
when: install_nodejs | default(true)
when:
- running_on_server
- install_nodejs | default(true)
4 changes: 2 additions & 2 deletions roles/drupal10/defaults/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,6 @@ trusted_host_patterns:
drupal_base_dir: '/var/www'
drupal_project: 'drupal10'
drupal_docroot: "{{ drupal_base_dir }}/{{ drupal_project }}"
php_version: '8.1'
phpeol_version: '7.4'
php_version: '8.3'
phpeol_version: '8.1'
php_webserver: 'nginx'
4 changes: 2 additions & 2 deletions roles/drupal10/molecule/default/verify.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
hosts: all
gather_facts: false
vars:
- php_version: "8.1"
- php_unwanted_version: "7.4"
- php_version: "8.3"
- php_unwanted_version: "8.1"
tasks:
- name: test for presence libwww apache config
lineinfile:
Expand Down
6 changes: 3 additions & 3 deletions roles/ealapps/molecule/default/verify.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,16 @@
hosts: all
gather_facts: false
tasks:
- name: check php curl status
- name: Check php curl status
ansible.builtin.package:
name: "{{ item }}"
state: present
check_mode: true
register: pkg_status
loop:
- php8.1-curl
- php8.3-curl

- name: test for ruby packages
- name: Test for PHP packages
assert:
that:
- not pkg_status.changed
2 changes: 1 addition & 1 deletion roles/libwww/molecule/default/verify.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
- name: Verify
hosts: all
vars:
- php_version: "8.0"
- php_version: "8.3"
gather_facts: false
tasks:
- name: test for presence libwww apache config
Expand Down
2 changes: 1 addition & 1 deletion roles/libwww/vars/main.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
# vars file for roles/libwww
php_version: "8.1"
php_version: "8.3"
app_db_host: "{{ db_host | default('localhost') }}"
app_db_user: "{{ drupal_db_user | default('locator') }}"
app_db_password: "{{ drupal_db_password | default('change_me') }}"
Expand Down
7 changes: 3 additions & 4 deletions roles/mysql/molecule/default/verify.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,16 @@
hosts: all
gather_facts: false
tasks:
- name: check mariadb package status
- name: Check mariadb package status
ansible.builtin.package:
name: "{{ item }}"
state: present
check_mode: true
register: pkg_status
loop:
- mariadb-server
- mysql-common
- mariadb-server-10.6

- name: test for ruby packages
- name: Test for mariadb packages
ansible.builtin.assert:
that:
- not pkg_status.changed
14 changes: 5 additions & 9 deletions roles/mysql/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,11 @@
#
- name: MySQL | Install pkg-config
ansible.builtin.apt:
name: pkg-config
state: present
name: "{{ item }}"
state: present
loop:
- pkg-config
- python3-dev

- name: MySQL | Install MariaDB key
ansible.builtin.apt_key:
Expand All @@ -28,13 +31,6 @@
when:
- running_on_server

- name: MySQL | Install python database client packages
ansible.builtin.pip:
name: mysqlclient
changed_when: false
when:
- running_on_server

- name: MySQL | install mysql
ansible.builtin.apt:
name: "{{ mysql_packages }}"
Expand Down
2 changes: 1 addition & 1 deletion roles/mysql/vars/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
mysql_name: mariadb # please be sure that this will install mariadb

mysql_packages:
- mariadb-server
- mariadb-server-10.6
- python3-mysqldb

mysql_client_packages:
Expand Down
2 changes: 1 addition & 1 deletion roles/ojs/defaults/main.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
# Note that ojs_version must match one of the downloadable packages from
# https://pkp.sfu.ca/ojs/ojs_download/
php_version: "8.1"
php_version: "8.3"
ojs_version: "3.3.0-8"

server:
Expand Down
4 changes: 2 additions & 2 deletions roles/php/defaults/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,5 @@ datadog_service_name: test
datadog_environment: none
php_memory_limit: '256M'
php_webserver: 'apache2'
php_version: '8.1'
php_unwanted_version: '7.4'
php_version: '8.3'
php_unwanted_version: '8.1'
14 changes: 6 additions & 8 deletions roles/php/molecule/default/verify.yml
Original file line number Diff line number Diff line change
@@ -1,19 +1,17 @@
---
# This is an example playbook to execute Ansible tests.

- name: Verify
hosts: all
gather_facts: false
tasks:
- name: test for php packages
apt:
- name: Test for php packages
ansible.builtin.apt:
name: "{{ item }}"
state: present
loop:
- php8.1
- php8.1-dev
- php8.1-curl
- php8.1-zip
- php8.3
- php8.3-dev
- php8.3-curl
- php8.3-zip
- datadog-php-tracer
check_mode: true
register: present
Expand Down
2 changes: 1 addition & 1 deletion roles/special_collections/molecule/default/verify.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
- name: Verify
hosts: all
vars:
- php_version: "8.1"
- php_version: "8.3"
gather_facts: false
tasks:
- name: test for presence special collection sudoer commands
Expand Down
2 changes: 1 addition & 1 deletion roles/video_reserves/molecule/default/verify.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
hosts: all
gather_facts: false
vars:
- php_version: "8.1"
- php_version: "8.3"
tasks:
- name: check php curl status
ansible.builtin.package:
Expand Down

0 comments on commit c00d161

Please sign in to comment.