cli
cli copied to clipboard
automate step-cli PR in winget registry
Hello!
- Vote on this issue by adding a đź‘Ť reaction
- If you want to implement this feature, comment to let us know (we'll work with you on design, scheduling, etc.)
Issue details
I would like to see step-cli in winget registry.
Why is this needed?
Winget is standard windows package manager. I think installation/uninstallation through winget would make step-cli usage easier. I know about ps1 script, but this script, as i see, don't have any uninstallation option and makes step-cli disconnected from the rest of the package management system.
Thank you for opening this issue, we'll take a look in the coming days and see what we can do.
Winget support would be great to add, as Winget is Microsoft's official CLI tool for installing packages.
So, in Windows Package Manager 1.4 (released just a few days ago), Microsoft has added full support for portable packages to Winget. This is ideal for distributing step.exe
and step-ca.exe
.
Prior to 1.4, Winget packages had to be full-blown MSI installers.
Portable packages, which are described more fully here, can be as simple as a manifest file and a ZIPped binary fetched from a URL. Here's the manifest schema, and here's documentation on how to create and validate a manifest file using Microsoft's tools—which we probably won't need to use for this.
To submit a package to the Winget registry, you open a pull request on microsoft/winget-pkgs. The full package submission process is documented here.
👉 Here's an example of a Winget portable package manifest for fly.io's flyctl.exe
.
I think we have three options here:
- Wait for GoReleaser to add goreleaser/goreleaser#2290
- Add support to GoReleaser ourselves and submit a PR.
- Roll our own yaml for this as a separate part of the release process.
The actual issue is goreleaser/goreleaser#1295 but it has been stale for a while, so @tashian if you want to go for it I would go for 3 (or 2)
Quick update. I've hand-crafted and tested a step
package, and opened this PR. This can serve as a template for us, and now we just need the release process piece.
I've also tested and pushed a step-ca
package, in this PR on Microsoft's repo.
@bapho-bush you can now install step with winget install Smallstep.step
.
My plan from here is to watch https://github.com/goreleaser/goreleaser/issues/2290 (which has some recent activity) for updates over the next month or so, and I will make manual PRs for step-cli releases in the meantime.
Also (cc @dopey) this GH Action looks promising, and it uses a Windows VM.
Also (cc @dopey) this GH Action looks promising, and it uses a Windows VM.
Is a windows VM really necessary, looking at the winget PR, it looks like we could templatize the files and use a GH action to do a pull request in a remote repository. We might be able to even use the same strategy for Homebrew.
Also (cc @dopey) this GH Action looks promising, and it uses a Windows VM.
Is a windows VM really necessary, looking at the winget PR, it looks like we could templatize the files and use a GH action to do a pull request in a remote repository. We might be able to even use the same strategy for Homebrew.
A windows VM is definitely not necessary, and I'd prefer not to use one. Just dropped that here as a ref.
winget
is indeed similar to how we do Homebrew deploys, and if I don't see any movement on GoReleaser in the next month or two, my plan is to adapt what we do there already.
We'll leave this open until the process is automated.
@bapho-bush you can now install step with
winget install Smallstep.step
.My plan from here is to watch goreleaser/goreleaser#2290 (which has some recent activity) for updates over the next month or so, and I will make manual PRs for step-cli releases in the meantime.
Glad to hear. Thank you for your job.
https://github.com/smallstep/cli/pull/984 contains the automation piece.