Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/xenion1987/ansible-playground
A DevContainer environment for playing around with ansible.
https://github.com/xenion1987/ansible-playground
ansible devcontainer docker docker-compose vscode
Last synced: about 2 months ago
JSON representation
A DevContainer environment for playing around with ansible.
- Host: GitHub
- URL: https://github.com/xenion1987/ansible-playground
- Owner: Xenion1987
- License: mit
- Created: 2023-01-18T22:35:08.000Z (almost 2 years ago)
- Default Branch: main
- Last Pushed: 2024-09-16T15:30:04.000Z (4 months ago)
- Last Synced: 2024-09-16T17:47:08.186Z (4 months ago)
- Topics: ansible, devcontainer, docker, docker-compose, vscode
- Language: Shell
- Homepage:
- Size: 103 KB
- Stars: 3
- Watchers: 0
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# ansible-playground
[![pre-commit](https://img.shields.io/badge/pre--commit-enabled-brightgreen?logo=pre-commit)](https://github.com/pre-commit/pre-commit) ![pre-commit](https://github.com/Xenion1987/ansible-playground/actions/workflows/pre-commit.yml/badge.svg) ![ansible-tests](https://github.com/Xenion1987/ansible-playground/actions/workflows/ansible-tests.yml/badge.svg)
## Installing
### Install requirements
1. [vscode](https://code.visualstudio.com/Download)
1. [docker compose](https://docs.docker.com/compose/install/)
1. vscode plugins
1. [Dev Containers](https://marketplace.visualstudio.com/items?itemName=ms-vscode-remote.remote-containers)### Clone this repository
```sh
git clone https://github.com/Xenion1987/ansible-playground.git
```## Start the playground
### Start the ansible control container
Open the repository in vscode. Vscode should give you a hint, that it has detected a DevContainer config and asks you to reopen it in DevContainer. Accept to initialize and start the environment.
By default, this playground builds and starts 2 out of 4 clients (`debian-12` and `almalinux-8`). If you want to build and start all 4 clients, you have to uncomment the `ubuntu` and `suse` client in both [docker-compose.yml](.devcontainer/docker-compose.yml) and [inventory.yml](inventory/inventory.yml) files.
## Contributing
This repository is [`pre-commit`](https://pre-commit.com/) enabled. Before commiting, all changes will be checked by pre-commit-hooks defined in [.pre-commit-config.yaml](./.pre-commit-config.yaml). [`pre-commit`](https://pre-commit.com/) will be installed inside the devcontainer.
Before doing a `git commit`, you should run `pre-commit run --all-files` to run checks and fix mentioned warnings/errors.