Add initial backup support

* sahred backup with backup feature configuration steps
* Initial structure for backup  manager
* include backup configuration steps into ceph_rgw

Change-Id: I0b88eef4e0e5e6eab93488ac99d8ea9face1c205
diff --git a/tcp_tests/templates/shared-backup-restore.yaml b/tcp_tests/templates/shared-backup-restore.yaml
new file mode 100644
index 0000000..c85e684
--- /dev/null
+++ b/tcp_tests/templates/shared-backup-restore.yaml
@@ -0,0 +1,137 @@
+{# Collection of common macroses shared across different deployments #}
+
+{%- macro MACRO_BACKUP_BACKUPNINJA() %}
+- description: Apply backup state on minions
+  cmd: salt -C 'I@backupninja:server or backupninja:client' state.sls salt.minion
+  node_name: {{ HOSTNAME_CFG01 }}
+  retry: {count: 1, delay: 1}
+  skip_fail: false
+
+- description: Refresh grains and mine for the backupninja client node
+  cmd: |
+    salt -C 'I@backupninja:client' state.sls salt.minion.grains
+    salt -C 'I@backupninja:client' mine.flush
+    salt -C 'I@backupninja:client' mine.update
+  node_name: {{ HOSTNAME_CFG01 }}
+  retry: {count: 1, delay: 1}
+  skip_fail: false
+
+- description: Apply the backupninja state to the backupninja client node
+  cmd: |
+    salt -C 'I@backupninja:client' state.sls backupninja
+  node_name: {{ HOSTNAME_CFG01 }}
+  retry: {count: 1, delay: 1}
+  skip_fail: false
+
+- description: Refresh grains for the backupninja server node
+  cmd: |
+    salt -C 'I@backupninja:server' state.sls salt.minion.grains
+  node_name: {{ HOSTNAME_CFG01 }}
+  retry: {count: 1, delay: 1}
+  skip_fail: false
+
+- description: Apply the backupninja state to the backupninja server node
+  cmd: |
+    salt -C 'I@backupninja:server' state.sls backupninja
+  node_name: {{ HOSTNAME_CFG01 }}
+  retry: {count: 1, delay: 1}
+  skip_fail: false
+
+{%- endmacro %}
+
+{%- macro MACRO_BACKUP_XTRABACKUP() %}
+
+- description: Refresh pillars
+  cmd: salt '*' saltutil.refresh_pillar
+  node_name: {{ HOSTNAME_CFG01 }}
+  retry: {count: 1, delay: 1}
+  skip_fail: false
+
+- description: Apply the salt.minion state
+  cmd: |
+    salt -C 'I@xtrabackup:client or I@xtrabackup:server' state.sls salt.minion
+  node_name: {{ HOSTNAME_CFG01 }}
+  retry: {count: 1, delay: 1}
+  skip_fail: false
+
+- description: Refresh grains for the xtrabackup client node
+  cmd: salt -C 'I@xtrabackup:client' saltutil.sync_grains
+  node_name: {{ HOSTNAME_CFG01 }}
+  retry: {count: 1, delay: 1}
+  skip_fail: false
+
+- description: Update the mine for the xtrabackup client node
+  cmd: |
+    salt -C 'I@xtrabackup:client' mine.flush
+    salt -C 'I@xtrabackup:client' mine.update
+  node_name: {{ HOSTNAME_CFG01 }}
+  retry: {count: 1, delay: 1}
+  skip_fail: false
+
+- description: Apply the xtrabackup client state
+  cmd: |
+    salt -C 'I@xtrabackup:client' state.sls openssh.client,xtrabackup
+  node_name: {{ HOSTNAME_CFG01 }}
+  retry: {count: 1, delay: 1}
+  skip_fail: false
+
+- description: Apply the xtrabackup server state
+  cmd: |
+    salt -C 'I@xtrabackup:server' state.sls xtrabackup
+  node_name: {{ HOSTNAME_CFG01 }}
+  retry: {count: 1, delay: 1}
+  skip_fail: false
+
+{%- endmacro %}
+
+{%- macro MACRO_BACKUP_CEPH() %}
+
+- description: Refresh pillars
+  cmd: salt '*' saltutil.refresh_pillar
+  node_name: {{ HOSTNAME_CFG01 }}
+  retry: {count: 1, delay: 1}
+  skip_fail: false
+
+- description: Apply the salt.minion state
+  cmd: |
+    salt -C 'I@ceph:backup:client or I@ceph:backup:server' state.sls salt.minion
+  node_name: {{ HOSTNAME_CFG01 }}
+  retry: {count: 1, delay: 1}
+  skip_fail: false
+
+- description: Refresh grains for the ceph client node
+  cmd: salt -C 'I@ceph:backup:client' saltutil.sync_grains
+  node_name: {{ HOSTNAME_CFG01 }}
+  retry: {count: 1, delay: 1}
+  skip_fail: false
+
+- description: Update the mine for the  client node
+  cmd: |
+    salt -C 'I@ceph:backup:client' mine.flush
+    salt -C 'I@ceph:backup:client' mine.update
+  node_name: {{ HOSTNAME_CFG01 }}
+  retry: {count: 1, delay: 1}
+  skip_fail: false
+
+- description: Apply the backup client state
+  cmd: |
+    salt -C 'I@ceph:backup:client' state.sls openssh.client,ceph.backup
+  node_name: {{ HOSTNAME_CFG01 }}
+  retry: {count: 1, delay: 1}
+  skip_fail: false
+
+- description: Apply the backup server state
+  cmd: |
+    salt -C 'I@ceph:backup:server' state.sls ceph.backup
+  node_name: {{ HOSTNAME_CFG01 }}
+  retry: {count: 1, delay: 1}
+  skip_fail: false
+
+{%- endmacro %}
+
+
+
+
+
+
+