mirror of
https://github.com/kyverno/kyverno.git
synced 2025-03-31 03:45:17 +00:00
switched to default serve mux (#2592)
Signed-off-by: Siddharth Lal <siddharthlal25@gmail.com>
This commit is contained in:
parent
9e9af4872e
commit
11a9eb3fb9
1 changed files with 1 additions and 3 deletions
|
@ -113,16 +113,14 @@ func main() {
|
|||
os.Exit(1)
|
||||
}
|
||||
|
||||
var profilingServerMux *http.ServeMux
|
||||
var metricsServerMux *http.ServeMux
|
||||
var promConfig *metrics.PromConfig
|
||||
|
||||
if profile {
|
||||
profilingServerMux = http.NewServeMux()
|
||||
addr := ":" + profilePort
|
||||
setupLog.Info("Enable profiling, see details at https://github.com/kyverno/kyverno/wiki/Profiling-Kyverno-on-Kubernetes", "port", profilePort)
|
||||
go func() {
|
||||
if err := http.ListenAndServe(addr, profilingServerMux); err != nil {
|
||||
if err := http.ListenAndServe(addr, nil); err != nil {
|
||||
setupLog.Error(err, "Failed to enable profiling")
|
||||
os.Exit(1)
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue