Skip to content

Instantly share code, notes, and snippets.

Created July 20, 2014 21:09
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
What would you like to do?
Ansible playbook to setup Docker 1.1.1 in Vagrant
- hosts: all
remote_user: vagrant
- name: install apt signing key
apt_key: url= state=present
- name: add repository
copy: src=docker.list dest=/etc/apt/sources.list.d/docker.list
- name: install package
apt: pkg=lxc-docker=1.1.1 update_cache=yes state=present
- name: ensure docker is running
service: name=docker state=started enabled=true
- name: add vagrant user to docker group
user: name=vagrant groups=docker append=yes
Copy link

Create a docker.list:

deb docker main

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment