Allow specifying local engine for client-side storage
If backupninja backs up the database to the local storage
there is no need to use any engine, no engine config file needs
to be created.
Change-Id: Ie1274a63955bcc6f623c46324a3f34f8299a32e8
diff --git a/README.rst b/README.rst
index 8a29afa..cf21103 100644
--- a/README.rst
+++ b/README.rst
@@ -73,6 +73,16 @@
key: ssh-key
+Backup client with local storage
+
+.. code-block:: yaml
+
+ backupninja:
+ client:
+ enabled: true
+ target:
+ engine: local
+
More information
================
diff --git a/backupninja/client.sls b/backupninja/client.sls
index 7760800..cacece6 100644
--- a/backupninja/client.sls
+++ b/backupninja/client.sls
@@ -135,6 +135,8 @@
- require:
- pkg: backupninja_packages
+{%- if client.target.engine not in ["local"] %}
+
backupninja_remote_handler_{{ client.target.engine }}:
file.managed:
- name: /etc/backup.d/200.backup.{{ client.target.engine }}
@@ -144,6 +146,8 @@
- require:
- pkg: backupninja_packages
+{%- endif %}
+
{%- if client.target.auth is defined and client.target.auth.gss is defined %}
backupninja_gss_helper_kinit: