tanzu-cli
tanzu-cli copied to clipboard
non interactive cli
Please provide the ability to make the cli non interactive and have the ability to configure per system not only per user.
Trying to automate tasks with a ci/cd pipeline with this cli is challenging at best.
It appears as though setting up a new context can be completed in a non-interactive way, however, the ability to set up a context system wide compared to per user would be a great addition:
$env:TANZU_API_TOKEN = "<redacted_api_token>" ; $env:TANZU_CLI_CEIP_OPT_IN_PROMPT_ANSWER = 'no' ; tanzu config eula accept ; tanzu context create --endpoint "<redacted_site>" --name "<redacted_name>"
Hi @ysineil. Thanks for the request. The Tanzu CLI should be 100% automatable today but it’s possible some flags or environment variables needed are not well documented.
Could you provide some examples that are causing you problems?
@dogseye do I understand correctly that you would like the CLI to be prefilled with the context? So one person creates it for the whole team for example.
This sounds interesting. Could you open a different issue for this?
@marckhouzam - I'd say this all stems from having to set a context for each user, happy for this issue to be just for that ability. I'll open another issue should we encounter specific commands/issues with automating using the tanzu cli as we migrate from the tkg cli.
The tkg cli was a lot more user-friendly (it was not documented well either) and simple in comparison, so it was a much easier process to get things automated.
@ysineil I don’t believe the tkg CLI allowed a shared setup, did it? Was it the login
command that made things easier?