Forskjell mellom versjoner av «Diskusjon:ISC-DHCP»

Fra Bitraf
Hopp til navigering Hopp til søk
m (move references section to bottom)
(enable reuse of playbooks: ny seksjon)
Linje 13: Linje 13:
 
== References ==
 
== References ==
 
<references/>
 
<references/>
 +
 +
== enable reuse of playbooks ==
 +
 +
Do not put system-level commands, statements or limits in the playbook. Examples:
 +
<pre>
 +
  strategy: free
 +
  remote_user: root
 +
</pre>
 +
they don't belong there, and they hinder reuse. Instead, use '''become''' when necessary. [[Bruker:Tingo|Tingo]] ([[Brukerdiskusjon:Tingo|diskusjon]]) 16. okt. 2022 kl. 19:47 (CEST)

Revisjonen fra 16. okt. 2022 kl. 19:47

Some changes are needed for this to work with Bitraf's ansible setup. You can find Bitraf's setup in the infrastructure[1] repository. Required changes will be documented below. Tingo (diskusjon) 16. okt. 2022 kl. 19:30 (CEST)

Use ansible roles

Bitraf uses roles[2] in the ansible setup. This makes it easy to re-use a playbook and associated variables. The roles Bitraf use can be found in the shared-roles directory. For an examples, look at the infoscreen role. Please rewrite the playbook as a shared role. Tingo (diskusjon) 16. okt. 2022 kl. 19:35 (CEST)

variables in separate files

Put variables into separate files, not in the playbook itself. Again, this helps with reuse. Tingo (diskusjon) 16. okt. 2022 kl. 19:40 (CEST)

References

enable reuse of playbooks

Do not put system-level commands, statements or limits in the playbook. Examples:

  strategy: free
  remote_user: root

they don't belong there, and they hinder reuse. Instead, use become when necessary. Tingo (diskusjon) 16. okt. 2022 kl. 19:47 (CEST)