https://github.com/boutetnico/ansible-role-docker
Install and configure Docker using Ansible.
https://github.com/boutetnico/ansible-role-docker
ansible debian docker-compose moby ubuntu
Last synced: 4 months ago
JSON representation
Install and configure Docker using Ansible.
- Host: GitHub
- URL: https://github.com/boutetnico/ansible-role-docker
- Owner: boutetnico
- License: mit
- Created: 2024-07-24T11:30:06.000Z (almost 2 years ago)
- Default Branch: master
- Last Pushed: 2026-02-04T16:35:47.000Z (5 months ago)
- Last Synced: 2026-02-05T04:05:19.532Z (5 months ago)
- Topics: ansible, debian, docker-compose, moby, ubuntu
- Language: Jinja
- Homepage:
- Size: 16.6 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
[](https://github.com/boutetnico/ansible-role-docker/actions?query=workflow%3A%22Test+ansible+role%22)
[](https://galaxy.ansible.com/boutetnico/docker)
ansible-role-docker
===================
This role installs Docker.
Requirements
------------
Ansible 2.15 or newer.
Supported Platforms
-------------------
- [Debian - 11 (Bullseye)](https://wiki.debian.org/DebianBullseye)
- [Debian - 12 (Bookworm)](https://wiki.debian.org/DebianBookworm)
- [Ubuntu - 22.04 (Jammy Jellyfish)](http://releases.ubuntu.com/22.04/)
- [Ubuntu - 24.04 (Noble Numbat)](http://releases.ubuntu.com/24.04/)
Role Variables
--------------
| Variable | Required | Default | Choices | Comments |
|---------------------------------|----------|----------------------|---------|----------------------------------------------------|
| docker_dependencies | true | | list | See `defaults/main.yml`. |
| docker_packages | true | | list | See `defaults/main.yml`. |
| docker_package_state | true | `present` | string | |
| docker_users | true | `[root]` | list | |
| docker_daemon_flags | true | `[-H unix://]` | list | |
| docker_daemon_json | true | `{}` | dict | |
| docker_cron_jobs | true | | list | See `defaults/main.yml`. |
Dependencies
------------
None
Example Playbook
----------------
- hosts: all
roles:
- role: ansible-role-docker
Testing
-------
## Debian
molecule --base-config molecule/shared/base.yml test --scenario-name debian-11
molecule --base-config molecule/shared/base.yml test --scenario-name debian-12
## Ubuntu
molecule --base-config molecule/shared/base.yml test --scenario-name ubuntu-2204
molecule --base-config molecule/shared/base.yml test --scenario-name ubuntu-2404
License
-------
MIT
Author Information
------------------
[@boutetnico](https://github.com/boutetnico)