git.lirion.de

Of git, get, and gud

aboutsummaryrefslogtreecommitdiffstats
path: root/.bash/vars.bash
diff options
context:
space:
mode:
authormail_redacted_for_web 2022-03-23 14:04:33 +0100
committermail_redacted_for_web 2022-03-23 14:04:33 +0100
commitb03248a3b3cb918ad1b25cf978bfa78f9c09c8d0 (patch)
tree4ec4b64984b74b280fe0d04d8fb41bcd9c5b83f0 /.bash/vars.bash
parent1d606042b070a7f0f205821c72c8accde4087785 (diff)
downloaddotfiles-b03248a3b3cb918ad1b25cf978bfa78f9c09c8d0.tar.bz2
$SSH_AUTH_SOCK only on the admin stations
Diffstat (limited to '.bash/vars.bash')
-rw-r--r--.bash/vars.bash12
1 files changed, 10 insertions, 2 deletions
diff --git a/.bash/vars.bash b/.bash/vars.bash
index cb124be..088e1e9 100644
--- a/.bash/vars.bash
+++ b/.bash/vars.bash
@@ -9,8 +9,6 @@ export SCRSHDIR="${HOME}/Pictures"
export SSHHOME="${HOME}/.ssh"
# 1. key files, array:
SSHKEYS=( "${SSHHOME}/id_ed25519" "${SSHHOME}/id_rsa" )
-# 2. SSH environment file
-export SSHENVFILE="${HOME}/.ssh/sshenv"
# 3. Hosts on which ssh-agent should run, FQDN. Array.
# Typically, "hosts" will equal your workstations. See ssh_config(5) (esp. ForwardAgent)
# Interpreted by fgrep / grep -F.
@@ -81,3 +79,13 @@ export LIBVIRT_DEFAULT_URI="qemu:///system"
if [ -z "$debian_chroot" ] && [ -r /etc/debian_chroot ]; then
debian_chroot=$(cat /etc/debian_chroot)
fi
+
+if [ -r "vars.bash.local" ];then
+ source vars.bash.local
+fi
+# SSH environment file
+#!/usr/bin/env bash
+# vim:syntax=sh
+if echo "${SSHAGH[@]}" | fgrep --word-regexp "$(hostname -f)" > /dev/null;then
+ export SSHENVFILE="${HOME}/.ssh/sshenv"
+fi