20 lines
385 B
Python
20 lines
385 B
Python
from pyinfra import host
|
|
from pyinfra.operations import server, files, systemd, apt
|
|
|
|
SUDO = True
|
|
|
|
apt.packages(
|
|
name='Install packages',
|
|
packages=['borgbackup', 'borgmatic'],
|
|
update=True,
|
|
)
|
|
|
|
files.template(
|
|
name='Push borgmatic config',
|
|
src='templates/borgmatic.yaml.j2',
|
|
dest='/etc/borgmatic/config.yaml',
|
|
mode='600',
|
|
user='root',
|
|
group='root',
|
|
)
|
|
|