-
Notifications
You must be signed in to change notification settings - Fork 198
FEAT: Interactive registry login #4008
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
FEAT: Interactive registry login #4008
Conversation
✅ Deploy Preview for zarf-docs canceled.
|
I will figure out how to update the docs tomorrow |
|
Codecov Report❌ Patch coverage is
🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
DCO, lint, and Docs and I believe this is in a good place. Functionality performs as expected for me locally.
craneCmd.Example = lang.CmdToolsRegistryLoginExample | ||
craneCmd.Flags().BoolVar(&o.interactive, "interactive", false, lang.CmdToolsRegistryLoginFlagInteractive) | ||
|
||
craneCmd.PreRunE = func(cmd *cobra.Command, args []string) error { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Appreciative of this addition - while not strictly required - it is a great addition to this workflow from the Zarf UX perspective.
I can get this done tonight hopefully - ansible-mans other account |
@brandtkeller Please let me know if there is anything else to be done here and I can get to it this week - ansible-man |
DCO needs signing - typically Otherwise the linting job has a few minor items that need to be adjusted otherwise this looks good to me. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
linting feedback
src/cmd/crane.go
Outdated
if err != nil { | ||
return err | ||
} | ||
cmd.Flags().Set("username", uname) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Linting flagged here for error check
cmd.Flags().Set("username", uname) | |
err := cmd.Flags().Set("username", uname) | |
if err != nil { | |
return err | |
} |
src/cmd/crane.go
Outdated
if err != nil { | ||
return err | ||
} | ||
cmd.Flags().Set("password", pass) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Linting flagged here
cmd.Flags().Set("password", pass) | |
err := cmd.Flags().Set("password", pass) | |
if err != nil { | |
return err | |
} |
src/cmd/crane.go
Outdated
} | ||
cmd.Flags().Set("password", pass) | ||
} | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
linting - remove this blank line
src/cmd/crane.go
Outdated
|
||
} | ||
return o.originalRunFn(cmd, args) | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
linting - remove this blank line
Signed-off-by: Cade Thomas <[email protected]>
Signed-off-by: Cade Thomas <[email protected]>
…v#4013) Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Signed-off-by: Cade Thomas <[email protected]>
…-dev#4014) Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Signed-off-by: Cade Thomas <[email protected]>
Signed-off-by: Allen Conlon <[email protected]> Signed-off-by: Brandt Keller <[email protected]> Co-authored-by: Brandt Keller <[email protected]> Signed-off-by: Cade Thomas <[email protected]>
…o 28.3.2+incompatible (zarf-dev#4009) Signed-off-by: dependabot[bot] <[email protected]> Signed-off-by: Austin Abro <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Austin Abro <[email protected]> Signed-off-by: Cade Thomas <[email protected]>
…2.1 (zarf-dev#4015) Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Signed-off-by: Cade Thomas <[email protected]>
…rf-dev#4011) Signed-off-by: Allen Conlon <[email protected]> Signed-off-by: Cade Thomas <[email protected]>
…arf-dev#4020) Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Signed-off-by: Cade Thomas <[email protected]>
…v#4017) Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Signed-off-by: Cade Thomas <[email protected]>
…3914) Signed-off-by: Brandt Keller <[email protected]> Signed-off-by: Cade Thomas <[email protected]>
…rf-dev#4019) Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Signed-off-by: Cade Thomas <[email protected]>
…arf-dev#4018) Signed-off-by: dependabot[bot] <[email protected]> Signed-off-by: Brandt Keller <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Brandt Keller <[email protected]> Signed-off-by: Cade Thomas <[email protected]>
…f-dev#3932) Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Signed-off-by: Cade Thomas <[email protected]>
Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Signed-off-by: Cade Thomas <[email protected]>
…arf-dev#4010) Signed-off-by: dependabot[bot] <[email protected]> Signed-off-by: Brandt Keller <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Brandt Keller <[email protected]> Signed-off-by: Cade Thomas <[email protected]>
…o 28.3.3+incompatible (zarf-dev#4025) Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Signed-off-by: Cade Thomas <[email protected]>
…v#4027) Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Signed-off-by: Cade Thomas <[email protected]>
…8.3.3+incompatible in the docker group across 1 directory (zarf-dev#4030) Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Signed-off-by: Cade Thomas <[email protected]>
Signed-off-by: Austin Abro <[email protected]> Signed-off-by: Austin Abro <[email protected]> Co-authored-by: Kit Patella <[email protected]> Signed-off-by: Cade Thomas <[email protected]>
Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Signed-off-by: Cade Thomas <[email protected]>
Signed-off-by: Austin Abro <[email protected]> Signed-off-by: Cade Thomas <[email protected]>
…-dev#4082) Signed-off-by: dependabot[bot] <[email protected]> Signed-off-by: Brandt Keller <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Brandt Keller <[email protected]> Signed-off-by: Cade Thomas <[email protected]>
…rf-dev#4088) Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Signed-off-by: Cade Thomas <[email protected]>
…arf-dev#4089) Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Signed-off-by: Cade Thomas <[email protected]>
Signed-off-by: Austin Abro <[email protected]> Signed-off-by: Cade Thomas <[email protected]>
Signed-off-by: Brandt Keller <[email protected]> Co-authored-by: Austin Abro <[email protected]> Signed-off-by: Cade Thomas <[email protected]>
Signed-off-by: Kit Patella <[email protected]> Signed-off-by: Cade Thomas <[email protected]>
…zarf-dev#4092) Signed-off-by: Brandt Keller <[email protected]> Signed-off-by: Cade Thomas <[email protected]>
Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Brandt Keller <[email protected]> Signed-off-by: Cade Thomas <[email protected]>
Signed-off-by: Chad Beaudin <[email protected]> Signed-off-by: Cade Thomas <[email protected]>
zarf-dev#4099) Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Signed-off-by: Cade Thomas <[email protected]>
…v#4102) Signed-off-by: Brandt Keller <[email protected]> Signed-off-by: Cade Thomas <[email protected]>
Signed-off-by: Brandt Keller <[email protected]> Signed-off-by: Cade Thomas <[email protected]>
…ev#4100) Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Signed-off-by: Cade Thomas <[email protected]>
Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Signed-off-by: Cade Thomas <[email protected]>
) Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Signed-off-by: Cade Thomas <[email protected]>
… 4.3.1 (zarf-dev#4106) Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Signed-off-by: Cade Thomas <[email protected]>
Signed-off-by: Brandt Keller <[email protected]> Signed-off-by: Cade Thomas <[email protected]>
…2.5 (zarf-dev#4101) Signed-off-by: dependabot[bot] <[email protected]> Signed-off-by: Brandt Keller <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Brandt Keller <[email protected]> Signed-off-by: Cade Thomas <[email protected]>
…v#4112) Signed-off-by: Austin Abro <[email protected]> Signed-off-by: Cade Thomas <[email protected]>
…-dev#4114) Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Signed-off-by: Cade Thomas <[email protected]>
…v#4115) Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Signed-off-by: Cade Thomas <[email protected]>
Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Signed-off-by: Cade Thomas <[email protected]>
Signed-off-by: Allen Conlon <[email protected]> Signed-off-by: Cade Thomas <[email protected]>
…f-injector (zarf-dev#4070) Signed-off-by: Austin Abro <[email protected]> Signed-off-by: Cade Thomas <[email protected]>
Signed-off-by: Brandt Keller <[email protected]> Co-authored-by: Maciej Szulik <[email protected]> Signed-off-by: Cade Thomas <[email protected]>
Signed-off-by: Cade Thomas <[email protected]>
edfe951
to
638cea3
Compare
Description
This PR allows users to pass the --interactive flag to zarf tools registry login. This helps prevent credentials from being exposed to bash history and syslog. Fully backwards compatible with the existing flags the --interactive flag will only prompt the user for information they did not provide at command runtime.
...
Related Issue
#4003
Checklist before merging