mirror of
https://github.com/dokku/dokku.git
synced 2025-12-29 00:25:08 +01:00
This is a "one-shot" ability, meaning that it is highly discouraged for multiple plugins to implement the triggers. The `builder-create-dokku-image` trigger is meant to modify the base DOKKU_IMAGE that will be used to build an application. A good use of the hook is to inject system packages by: - calculating an image tag from the set of system packages - checking that the image doesnt already exist - creating the image if it does not As the output is sent to stdout, we have to find an alternative way of fetching the new DOKKU_IMAGE. The `builder-dokku-image` trigger can output an image tag based on the calculated image tag. If no tag is output, then the DOKKU_IMAGE is used as is. Using this pattern, users can efficiently modify the base image in use for an app without duplicating the work on every push. This is especially useful for package installation, where packages are required for app building, but may take a long time and can be error prone.