feat(repo): IaaS baseline
This commit is contained in:
@@ -20,11 +20,8 @@ ProtectSystem=strict
|
||||
ProtectHome=tmpfs
|
||||
InaccessiblePaths=/boot /root
|
||||
|
||||
{% if node['name'] == 'infra' %}
|
||||
BindReadOnlyPaths={{ node['home_path'] }}/containers/postgresql/backups
|
||||
{% elif node['name'] == 'app' %}
|
||||
BindReadOnlyPaths={{ node['home_path'] }}/data
|
||||
{% endif %}
|
||||
|
||||
# In root namescope, %u always bring 0
|
||||
BindPaths=/etc/kopia
|
||||
BindPaths=/etc/secrets/{{ kopia_uid }}
|
||||
@@ -36,14 +33,8 @@ ExecStartPre=/usr/bin/kopia repository connect server \
|
||||
--override-username={{ node['name'] }} \
|
||||
--override-hostname={{ node['name'] }}.{{ domain['internal'] }}
|
||||
|
||||
{% if node['name'] == 'infra' %}
|
||||
ExecStart=/usr/bin/kopia snapshot create \
|
||||
{{ node['home_path'] }}/containers/postgresql/backups
|
||||
{% elif node['name'] == 'app' %}
|
||||
ExecStart=/usr/bin/kopia snapshot create \
|
||||
{{ node['home_path'] }}/data
|
||||
{% endif %}
|
||||
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
KOPIA_PASSWORD={{ hostvars['console']['kopia']['user'][node['name']] }}
|
||||
KOPIA_PASSWORD={{ hostvars['console']['kopia']['users'][node['name']] }}
|
||||
KOPIA_CONFIG_PATH=/etc/kopia/repository.config
|
||||
KOPIA_CACHE_DIRECTORY=/var/cache/kopia
|
||||
KOPIA_LOG_DIR=/var/cache/kopia/logs
|
||||
|
||||
Reference in New Issue
Block a user