diff options
author | Dimitri John Ledkov <xnox@ubuntu.com> | 2017-08-21 12:48:31 +0100 |
---|---|---|
committer | Colin Watson <cjwatson@debian.org> | 2017-08-22 16:17:24 +0100 |
commit | b4fc0d329c03de1c38dc3f908a10f7239c32a05c (patch) | |
tree | 9187928083f825c0cdc32a2bfc0fd369a600ea38 /debian/agent-launch | |
parent | 0aa09c9ec85924a27d864ccf26bc1fed79b41946 (diff) |
Drop upstart system and user jobs.
Diffstat (limited to 'debian/agent-launch')
-rwxr-xr-x | debian/agent-launch | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/debian/agent-launch b/debian/agent-launch index 79c75a50b..f3cbfaef8 100755 --- a/debian/agent-launch +++ b/debian/agent-launch | |||
@@ -1,5 +1,5 @@ | |||
1 | #!/bin/sh | 1 | #!/bin/sh |
2 | # helper script for launching ssh-agent, used by systemd unit and upstart job | 2 | # helper script for launching ssh-agent, used by systemd unit |
3 | set -e | 3 | set -e |
4 | 4 | ||
5 | if [ ! -d "$XDG_RUNTIME_DIR" ]; then | 5 | if [ ! -d "$XDG_RUNTIME_DIR" ]; then |
@@ -11,17 +11,11 @@ if [ "$1" = start ]; then | |||
11 | if [ -z "$SSH_AUTH_SOCK" ] && grep -s -q '^use-ssh-agent$' /etc/X11/Xsession.options; then | 11 | if [ -z "$SSH_AUTH_SOCK" ] && grep -s -q '^use-ssh-agent$' /etc/X11/Xsession.options; then |
12 | S="$XDG_RUNTIME_DIR/openssh_agent" | 12 | S="$XDG_RUNTIME_DIR/openssh_agent" |
13 | dbus-update-activation-environment --verbose --systemd SSH_AUTH_SOCK=$S SSH_AGENT_LAUNCHER=openssh | 13 | dbus-update-activation-environment --verbose --systemd SSH_AUTH_SOCK=$S SSH_AGENT_LAUNCHER=openssh |
14 | if [ "$UPSTART_SESSION" ] && type initctl >/dev/null 2>&1; then | ||
15 | initctl set-env --global SSH_AUTH_SOCK=$S | ||
16 | fi | ||
17 | exec ssh-agent -D -a $S | 14 | exec ssh-agent -D -a $S |
18 | fi | 15 | fi |
19 | elif [ "$1" = stop ]; then | 16 | elif [ "$1" = stop ]; then |
20 | if [ "$SSH_AGENT_LAUNCHER" = openssh ]; then | 17 | if [ "$SSH_AGENT_LAUNCHER" = openssh ]; then |
21 | dbus-update-activation-environment --systemd SSH_AUTH_SOCK= | 18 | dbus-update-activation-environment --systemd SSH_AUTH_SOCK= |
22 | if [ "$UPSTART_SESSION" ] && type initctl >/dev/null 2>&1; then | ||
23 | initctl unset-env --global SSH_AUTH_SOCK | ||
24 | fi | ||
25 | fi | 19 | fi |
26 | else | 20 | else |
27 | echo "Unknown command $1" >&2 | 21 | echo "Unknown command $1" >&2 |