Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

Feature request: "--browser" flag for "cf login"

Aperta
#1,898 5 commenti 0 reazioni 1 assegnatario Vedi su GitHub

@a-b ci sta già lavorando.

Dal 1/10/2024.

Valutazione

Questa issue non è ancora stata valutata.

Descrizione

product-improvement

Context

Single sign-on flow is fragile depending on terminal emulator used by user.

Some users, running cf login --sso are given a link, which is copy-and-pasteable into a web browser; more commonly, users use their terminal emulator to click the link. This link can sometimes be truncated to domain.suffix/pa or passcod, etc due to line-wrapping, or other issues.

These problems are to do with the terminal emulator, and so are not fixable by CF CLI, however the CLI could provide more ergonomic ways for getting a passcode.

Concourse's CLI fly has a --browser / -b flag which performs the flow automatically, by opening the browser which, in turn, redirects the user to a local port. This may be overkill however.

I propose either implementing the --browser flag via Fly, or alternatively provider an --open-browser flag which opens the passcode URL, obviating the need for a user to copy/paste the link.

The --sso-passcode flag is useful, but does not solve the problem described.

What's the user value of this feature request?

Operators of Cloud Foundry would be able to document a less fragile way of signing in, either by using the --browser flow or the --open-browser flag to automatically link users to the correct page.

Who is the functionality for?

This could be used by any user who uses single sign-on to log in.

How often will this functionality be used by the user?

Whenever the user logs in.

Who else is affected by the change?

This would be a non-breaking change

Is your feature request related to a problem? Please describe.

Users semi-regularly report that SSO is not working, because their terminal emulator does not play nicely with CF CLI output.

Describe the solution you'd like

One of, depending on preferences of product management:

As a user, I want to be able to run cf login --sso --browser which automatically conducts the browser login flow, with a local redirection, so that I don't have to copy and paste.

As a user, I want to be able to run cf login --sso --open-browser which automatically opens the passcode page in my browser, so that copy-and-pasting the link is more ergonomic, and less fragile

Describe alternatives you've considered

Writing a CF Plugin instead

Lingua principale
Go
Stelle
1.9k
Fork
990
Merge medio
1g 7h
PR unite (30g)
8

Guida per i contributori

Apri la guida per i contributori

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di cloudfoundry/cli

Tutte le issue di cloudfoundry/cli

Issue simili

Altre issue su Go

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.