A simple alternative to Chef and Puppet to bootstrap *nix machines.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

19 lines
520 B

#! /bin/bash
image_name=devenv-$(whoami)
container_name=$image_name-run
if ! docker inspect "$container_name" > /dev/null ; then
echo "start new"
docker run -it \
--hostname="$(hostname)-docker" \
--env SSH_CLIENT=true \
--env TERM_PROGRAM="$TERM_PROGRAM" \
--env ITERM_PROFILE="$ITERM_PROFILE" \
--volume /:/host \
--name "$container_name" \
"$image_name" fish
else
echo "start existing"
docker start --attach --interactive "$container_name"
fi