UffizziCloud / uffizzi_cli

The command-line interface for the Uffizzi API
Apache License 2.0
87 stars 46 forks source link

Various CLI updates #397

Closed gadkins closed 8 months ago

gadkins commented 10 months ago

Summary

  1. When the user logs in for the first time, ask them to select their configuration of choice: Uffizzi Cloud (default) or install Uffizzi Business. If the latter, display install command and link to docs.
$ uffizzi login
Login successful
Select an account: (Press ↑/↓/←/→ arrow to move and Enter to select)
‣ Acme Inc.
  gadkins
Select a project or create a new project: 
‣ Create a new project
  ...
Project foo was successfully created

####################################################################

By default this CLI is configured for use with Uffizzi Cloud. 
To see options for self-hosting Uffizzi, run `uffizzi install -h`.  
moklidia commented 8 months ago

@gadkins Will this information (Uffizzi Cloud/ Uffizzi Business) used in the future? Should it be saved?

gadkins commented 8 months ago

@moklidia Per our discussion:

Each time a user runs uffizzi login display the following messages, conditioned on if they are connect to Uffizzi Cloud or their own installation's controller (where [CONTROLLER_HOST] is the hostname of the user's installed controller.

Uffizzi Cloud

$ uffizzi login
Login successful
Select an account: (Press ↑/↓/←/→ arrow to move and Enter to select)
‣ Acme Inc.
  gadkins
Select a project or create a new project: 
‣ Create a new project
  ...
Project foo was successfully created

####################################################################

Your CLI is configured to use https://app.uffizzi.com (Uffizzi Cloud).

Run `uffizzi config -h` to see CLI configuration options.
Run `uffizzi install -h` to see self-hosted installation options.

Self-hosted

$ uffizzi login
Login successful
Select an account: (Press ↑/↓/←/→ arrow to move and Enter to select)
‣ Acme Inc.
  gadkins
Select a project or create a new project: 
‣ Create a new project
  ...
Project foo was successfully created

####################################################################

Your CLI is configured to use [CONTROLLER_HOST].

Run `uffizzi config -h` to see CLI configuration options.