Skip to content

Instantly share code, notes, and snippets.

@fightbulc
Created July 26, 2014 16:01
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save fightbulc/3e8476b831904885ed3d to your computer and use it in GitHub Desktop.
Save fightbulc/3e8476b831904885ed3d to your computer and use it in GitHub Desktop.
#
# redis
#
sudo docker run -d -v /home/data/redis:/data --name web_redis dockerfile/redis redis-server /etc/redis/redis.conf
sudo docker run -it --rm --link web_redis:redis dockerfile/redis bash -c 'redis-cli -h $REDIS_PORT_6379_TCP_ADDR'
#
# mysql
#
sudo docker run -d -v /home/data/mysql:/var/lib/mysql -p 3306:3306 -e MYSQL_PASS="rootuser" --name web_mysql tutum/mysql
#
# web
#
sudo docker run -i -t -v $SSH_AUTH_SOCK:/ssh-agent -e SSH_AUTH_SOCK=/ssh-agent --dns 127.0.0.1 -v /home/www:/home/www -v /home/vhosts:/home/vhosts --link=web_mysql:mysql --link=web_redis:redis -p 80:80 --name web fightbulc/nginx-php55 /bin/bash -l
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment