Forskjell mellom versjoner av «Diskusjon:ISC-DHCP»

Fra Bitraf
Hopp til navigering Hopp til søk
(Start the discussion page)
 
m (move references section to bottom)
 
(6 mellomliggende revisjoner av samme bruker vises ikke)
Linje 1: Linje 1:
 
Some changes are needed for this to work with Bitraf's ansible setup. You can find Bitraf's setup in the infrastructure<ref>[https://github.com/bitraf/infrastructure github - bitraf - infrastructure]</ref> repository. Required changes will be documented below. [[Bruker:Tingo|Tingo]] ([[Brukerdiskusjon:Tingo|diskusjon]]) 16. okt. 2022 kl. 19:30 (CEST)
 
Some changes are needed for this to work with Bitraf's ansible setup. You can find Bitraf's setup in the infrastructure<ref>[https://github.com/bitraf/infrastructure github - bitraf - infrastructure]</ref> repository. Required changes will be documented below. [[Bruker:Tingo|Tingo]] ([[Brukerdiskusjon:Tingo|diskusjon]]) 16. okt. 2022 kl. 19:30 (CEST)
  
 +
== Use ansible roles ==
 +
 +
Bitraf uses roles<ref>[https://docs.ansible.com/ansible/latest/user_guide/playbooks_reuse_roles.html ansible - roles]</ref> 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 <code>shared-roles</code> directory. For an examples, look at the '''infoscreen''' role.
 +
Please rewrite the playbook as a shared role. [[Bruker:Tingo|Tingo]] ([[Brukerdiskusjon: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. [[Bruker:Tingo|Tingo]] ([[Brukerdiskusjon:Tingo|diskusjon]]) 16. okt. 2022 kl. 19:40 (CEST)
 +
 +
== 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)
  
 
== References ==
 
== References ==
 
<references/>
 
<references/>

Nåværende revisjon 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)

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)

References