Skip to content

bodsch/ansible-collection-core

Repository files navigation

Ansible Collection - bodsch.core

Documentation for the collection.

This collection aims to offer an set of small ansible modules or helper functions.

supported Operating systems

Tested on

  • ArchLinux
  • Debian based
    • Debian 10 / 11 / 12
    • Ubuntu 20.04 / 22.04

RedHat-based systems are no longer officially supported! May work, but does not have to.

Requirements & Dependencies

  • dnspython
  • dirsync
  • netaddr
pip install dnspython
pip install dirsync
pip install netaddr

Included content

Roles

Role Build State Description
bodsch.core.pacman GitHub Workflow Status Ansible role to configure pacman.
bodsch.core.fail2ban GitHub Workflow Status Installs and configure fail2ban
bodsch.core.snakeoil GitHub Workflow Status moved to (https://github.com/bodsch/ansible-collection-certs/tree/main/roles/snakeoil)[bodsch.certs]
bodsch.core.syslog_ng GitHub Workflow Status Installs and configures a classic syslog-ng service for processing log files away from journald.
bodsch.core.logrotate GitHub Workflow Status Installs logrotate and provides an easy way to setup additional logrotate scripts
bodsch.core.mount GitHub Workflow Status Manage generic mountpoints
bodsch.core.openvpn GitHub Workflow Status Ansible role to install and configure openvpn server.
bodsch.core.sysctl GitHub Workflow Status Ansible role to configure sysctl.
bodsch.core.sshd GitHub Workflow Status Ansible role to configure sshd.

Modules

Name Description
bodsch.core.remove_ansible_backups Remove older backup files created by ansible
bodsch.core.package_version Attempts to determine the version of a package to be installed or already installed.
bodsch.core.aur Installing packages for ArchLinux with aur
bodsch.core.journalctl Query the systemd journal with a very limited number of possible parameters
bodsch.core.facts Write ansible facts
bodsch.core.sync_directory Syncronises directories similar to rsync
bodsch.core.check_mode Replacement for ansible_check_mode.
bodsch.core.facts Creates a facts file for ansible.

Installing this collection

You can install the memsource collection with the Ansible Galaxy CLI:

#> ansible-galaxy collection install bodsch.core

To install directly from GitHub:

#> ansible-galaxy collection install [email protected]:bodsch/ansible-collection-core.git

You can also include it in a requirements.yml file and install it with ansible-galaxy collection install -r requirements.yml, using the format:

---
collections:
  - name: bodsch.core

The python module dependencies are not installed by ansible-galaxy. They can be manually installed using pip:

pip install -r requirements.txt

Using this collection

You can either call modules by their Fully Qualified Collection Name (FQCN), such as bodsch.core.remove_ansible_backups, or you can call modules by their short name if you list the bodsch.core collection in the playbook's collections keyword:

---
- name: remove older ansible backup files
  bodsch.core.remove_ansible_backups:
    path: /etc
    holds: 4

Contribution

Please read Contribution

Development, Branches (Git Tags)

The master Branch is my Working Horse includes the "latest, hot shit" and can be complete broken!

If you want to use something stable, please use a Tagged Version!

Author

  • Bodo Schulz

License

Apache

FREE SOFTWARE, HELL YEAH!