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.

Requirements & Dependencies

  • dnspython
  • dirsync
pip install dnspython
pip install dirsync

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 build a simple snakeoil certificate for a test environment.
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.

Modules

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

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 git@github.com: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!