You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copier natively supports this and our CLI help for --template-uri in nava-platform infra commands indicate you can use a URL, but you can not. Currently the infra template must be a local path.
Most projects should probably reference a remote copy ultimately (to avoid needing to maintain a local copy of every template and conflicting local paths saved to the answers file).
With recent work to switch the include/exclude logic to a custom worker/src path based/more statically defined, the only remaining bits in InfraTemplate that depend having a local git copy are the version/short_version properties, which shouldn't be needed for typical install/update processes. So should be able to just remove:
raiseValueError("Infra template must be a git working directory")
But more of a question about when we are ready to commit to supporting remote URLs from a product perspective.
This might present some issues for anyone running the tool under docker (and wanting to use ssh/git URLs instead of HTTP ones).
Couple different approaches:
Avoid ever interacting with git for a template outside of copier itself (maybe not realistic long-term, but possibly viable for a while)
Use copier's local checkout logic (or re-implement ourselves) within our template code to do the git interactions we need before passing to copier (we probably can't pass the temporary checkout to copier to use directly as that would get saved to the answers file, so would have to let copier copy the remote again?)
The text was updated successfully, but these errors were encountered:
doshitan
changed the title
Support remote templates
Support remote (infra) templates
Nov 12, 2024
Copier natively supports this and our CLI help for
--template-uri
innava-platform infra
commands indicate you can use a URL, but you can not. Currently the infra template must be a local path.Most projects should probably reference a remote copy ultimately (to avoid needing to maintain a local copy of every template and conflicting local paths saved to the answers file).
With recent work to switch the include/exclude logic to a custom worker/src path based/more statically defined, the only remaining bits in
InfraTemplate
that depend having a local git copy are theversion
/short_version
properties, which shouldn't be needed for typical install/update processes. So should be able to just remove:platform-cli/nava/platform/infra_template.py
Lines 24 to 27 in 79cf262
But more of a question about when we are ready to commit to supporting remote URLs from a product perspective.
This might present some issues for anyone running the tool under docker (and wanting to use ssh/git URLs instead of HTTP ones).
Couple different approaches:
git
for a template outside of copier itself (maybe not realistic long-term, but possibly viable for a while)The text was updated successfully, but these errors were encountered: