Update README.md

This commit is contained in:
Glenn Y. Rolland 2024-07-12 13:10:08 +00:00
parent 6373e1f70d
commit a21d9b3d98

View file

@ -1,38 +1,60 @@
Role Name
=========
A brief description of the role goes here.
# Ansible Role: rsnapshot
Requirements
------------
[![CI](https://github.com/glenux/ansible-role-rsnapshot/workflows/CI/badge.svg?event=push)](https://github.com/glenux/ansible-role-rsnapshot/actions?query=workflow%3ACI)
Any pre-requisites that may not be covered by Ansible itself or the role should be mentioned here. For instance, if the role uses the EC2 module, it may be a good idea to mention in this section that the boto package is required.
This role installs and configures rsnapshot on Debian-based systems.
Role Variables
--------------
## Requirements
A description of the settable variables for this role should go here, including any variables that are in defaults/main.yml, vars/main.yml, and any variables that can/should be set via parameters to the role. Any variables that are read from other roles and/or the global scope (ie. hostvars, group vars, etc.) should be mentioned here as well.
This role has been tested on Debian 11 (Bullseye) and should work on other Debian-based systems.
Dependencies
------------
## Role Variables
A list of other roles hosted on Galaxy should go here, plus any details in regards to parameters that may need to be set for other roles, or variables that are used from other roles.
All variables are defined with their default values in `defaults/main.yml`. An exhaustive description of the variables is available in `criteria/variables.json`. Here are a few notable variables:
Example Playbook
----------------
| Variable | Default Value | Description |
|-----------------------------|---------------------------|---------------------------------------------------------------------------------|
| `rsnapshot_snapshot_root` | `/var/lib/rsnapshot` | Root directory for storing snapshots. |
| `rsnapshot_retains` | `{"hourly": 6, "daily": 7, "weekly": 4, "monthly": 12 }` | Retention policy for snapshots. |
| `rsnapshot_backups` | `[]` | Array of backup configurations. See example below. |
| `rsnapshot_backup_scripts` | `[]` | Array of scripts to execute before backups. |
Including an example of how to use your role (for instance, with variables passed in as parameters) is always nice for users too:
## Dependencies
- hosts: servers
roles:
- { role: username.rolename, x: 42 }
None.
License
-------
## Example Playbook
BSD
```yaml
- hosts: backupservers
become: true
roles:
- role: glenux.rsnapshot
vars:
rsnapshot_backups:
- remote:
user: backupuser
host: 192.168.1.10
paths:
- /etc
- /home
local: server1
- remote:
user: backupuser
host: 192.168.1.11
paths:
- /var/www
local: server2
rsnapshot_backup_scripts:
- /usr/local/bin/mysql_backup.sh
- /usr/local/bin/postgres_backup.sh
```
Author Information
------------------
## License
An optional section for the role authors to include contact information, or a website (HTML is not allowed).
This project is licensed under the BSD License - see the LICENSE file for details.
## Author Information
This role was created by [glenux](https://github.com/glenux).