Skip to content

Commit

Permalink
Make customers use key ID, not fingerprint (#112)
Browse files Browse the repository at this point in the history
  • Loading branch information
marcinwyszynski committed Jan 2, 2023
1 parent db5c3ea commit 8d16d03
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 6 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,4 @@ spacectl
build
dist
key.*
*.asc
2 changes: 1 addition & 1 deletion internal/cmd/provider/create_version.go
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ func createVersion() cli.ActionFunc {
ProtocolVersions: cliCtx.StringSlice(flagProviderVersionProtocols.Name),
SHASumsFileSHA: checksumsFileChecksum,
SignatureFileSHA: signatureFileChecksum,
SigningKeyID: cliCtx.String(gpgKeyFingerprint.Name),
SigningKeyID: cliCtx.String(flagGPGKeyID.Name),
},
}

Expand Down
8 changes: 4 additions & 4 deletions internal/cmd/provider/flags.go
Original file line number Diff line number Diff line change
Expand Up @@ -60,9 +60,9 @@ var flagRequiredVersionID = &cli.StringFlag{
Required: true,
}

var gpgKeyFingerprint = &cli.StringFlag{
Name: "gpg-fingerprint",
Usage: "ID (fingerprint) of the GPG key used to sign the provider version",
EnvVars: []string{"GPG_FINGERPRINT"},
var flagGPGKeyID = &cli.StringFlag{
Name: "gpg-key-id",
Usage: "ID of the GPG key used to sign the provider version",
EnvVars: []string{"GPG_KEY_ID"},
Required: true,
}
2 changes: 1 addition & 1 deletion internal/cmd/provider/provider.go
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ func Command() *cli.Command {
flagProviderType,
flagProviderVersionProtocols,
flagGoReleaserDir,
gpgKeyFingerprint,
flagGPGKeyID,
},
Action: createVersion(),
Before: authenticated.Ensure,
Expand Down

0 comments on commit 8d16d03

Please sign in to comment.