Lono supports a variety of hooks. They can be used to customize and finely control the lifecycle process.
There are 2 hook types that operate at different levels:
- Project-level: These hooks operate at the Lono project level. These hooks run on all stacks. They are defined in the root of the Lono project in the
config/hooksfolder. Project-level hooks run before blueprint or module level hooks.
- Blueprint-level: These hooks operate at the blueprint level. They are defined in the blueprint folder. For example:
app/stacks/demo/config/hooks. These hooks only run for that specific blueprint.
There are several types of hooks, so you may be unsure which to use. When in doubt, use the blueprint-level hooks. You probably want hooks to fire when deploying a specific blueprint only.