Made improvements proposed on pulls/6

aws-to-backblaze
Illia Chub 2021-12-17 07:13:34 +02:00
parent 24f2e83cf1
commit 64d12982be
No known key found for this signature in database
GPG Key ID: 5D3581534C02467A
2 changed files with 5 additions and 4 deletions

View File

@ -6,19 +6,19 @@ in
systemd = {
services = {
"restic-scheduled-backup" = {
"restic-backup" = {
description = "Userdata restic backup trigger";
serviceConfig = {
Type = "simple";
User = "restic";
ExecStart = "${pkgs.restic}/bin/restic -r rclone:backblaze:${cfg.backblaze.bucket}:/sfbackup --verbose --json backup /var";
ExecStart = "${pkgs.restic}/bin/restic -o rclone.args=serve restic --stdio -r rclone:backblaze:${cfg.backblaze.bucket}:/sfbackup --verbose --json backup /var";
};
};
};
timers = {
"restic-scheduled-backup" = {
wantedBy = [ "timers.target" ];
partOf = [ "restic-scheduled-backup.service" ];
partOf = [ "restic-backup.service" ];
timerConfig = {
OnCalendar = "daily";
};

View File

@ -1,4 +1,4 @@
{ pkgs, config, ... }:
{ pkgs, config, lib, ... }:
let
domain = config.services.userdata.domain;
in
@ -11,6 +11,7 @@ in
recommendedProxySettings = true;
recommendedTlsSettings = true;
clientMaxBodySize = "1024m";
sslProtocols = lib.mkForce "TLSv1.2 TLSv1.3";
virtualHosts = {
"${domain}" = {