Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

93 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Ansible Collections

Stars Top Language License Issues PRs Repo Size

This repository contains ready-to-use Ansible collections for configuring a server with a specific runtime stack. Each collection installs and configures everything needed behind an Nginx reverse proxy — so you can set up a fully functioning server with a single command.

What is Ansible?

Ansible is an open-source automation tool that lets you configure servers, run applications, and manage infrastructure — all without installing any agent on the target machine. You write tasks in simple YAML files called playbooks, and Ansible connects via SSH to execute them.

Instead of manually running commands on each server, you define once what your server should look like and let Ansible do the rest.

What is Ansible Galaxy?

Ansible Galaxy is the official hub for sharing Ansible collections and roles. It works like a package manager — you can download pre-built automation content published by the community or by vendors. This repo's collections are published on Galaxy, so you can install them directly with ansible-galaxy collection install.

Use Cases

These collections let you turn a blank VM or VPS into a fully configured server for your preferred runtime — whether that's for a web app, API, or backend service. Just pick the stack you need, run the playbook, and your server is ready to go. They're also great for learning how Ansible automates real-world server setup.

How It Works

graph LR
    A[Your Machine] -->|SSH| B[Target Server]
    A --> C[Ansible Playbook]
    C --> D[Collection Roles]
    D --> E[Install & Configure]
    E --> F[Nginx + App Stack Ready]
Loading

Each collection contains a playbook that calls multiple roles to install and configure everything needed for a specific tech stack.

Available Collections

Collection Stack Link
node_app_server_bootstrapNode.js + Nginx + PM2galaxy
dotnet_app_server_bootstrap.NET/C# + Nginxgalaxy
php_app_server_bootstrapPHP + PHP-FPM + Nginxgalaxy
python_app_server_bootstrapPython + Gunicorn + Nginxgalaxy
golang_app_server_bootstrapGo + Nginxgalaxy
docker_bootstrapDocker Engine + Docker Composegalaxy
podman_bootstrapPodman + Podman Composegalaxy
kubernetes_helm_bootstrapkubectl + Helmgalaxy
observability_bootstrapPrometheus + Grafana + Loki + Promtail + Tempo + OpenTelemetry + Nginxgalaxy

CI/CD

Each collection has its own GitHub Actions workflow that runs on pushes and pull requests to main:

Collection Status
dotnet_app_server_bootstrap dotnet_app_server_bootstrap
golang_app_server_bootstrap golang_app_server_bootstrap
node_app_server_bootstrap node_app_server_bootstrap
php_app_server_bootstrap php_app_server_bootstrap
python_app_server_bootstrap python_app_server_bootstrap
docker_bootstrap docker_bootstrap
podman_bootstrap podman_bootstrap
kubernetes_helm_bootstrap kubernetes_helm_bootstrap
observability_bootstrap observability_bootstrap

Each workflow runs two jobs:

  • syntax-check — Installs Ansible, builds the collection, and validates both install.yml and uninstall.yml with --syntax-check (runs on every push/PR).
  • deploy — Triggered manually via workflow_dispatch. Takes host and ansible_user as inputs; the SSH private key is read from the SSH_PRIVATE_KEY repository secret for security.

Quick Start

  1. Create an inventory file (inventory.ini) with your server IP:
    [webserver]
    192.168.1.10 ansible_user=root
  2. Navigate to a collection folder, e.g. cd node_app_server_bootstrap
  3. Run a playbook:
    ansible-playbook playbooks/<playbook>.yml -i inventory.ini

See CONTRIBUTING.md for detailed setup and publishing instructions.

Running Ansible from WSL / Docker / Podman

You don't need a Linux machine to run these playbooks — any environment with Ansible installed can SSH into a remote server.

WSL (Windows Subsystem for Linux)

# Install Ansible inside your WSL distro (Ubuntu/Debian)
sudo apt update && sudo apt install -y ansible

# Clone the repo
git clone https://github.com/marcuwynu23/ansible-collections.git
cd ansible-collections

# Run a playbook
ansible-playbook node_app_server_bootstrap/playbooks/<playbook>.yml -i inventory.ini

Docker

# Run Ansible from an Alpine container with SSH access
docker run --rm -it -v ${PWD}:/workspace -w /workspace alpine:latest sh -c \
  "apk add --no-cache ansible openssh-client && sh"

# Inside the container, run:
# ansible-playbook node_app_server_bootstrap/playbooks/<playbook>.yml -i inventory.ini

Podman

# Same as Docker, but with Podman
podman run --rm -it -v ${PWD}:/workspace:Z -w /workspace alpine:latest sh -c \
  "apk add --no-cache ansible openssh-client && sh"

Guides

About

This repository contains Ansible collections for various automation tasks.

Topics

Resources

Code of conduct

Contributing

Security policy

Stars

1 star

Watchers

0 watching

Forks

Used by

Contributors

Languages