Quellcode durchsuchen

parametrize backup server side dir

PROD-18191

Change-Id: I15c2cc66f0c0010408863b46c0dccf84730f31d9
pull/73/head
Jiri Broulik vor 6 Jahren
Ursprung
Commit
3e28164df7
2 geänderte Dateien mit 3 neuen und 2 gelöschten Zeilen
  1. +1
    -0
      README.rst
  2. +2
    -2
      salt/files/restore_master.sh

+ 1
- 0
README.rst Datei anzeigen

@@ -225,6 +225,7 @@ Salt master backup configuration
backup: true
initial_data:
engine: backupninja
home_dir: remote-backup-home-dir
source: backup-node-host
host: original-salt-master-id


+ 2
- 2
salt/files/restore_master.sh Datei anzeigen

@@ -4,8 +4,8 @@
{%- if master.initial_data is defined %}
mkdir -p /etc/salt/pki.bak
mv /etc/salt/pki/* /etc/salt/pki.bak
scp -r backupninja@{{ master.initial_data.source }}:/srv/backupninja/{{ master.initial_data.host }}/etc/salt/pki/pki.0/* /etc/salt/pki
scp -r backupninja@{{ master.initial_data.source }}:{{ master.initial_data.get('home_dir', '/srv/backupninja') }}/{{ master.initial_data.host }}/etc/salt/pki/pki.0/* /etc/salt/pki
{%- if master.pillar.engine == 'reclass' or (master.pillar.engine == 'composite' and master.pillar.reclass is defined) %}
scp -r backupninja@{{ master.initial_data.source }}:/srv/backupninja/{{ master.initial_data.host }}/srv/salt/reclass/reclass.0/* /srv/salt/reclass
scp -r backupninja@{{ master.initial_data.source }}:{{ master.initial_data.get('home_dir', '/srv/backupninja') }}/{{ master.initial_data.host }}/srv/salt/reclass/reclass.0/* /srv/salt/reclass
{%- endif %}
{%- endif %}

Laden…
Abbrechen
Speichern