2018-10-14 21:17:40 +00:00
|
|
|
---
|
2022-04-03 12:53:03 +00:00
|
|
|
- name: Add PostgreSQL repository
|
|
|
|
yum_repository:
|
|
|
|
name: "postgresql-{{ __postgres_version }}"
|
|
|
|
file: "{{ postgres_repository_filename }}"
|
|
|
|
description: "PostgreSQL {{ __postgres_version }} yum repository"
|
|
|
|
baseurl: "https://download.postgresql.org/pub/repos/yum/{{ __postgres_version }}/redhat/rhel-{{ ansible_distribution_major_version }}-{{ ansible_architecture }}"
|
|
|
|
gpgcheck: yes
|
|
|
|
enabled: yes
|
|
|
|
gpgkey: "https://download.postgresql.org/pub/repos/yum/RPM-GPG-KEY-PGDG-{{ __postgres_version }}"
|
2022-04-03 13:13:11 +00:00
|
|
|
become: True
|
|
|
|
become_user: root
|
|
|
|
when: postgres_repository_enabled | bool
|