-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
6959048
commit fc710a4
Showing
2 changed files
with
31 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
--- | ||
- hosts: all | ||
tasks: | ||
- name: Install requirements | ||
become: yes | ||
apt: | ||
name: | ||
- curl | ||
- ca-certificates | ||
state: present | ||
- name: step1 | ||
become: yes | ||
ansible.builtin.shell: install -d /usr/share/postgresql-common/pgdg | ||
- name: step2 | ||
become: yes | ||
ansible.builtin.shell: curl -o /usr/share/postgresql-common/pgdg/apt.postgresql.org.asc --fail https://www.postgresql.org/media/keys/ACCC4CF8.asc | ||
- name: step3 | ||
become: yes | ||
ansible.builtin.shell: sh -c 'echo "deb [signed-by=/usr/share/postgresql-common/pgdg/apt.postgresql.org.asc] https://apt.postgresql.org/pub/repos/apt $(lsb_release -cs)-pgdg main" > /etc/apt/sources.list.d/pgdg.list' | ||
- name: step4 | ||
become: yes | ||
ansible.builtin.shell: apt update | ||
- name: step5 | ||
become: yes | ||
ansible.builtin.shell: apt -y install postgresql-15 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters