diff --git a/ansible_playbooks/vars/nomad_vars.sample.yml b/ansible_playbooks/vars/nomad_vars.sample.yml index bc334a9..44fabce 100644 --- a/ansible_playbooks/vars/nomad_vars.sample.yml +++ b/ansible_playbooks/vars/nomad_vars.sample.yml @@ -24,21 +24,29 @@ nomad/jobs/backup: nas_ftp_host: VALUE nas_ftp_pass: VALUE nas_ftp_user: VALUE + nas_minio_access_key_id: VALUE + nas_minio_secret_access_key: VALUE nomad/jobs/backup-oneoff-n1: backup_passphrase: VALUE nas_ftp_host: VALUE nas_ftp_pass: VALUE nas_ftp_user: VALUE + nas_minio_access_key_id: VALUE + nas_minio_secret_access_key: VALUE nomad/jobs/backup-oneoff-n2: backup_passphrase: VALUE nas_ftp_host: VALUE nas_ftp_pass: VALUE nas_ftp_user: VALUE + nas_minio_access_key_id: VALUE + nas_minio_secret_access_key: VALUE nomad/jobs/backup-oneoff-pi4: backup_passphrase: VALUE nas_ftp_host: VALUE nas_ftp_pass: VALUE nas_ftp_user: VALUE + nas_minio_access_key_id: VALUE + nas_minio_secret_access_key: VALUE nomad/jobs/bazarr: db_name: VALUE db_pass: VALUE diff --git a/backups/backup.nomad b/backups/backup.nomad index 2ffb178..e1fa858 100644 --- a/backups/backup.nomad +++ b/backups/backup.nomad @@ -69,7 +69,7 @@ job "backup%{ if batch_node != null }-oneoff-${batch_node}%{ endif }" { } config { - image = "iamthefij/resticscheduler:0.2.0" + image = "iamthefij/resticscheduler:0.3.0" ports = ["metrics"] args = [ %{ if batch_node != null ~} @@ -113,6 +113,8 @@ RCLONE_FTP_USER={{ .nas_ftp_user }} RCLONE_FTP_PASS={{ .nas_ftp_pass.Value | toJSON }} RCLONE_FTP_EXPLICIT_TLS=true RCLONE_FTP_NO_CHECK_CERTIFICATE=true +AWS_ACCESS_KEY_ID={{ .nas_minio_access_key_id }} +AWS_SECRET_ACCESS_KEY={{ .nas_minio_secret_access_key }} {{ end -}} EOF destination = "secrets/db.env" diff --git a/backups/jobs/authelia.hcl b/backups/jobs/authelia.hcl index ad4647c..9e73cc4 100644 --- a/backups/jobs/authelia.hcl +++ b/backups/jobs/authelia.hcl @@ -2,8 +2,12 @@ job "authelia" { schedule = "@daily" config { - repo = "rclone::ftp,env_auth:/nomad/authelia" + repo = "s3://backups-minio.agnosticfront.thefij:8443/nomad/authelia" passphrase = env("BACKUP_PASSPHRASE") + + options { + InsecureTls = true + } } task "Create local authelia dir" { diff --git a/backups/jobs/grafana.hcl b/backups/jobs/grafana.hcl index 2c69813..0bf68ae 100644 --- a/backups/jobs/grafana.hcl +++ b/backups/jobs/grafana.hcl @@ -2,8 +2,12 @@ job "grafana" { schedule = "@daily" config { - repo = "rclone::ftp,env_auth:/nomad/grafana" + repo = "s3://backups-minio.agnosticfront.thefij:8443/nomad/grafana" passphrase = env("BACKUP_PASSPHRASE") + + options { + InsecureTls = true + } } task "Create local grafana dir" { diff --git a/backups/jobs/lidarr.hcl b/backups/jobs/lidarr.hcl index a444b53..a07025d 100644 --- a/backups/jobs/lidarr.hcl +++ b/backups/jobs/lidarr.hcl @@ -2,8 +2,12 @@ job "lidarr" { schedule = "@daily" config { - repo = "rclone::ftp,env_auth:/nomad/lidarr" + repo = "s3://backups-minio.agnosticfront.thefij:8443/nomad/lidarr" passphrase = env("BACKUP_PASSPHRASE") + + options { + InsecureTls = true + } } task "Backup main database" { diff --git a/backups/jobs/lldap.hcl b/backups/jobs/lldap.hcl index 1cb6c84..df54526 100644 --- a/backups/jobs/lldap.hcl +++ b/backups/jobs/lldap.hcl @@ -2,8 +2,12 @@ job "lldap" { schedule = "@daily" config { - repo = "rclone::ftp,env_auth:/nomad/lldap" + repo = "s3://backups-minio.agnosticfront.thefij:8443/nomad/lldap" passphrase = env("BACKUP_PASSPHRASE") + + options { + InsecureTls = true + } } task "Create local backup dir" { diff --git a/backups/jobs/nzbget.hcl b/backups/jobs/nzbget.hcl index bb16e02..97bd87e 100644 --- a/backups/jobs/nzbget.hcl +++ b/backups/jobs/nzbget.hcl @@ -2,8 +2,12 @@ job "nzbget" { schedule = "@daily" config { - repo = "rclone::ftp,env_auth:/nomad/nzbget" + repo = "s3://backups-minio.agnosticfront.thefij:8443/nomad/nzbget" passphrase = env("BACKUP_PASSPHRASE") + + options { + InsecureTls = true + } } backup { diff --git a/backups/jobs/photoprism.hcl b/backups/jobs/photoprism.hcl index 713dc65..0180431 100644 --- a/backups/jobs/photoprism.hcl +++ b/backups/jobs/photoprism.hcl @@ -2,8 +2,12 @@ job "photoprism" { schedule = "10 * * * *" config { - repo = "rclone::ftp,env_auth:/nomad/photoprism" + repo = "s3://backups-minio.agnosticfront.thefij:8443/nomad/photoprism" passphrase = env("BACKUP_PASSPHRASE") + + options { + InsecureTls = true + } } task "Create local photoprism dir" { diff --git a/backups/jobs/sabnzbd.hcl b/backups/jobs/sabnzbd.hcl index 6533bd9..cb9694a 100644 --- a/backups/jobs/sabnzbd.hcl +++ b/backups/jobs/sabnzbd.hcl @@ -2,8 +2,12 @@ job "sabnzbd" { schedule = "@daily" config { - repo = "rclone::ftp,env_auth:/nomad/sabnzbd" + repo = "s3://backups-minio.agnosticfront.thefij:8443/nomad/sabnzbd" passphrase = env("BACKUP_PASSPHRASE") + + options { + InsecureTls = true + } } backup { diff --git a/backups/jobs/sonarr.hcl b/backups/jobs/sonarr.hcl index a08da53..11fff27 100644 --- a/backups/jobs/sonarr.hcl +++ b/backups/jobs/sonarr.hcl @@ -2,8 +2,12 @@ job "sonarr" { schedule = "@daily" config { - repo = "rclone::ftp,env_auth:/nomad/sonarr" + repo = "s3://backups-minio.agnosticfront.thefij:8443/nomad/sonarr" passphrase = env("BACKUP_PASSPHRASE") + + options { + InsecureTls = true + } } task "Backup main database" {