This reminds me a bit of the container image builder "Kubler" (https://github.com/edannenberg/kubler) which is also configured with Bash scripts.
Just creating a cross-reference for the interested here :)
Just creating a cross-reference for the interested here :)