Skip to content

Commit

Permalink
Add docker-ssh-add-key script
Browse files Browse the repository at this point in the history
  • Loading branch information
yongjhih committed Mar 22, 2016
1 parent 92a4b37 commit b890079
Showing 1 changed file with 24 additions and 0 deletions.
24 changes: 24 additions & 0 deletions scripts/docker-ssh-add-key
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
#!/usr/bin/env bash

if [ ! "$1" ]; then
echo "Usage: $0 <name-of-parse-server-container> <ssh-key-file>..."
exit 1
fi

DOCKER_PARSE_SERVER_NAME="$1"
shift

if [ ! "$1" ]; then
echo "Usage: $0 <name-of-parse-server-container> <ssh-key-file>..."
exit 1
fi

while [ "$1" ]; do
if [ ! -f "$1" ]; then
shift
continue
fi

docker exec -i parse-server ssh-add-key < "$1"
shift
done

0 comments on commit b890079

Please sign in to comment.