diff --git a/README.md b/README.md index 3498232961edc431636af3c2b18d4ca245a1adfd..55144681212a4f28f07c618f25cc637390376c8e 100644 --- a/README.md +++ b/README.md @@ -13,17 +13,16 @@ To deploy this role to a managed host, the following software must be installed * Python3 * SSHd -It is recommended to use Debian VMs as deployed by SLUB's UDA tool with this role. - -## Quick Start - +Other roles required by this role can be easily installed using `ansible-galaxy` if necessary. As the roles reside in SLUB's local Git server instance, you might need a password for certain repositories despite most of them being publicly available. This command will install the required roles in the correct location so they are found in the search path: ``` - ansible-playbook site.yml [-i <INVENTORY_FILE>] [--limit <HOSTNAME>] [-u <USERNAME>] [-b] + ansible-galaxy install -r requirements.yml -p ../ ``` -## General Ansible usage +It is recommended to use Debian VMs as deployed by SLUB's UDA tool with this role. -Most options already have sensible defaults in `ansible.cfg`. However, you can override these defaults using CLI options/flags if you want to. +## Quick Start + +Most options already have sensible defaults in `ansible.cfg`. However, you can override these defaults using CLI options/flags if you want to. The flags can be combined if necessary, and most of them have long versions as well. Get more information using `ansible-playbook --help`. To simply run the playbook, just call the `site.yml` playbook like this: ``` @@ -44,12 +43,6 @@ If you do not have Vault password files in the directory above the role direcory ansible-playbook site.yml --ask-vault-pass ``` -You can use your own inventory file by adding the `-i` or `--inventory=INVENTORY` option: -``` - ansible-playbook site.yml -i inventory.yml - ansible-playbook site.yml --inventory=inventory.yml -``` - Tasks in this role have been tagged to enable users to only run subsets of tasks. This can be leveraged to decrease run times or run only certain tasks after small changes. To list all available tags, use: ``` @@ -61,8 +54,6 @@ You can then run only certain tagged tasks by using the `--tags` option: ansible-playbook site.yml --tags=tag1,tag2,...,tagN ``` -For more help with ansible-playbook, use the `--help` flag. - ## Testing the role Tests have been implemented using the Molecule framework. The details on using the test suite are described below `molecule/`. diff --git a/requirements.yml b/requirements.yml new file mode 100644 index 0000000000000000000000000000000000000000..58de2735f5b6827e12b1562b10af1fa3d6cd0566 --- /dev/null +++ b/requirements.yml @@ -0,0 +1,12 @@ +--- +# https://docs.ansible.com/ansible/latest/galaxy/user_guide.html#installing-multiple-roles-from-a-file +- src: git+https://git.slub-dresden.de/slub-referat-2-3/ansible_vaults.git + scm: git +- src: git+https://git.slub-dresden.de/digital-preservation/ansible_lza_install_common.git + scm: git +- src: git+https://git.slub-dresden.de/digital-preservation/ansible_lza_server_hardening.git + scm: git +- src: git+https://git.slub-dresden.de/digital-preservation/ansible_slub_osquery.git + scm: git +#- src: git+ +# scm: git