It doesn’t seem to be possible using an ansible list for a hook file path.
I want to extend the deploy_build_after hook file, adding new functionality while preserving the original one (from Trellis). I want to avoid editing the file directly for better pulling+merging further Trellis updates (I use trellis as normal git repository and pull from GitHub).
That would be good, but it doesn’t seem to work, does it? In my test deployment just stopped before doing the build_after stuff, no error message or so.
@mockey Thanks for trying and reporting back. Trying just now, I get the same result. It’s baffling that the play just stops with no errors.
I think a “task include” parses and loads things a little differently than regular and has a problem with the usage of a default containing a quoted string. Here’s an example of changes Trellis might make to enable the nested include strategy above to succeed.
There may be something Ansible needs to fix upstream, but perhaps Trellis could make this implementation adjustment for all deploy hooks in order to facilitate nested includes.