This role:
- Import apt-key from docker project
- Install or update docker-engine
- Restart docker-engine
See also:
No special requirements.
(optional) docker_engine_version
specifies docker-engine version. You can also downgrade version, but be aware that docker doesn't like this and can fail to start or to work properly.
(optional) docker_engine_allow_non_root
specifies a list with users, which should be added to docker
group for non root access to docker. Users need to relogin or use newgrp docker
to activate group for current shell. Be aware of security risk, because it's same as to give a root access to users.
No dependencies.
Install role globally with:
ansible-galaxy install Bessonov.docker
or locally:
ansible-galaxy install --roles-path roles Bessonov.docker
Playbook:
- hosts: servers
roles:
- Bessonov.docker
or with parameters:
- hosts: servers
roles:
- role: Bessonov.docker
# optional set docker version
docker_engine_version: 17.06.2
The MIT License (MIT)
Copyright (c) 2016, Anton Bessonov
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.