Skip to content

Commit

Permalink
serve args
Browse files Browse the repository at this point in the history
Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com>
  • Loading branch information
eddycharly committed Oct 24, 2024
1 parent 44ba567 commit bd24325
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions pkg/commands/serve/command.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ func Command() *cobra.Command {
var policies []string
var address string
var healthaddress string
serve := &cobra.Command{
command := &cobra.Command{
Use: "serve",
Short: "Start the kyverno-envoy-plugin server",
Run: func(cmd *cobra.Command, args []string) {
Expand All @@ -20,5 +20,8 @@ func Command() *cobra.Command {
server.StartServers(ctx, srv)
},
}
return serve
command.Flags().StringSliceVar(&policies, "policy", nil, "Path to kyverno-json policies")
command.Flags().StringVar(&address, "address", ":9000", "Address to listen on")
command.Flags().StringVar(&healthaddress, "healthaddress", ":8181", "Address to listen on for health checks")
return command
}

0 comments on commit bd24325

Please sign in to comment.