mirror of
https://github.com/Burnett01/rsync-deployments.git
synced 2026-09-27 16:56:11 +00:00
Remove .sh ext
This commit is contained in:
+3
-3
@@ -9,7 +9,7 @@ RUN rm -rf /var/cache/apk/*
|
|||||||
RUN mkdir ~/.ssh
|
RUN mkdir ~/.ssh
|
||||||
|
|
||||||
# Copy in our executables.
|
# Copy in our executables.
|
||||||
COPY agent-start.sh /bin/agent-start
|
COPY agent-start /bin/agent-start
|
||||||
COPY agent-add.sh /bin/agent-add
|
COPY agent-add /bin/agent-add
|
||||||
COPY agent-stop.sh /bin/agent-stop
|
COPY agent-stop /bin/agent-stop
|
||||||
RUN chmod +x /bin/agent-start /bin/agent-stop /bin/agent-add
|
RUN chmod +x /bin/agent-start /bin/agent-stop /bin/agent-add
|
||||||
|
|||||||
@@ -0,0 +1,5 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
# Start the SSH agent if it isn't already.
|
||||||
|
agent-start
|
||||||
|
ssh-add "$@"
|
||||||
@@ -0,0 +1,7 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
# Start the SSH agent if it isn't already.
|
||||||
|
if [ -z "$SSH_AGENT_PID" ]; then
|
||||||
|
eval $(ssh-agent) > /dev/null
|
||||||
|
echo "$SSH_AGENT_PID" > /tmp/ssh-agent-id
|
||||||
|
fi
|
||||||
+13
@@ -0,0 +1,13 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
if [ ! -z "$SSH_AGENT_PID" ]; then
|
||||||
|
ssh-agent -k
|
||||||
|
exit $?
|
||||||
|
elif [ -f "/tmp/ssh-agent-id" ]; then
|
||||||
|
SSH_AGENT_PID=$(cat /tmp/ssh-agent-id)
|
||||||
|
ssh-agent -k
|
||||||
|
exit $?
|
||||||
|
else
|
||||||
|
echo "SSH_AGENT_PID not set, /tmp/ssh-agent-id doesn't exist!" 1>&2
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
truncate -s 0 ~/.ssh/known_hosts
|
||||||
Reference in New Issue
Block a user