Docker utilities to try out recipes and the commands

This commit is contained in:
Bruno Tavares
2014-02-20 12:49:57 -03:00
parent ce2ac5e848
commit 749fbae08c
3 changed files with 47 additions and 0 deletions

7
lib/kickstart-docker-ssh Executable file
View File

@ -0,0 +1,7 @@
#!/bin/bash -e
runnig_sshd=$(docker ps -q moul/sshd)
[ -z "$runnig_sshd" ] && echo "Docker container not created. Run \`kickstart docker-create\` to get one" && exit 1
port=`docker port $runnig_sshd 22 | cut -f 2 -d :`
exec ssh -p $port root@localhost