From ceb78c8d3a991326ae2509f36364af3a48fb36f7 Mon Sep 17 00:00:00 2001 From: Ian Kelling Date: Wed, 13 Oct 2021 17:05:56 -0400 Subject: [PATCH] make default port simpler --- kaya | 3 +++ kaya.conf | 6 ++++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/kaya b/kaya index b0b9b55..80c3ddf 100755 --- a/kaya +++ b/kaya @@ -131,6 +131,9 @@ function main() { # shellcheck source=/etc/kaya.conf source "${global_conf}" + if [[ -z $local_port ]]; then + local_port=8000 + fi backup_dir="${backuproot}/${hostname}" password_file="${backup_dir}/repo-password-keep" diff --git a/kaya.conf b/kaya.conf index c5ac89a..6944486 100644 --- a/kaya.conf +++ b/kaya.conf @@ -1,10 +1,12 @@ - +#!/bin/bash # # Config file for Kaya, the restic backup wrapper # +# This will be sourced by bash backuproot=/srv/backups/kaya -local_port=8000 # use 'rest-server --listen ...' +# set if using non-default port as in 'rest-server --listen :PORT' +# local_port=8000 remote_port=8777 # some aribtrary port -- 2.25.1