mirror of
https://bitbucket.org/atlassian/dc-deployments-automation.git
synced 2025-12-14 00:43:06 -06:00
DCD-686: Install Postgres only if restoration is required.
This commit is contained in:
@@ -4,9 +4,7 @@ set -e
|
|||||||
|
|
||||||
source /etc/os-release
|
source /etc/os-release
|
||||||
if [[ $ID = "amzn" ]]; then
|
if [[ $ID = "amzn" ]]; then
|
||||||
amazon-linux-extras enable postgresql9.6
|
|
||||||
yum install -y \
|
yum install -y \
|
||||||
postgresql \
|
|
||||||
python3-devel \
|
python3-devel \
|
||||||
python3-pip \
|
python3-pip \
|
||||||
python2-boto3 \
|
python2-boto3 \
|
||||||
|
|||||||
7
roles/fetch_backups/tasks/amazon.yml
Normal file
7
roles/fetch_backups/tasks/amazon.yml
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
---
|
||||||
|
|
||||||
|
# Amazon Linux 2 supplies extra packages via a special command.
|
||||||
|
- name: Enable Postgresql from 'extras'
|
||||||
|
command: amazon-linux-extras install -y "postgresql{{ postgres_version }}"
|
||||||
|
args:
|
||||||
|
creates: /usr/bin/psql
|
||||||
@@ -69,4 +69,7 @@
|
|||||||
object: "{{ atl_backup_manifest.shared_home_dump | urlsplit('path') }}"
|
object: "{{ atl_backup_manifest.shared_home_dump | urlsplit('path') }}"
|
||||||
dest: "{{ atl_backup_home_dest }}"
|
dest: "{{ atl_backup_home_dest }}"
|
||||||
|
|
||||||
|
- name: Install distro-specific restore support packages
|
||||||
|
include_tasks: "{{ ansible_distribution|lower }}.yml"
|
||||||
|
|
||||||
when: atl_backup_manifest_url is defined and atl_backup_manifest_url != ''
|
when: atl_backup_manifest_url is defined and atl_backup_manifest_url != ''
|
||||||
|
|||||||
Reference in New Issue
Block a user