Skip to content

Commit 14e033e

Browse files
ShimShteinevgeni
authored andcommitted
Switch to postgres 16 image
1 parent ba1f1a5 commit 14e033e

4 files changed

Lines changed: 13 additions & 13 deletions

File tree

development/playbooks/remote-database/remote-database.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
- "../../../src/vars/defaults.yml"
88
- "../../../src/vars/flavors/{{ flavor }}.yml"
99
- "../../../src/vars/database.yml"
10+
- "../../../src/vars/images.yml"
1011
vars:
1112
certificates_hostnames:
1213
- "{{ ansible_facts['fqdn'] }}"

src/roles/postgresql/tasks/main.yml

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -107,18 +107,6 @@
107107
name: "{{ postgresql_container_name }}"
108108
state: started
109109

110-
# SCRAM-SHA-256 is default for PostgreSQL 14+,
111-
# after the upgrade, we can drop this task.
112-
- name: Use scram-sha-256 for password encryption
113-
community.postgresql.postgresql_set:
114-
login_user: postgres
115-
login_password: "{{ postgresql_admin_password }}"
116-
login_host: localhost
117-
name: password_encryption
118-
value: "scram-sha-256"
119-
notify:
120-
- Restart postgresql
121-
122110
- name: Create PostgreSQL users
123111
community.postgresql.postgresql_user:
124112
name: "{{ item.name }}"

src/roles/pre_install/tasks/main.yaml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,17 @@
33
ansible.builtin.include_role:
44
name: debug_tools
55

6+
- name: 'Enable postgresql:16 module'
7+
ansible.builtin.command: dnf module enable -y postgresql:16
8+
# can't use the `dnf` module for modules without a default stream
9+
# https://github.com/ansible/ansible/issues/56504
10+
# https://github.com/ansible/ansible/issues/64852
11+
args:
12+
creates: /etc/dnf/modules.d/postgresql.module
13+
when:
14+
- ansible_facts['os_family'] == 'RedHat'
15+
- ansible_facts['distribution_major_version'] == '9'
16+
617
- name: Install podman
718
ansible.builtin.package:
819
name:

src/vars/images.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ foreman_container_tag: "{{ container_tag_stream }}"
99
foreman_proxy_container_image: "quay.io/foreman/foreman-proxy"
1010
foreman_proxy_container_tag: "{{ container_tag_stream }}"
1111

12-
postgresql_container_image: quay.io/sclorg/postgresql-13-c9s
12+
postgresql_container_image: quay.io/sclorg/postgresql-16-c10s
1313
postgresql_container_tag: "latest"
1414
pulp_container_image: quay.io/foreman/pulp
1515
pulp_container_tag: "foreman-{{ container_tag_stream }}"

0 commit comments

Comments
 (0)