{"id":14984551,"url":"https://github.com/nduytg/ansible_roles","last_synced_at":"2025-10-17T17:04:14.959Z","repository":{"id":63769146,"uuid":"211607587","full_name":"nduytg/ansible_roles","owner":"nduytg","description":" A collection of my personal ansible roles","archived":false,"fork":false,"pushed_at":"2020-03-30T08:55:45.000Z","size":71,"stargazers_count":22,"open_issues_count":1,"forks_count":17,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-24T18:49:35.904Z","etag":null,"topics":["ansible","ansible-roles","devops","playbook","roles","system"],"latest_commit_sha":null,"homepage":"https://cloudcraft.info/","language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/nduytg.png","metadata":{"files":{"readme":"Readme.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2019-09-29T05:20:56.000Z","updated_at":"2025-02-23T17:01:49.000Z","dependencies_parsed_at":"2022-11-25T16:50:54.670Z","dependency_job_id":null,"html_url":"https://github.com/nduytg/ansible_roles","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nduytg%2Fansible_roles","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nduytg%2Fansible_roles/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nduytg%2Fansible_roles/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nduytg%2Fansible_roles/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nduytg","download_url":"https://codeload.github.com/nduytg/ansible_roles/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248298789,"owners_count":21080403,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ansible","ansible-roles","devops","playbook","roles","system"],"created_at":"2024-09-24T14:09:15.473Z","updated_at":"2025-10-17T17:04:14.955Z","avatar_url":"https://github.com/nduytg.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Personal Ansible Roles\n\nThis repository contains a collection of reusable roles that I use to bootstrap monitoring, observability, and supporting services in my lab environments. The content has been refreshed to follow the [Ansible 2.10+ best practices](https://docs.ansible.com/ansible/latest/user_guide/playbooks_best_practices.html), including modern task syntax, the new `group_vars` layout, and explicit use of the `ansible.builtin` collection.\n\n## Repository Layout\n\n```text\nansible_roles/\n├── group_vars/          # Group specific variable files (e.g. staging/)\n├── hosts                # Example inventory file\n├── roles/               # Individual roles for services such as Prometheus, Nginx, etc.\n├── target.yml           # Example playbook that wires the roles together\n└── Readme.md            # This document\n```\n\nEach role follows the standard Ansible role structure (`defaults`, `tasks`, `templates`, and so on). The `target.yml` playbook now declares the `ansible.builtin` collection and uses modern task syntax so it is ready to run with Ansible 2.10 or newer.\n\n## Getting Started\n\n1. **Install dependencies**\n   * Python 3.9+\n   * Ansible 2.10 or newer (`pip install ansible`)\n\n2. **Inventory**\n   * Update the `hosts` file with your infrastructure details.\n   * Place per-environment variables in `group_vars/\u003cgroup\u003e/`.\n\n3. **Select roles**\n   * Enable the roles you want in `target.yml` by uncommenting them under the `roles` section.\n\n4. **Run the playbook**\n   ```bash\n   ansible-playbook -i hosts target.yml\n   ```\n\n## Recommended Workflow\n\n| Step | Command | Purpose |\n| --- | --- | --- |\n| 1 | `ansible-playbook --syntax-check target.yml` | Validate the playbook parses correctly. |\n| 2 | `ansible-playbook --check -i hosts target.yml` | Perform a dry run without applying changes. |\n| 3 | `ansible-playbook -i hosts target.yml` | Apply the roles to the selected hosts. |\n\n## Available Roles\n\nThe repository currently includes roles for:\n\n- **Prometheus Stack**: Prometheus, Alertmanager, Pushgateway, Thanos (query \u0026 sidecar), and Elasticsearch exporters (VM and Docker).\n- **Proxy / Load Balancing**: Nginx with monitoring extensions.\n- **High Availability**: Keepalived.\n- **Service Discovery**: Consul (stand-alone or clustered).\n- **Elastic Stack**: Elasticsearch, Logstash, Kibana.\n- **Miscellaneous**: MySQL, Docker, VSFTPD, and more.\n\nRefer to each role's `README.md` (where provided) for configuration specifics.\n\n## Contributing Improvements\n\n* Use `ansible-lint` or `yamllint` when modifying roles to maintain consistency.\n* Ensure new tasks use `loop`/`include_tasks` and Fully Qualified Collection Names (FQCNs) where appropriate.\n* Document any new variables or dependencies in the relevant role README.\n\n## Supported Platforms\n\n- ✅ Ubuntu (primary test target)\n- ⚠️ CentOS / Debian (not fully validated yet, contributions welcome!)\n\nFeel free to open issues or pull requests with suggestions, fixes, or additional roles.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnduytg%2Fansible_roles","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnduytg%2Fansible_roles","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnduytg%2Fansible_roles/lists"}