From: Ian Kelling Date: Mon, 29 Jul 2019 17:03:07 +0000 (-0400) Subject: fix default mounts for o when pulling X-Git-Url: https://iankelling.org/git/?p=distro-setup;a=commitdiff_plain;h=2fab67243e4b580b90b936acd87c4058dbf7e6e9;hp=f31ab4e29572ea4948f292bee814bc23061e992a fix default mounts for o when pulling --- diff --git a/btrbk-run b/btrbk-run index 3ec2221..f6570a1 100644 --- a/btrbk-run +++ b/btrbk-run @@ -238,8 +238,17 @@ else # ;; *) prospective_mps=(/a /q) - if [[ $HOSTNAME == "$MAIL_HOST" ]]; then - prospective_mps+=(/o) + if [[ $source ]]; then + source_state="$(ssh $source cat /a/bin/bash_unpublished/source-state)" + eval "$source_state" + source_host="$(ssh $source cat /etc/hostname)" + if [[ $source_host == "$MAIL_HOST" ]]; then + prospective_mps+=(/o) + fi + else + if [[ $HOSTNAME == "$MAIL_HOST" ]]; then + prospective_mps+=(/o) + fi fi ;; esac