mirror of
https://github.com/jackyzha0/quartz.git
synced 2025-12-27 23:04:05 -06:00
Add inventory file with default groups and group naming conventions
This commit is contained in:
parent
c0fe21f4d1
commit
30a65ed7d4
@ -285,3 +285,32 @@ In this playbook:
|
||||
|
||||
The playbook orchestrates the entire workflow across different sets of servers, with each play and its tasks focused on a specific aspect of the overall configuration.
|
||||
|
||||
|
||||
|
||||
ungrouped:
|
||||
hosts:
|
||||
mail.example.com:
|
||||
webservers:
|
||||
hosts:
|
||||
foo.example.com:
|
||||
bar.example.com:
|
||||
dbservers:
|
||||
hosts:
|
||||
one.example.com:
|
||||
two.example.com:
|
||||
three.example.com:
|
||||
|
||||
|
||||
Even if you do not define any groups in your inventory file, Ansible creates two default groups: `all` and `ungrouped`. The `all` group contains every host. The `ungrouped` group contains all hosts that don’t have another group aside from `all`. Every host will always belong to at least 2 groups (`all` and `ungrouped` or `all` and some other group). For example, in the basic inventory above, the host `mail.example.com` belongs to the `all` group and the `ungrouped` group; the host `two.example.com` belongs to the `all` group and the `dbservers` group. Though `all` and `ungrouped` are always present, they can be implicit and not appear in group listings like `group_names`.
|
||||
|
||||
# How to name groups in ansible
|
||||
|
||||
- What - An application, stack or microservice (for example, database servers, web servers, and so on).
|
||||
|
||||
- Where - A datacenter or region, to talk to local DNS, storage, and so on (for example, east, west).
|
||||
|
||||
- When - The development stage, to avoid testing on production resources (for example, prod, test).
|
||||
|
||||
#parentchildansible
|
||||
https://docs.ansible.com/ansible/latest/inventory_guide/intro_inventory.html#grouping-groups-parent-child-group-relationships
|
||||
|
||||
|
||||
3
content/Devops&DevSecOps/Vscode Dev Containers.md
Normal file
3
content/Devops&DevSecOps/Vscode Dev Containers.md
Normal file
@ -0,0 +1,3 @@
|
||||
https://code.visualstudio.com/docs/devcontainers/containers
|
||||
|
||||
#devcontainers
|
||||
Loading…
Reference in New Issue
Block a user