feat: Command that generates a private key with well known params.
This commit is contained in:
1 parent
56fc799cf6
commit
6eb97bb780
7 files changed
+143
No files matched your search
@@ -0,0 +1,28 @@
|
||||
package hmpki
|
||||
|
||||
import (
|
||||
"github.com/spf13/cobra"
|
||||
)
|
||||
|
||||
var Output string
|
||||
|
||||
func init() {
|
||||
rootCmd.AddCommand(generateCmd)
|
||||
|
||||
// All "generate" commands output an artifact to a file,
|
||||
// be it a key or a cert, etc.
|
||||
generateCmd.PersistentFlags().StringVarP(
|
||||
&Output,
|
||||
"output",
|
||||
"o",
|
||||
"",
|
||||
"output filename",
|
||||
)
|
||||
generateCmd.MarkPersistentFlagRequired("output")
|
||||
generateCmd.MarkPersistentFlagFilename("output")
|
||||
}
|
||||
|
||||
var generateCmd = &cobra.Command{
|
||||
Use: "generate",
|
||||
Short: "Generate pki resources (keys/certs)",
|
||||
}
|
||||
Reference in new issue
Block a user