turnkeylinux / tracker

TurnKey Linux Tracker
https://www.turnkeylinux.org
70 stars 16 forks source link

devise and document inithook policy/"best practice" #1126

Open JedMeister opened 6 years ago

JedMeister commented 6 years ago

Somewhat along the lines of #1125; we should clarify the policy surrounding inithooks. And/or we should be documenting inithooks "best practice". IMO this would be really useful for developers and maintainers, especially devs that aren't particularly familiar with python. It will support code consistency across appliances and reduce introduction of edge case bugs and poor practices.

637 & #1112 are somewhat related issues.

We should highlight some good code examples of setting/adjusting specific things via inithooks (e.g. setting an appliance domain, adjusting a DB entry, etc). Then when a maintainer (or new appliance developer) needs to add a new question to an inithook or adjust functionality, they have a single place to double check "best practice" and some code snippets that they can use as a base for their changes.

Resolution of this issue could provide something of a design framework for a "inithook-lib" (which could include resolution of #637 & #1112).

Also relevant to #728 & #275

JedMeister commented 6 years ago

I've added the tkldev tag as this should be linked to in the tkldev docs (included in inithooks docs IMO).