Skip to content
This repository was archived by the owner on May 13, 2025. It is now read-only.

DominiqueFuchs/docker-images-ansible

Repository files navigation

ARCHIVED – Superseded by https://github.com/DominiqueFuchs/DiD

Docker Images for Ansible Role and Molecule Testing

This repository provides Docker images pre-configured for testing Ansible roles, particularly with Molecule. The images are automatically built and published to Docker Hub via GitHub Actions.

These Docker images were initially created for and are used by my other repo ansible-grafana-compose. This Ansible role deploys a Grafana, Prometheus, Loki, and Alertmanager stack using Docker Compose, leveraging these images for its Molecule testing scenarios.

Available Linux Distributions

The following base images are available, each equipped with Ansible and other testing essentials:

Core Included Packages

Each image comes with:

  • Ansible: Latest version installed via pip.
  • Python 3 & pip: For Ansible and general scripting.
  • sudo: For privilege escalation.
  • Docker Engine (CE): For roles that might interact with Docker.
  • Docker Compose (plugin): For managing multi-container applications within tests.
  • systemd: Enabled in the base images to allow testing of service management.

Tags

  • latest: Each image currently tracks the latest available version of its base distribution and has a single latest tag.

Usage Example (with Molecule)

You can use these images in your molecule.yml file:

dependency:
  name: galaxy
driver:
  name: docker
platforms:
  - name: instance
    image: dfuchs/ubuntu-24.04-ansible:latest
    pre_build_image: true
    override_command: false
    privileged: true # For systemd, in conjunction with the cgroup mount
    volume_mounts:
      - "/sys/fs/cgroup:/sys/fs/cgroup:ro"
provisioner:
  name: ansible
verifier:
  name: ansible

About

Docker images for Ansible/Molecule role testing

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •