mirror of
https://github.com/prometheus-operator/prometheus-operator.git
synced 2025-04-16 09:16:38 +00:00
* update golangci lint version --------- Signed-off-by: dongjiang1989 <dongjiang1989@126.com>
31 lines
931 B
Go
31 lines
931 B
Go
// Copyright 2017 The prometheus-operator Authors
|
|
//
|
|
// Licensed under the Apache License, Version 2.0 (the "License");
|
|
// you may not use this file except in compliance with the License.
|
|
// You may obtain a copy of the License at
|
|
//
|
|
// http://www.apache.org/licenses/LICENSE-2.0
|
|
//
|
|
// Unless required by applicable law or agreed to in writing, software
|
|
// distributed under the License is distributed on an "AS IS" BASIS,
|
|
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
// See the License for the specific language governing permissions and
|
|
// limitations under the License.
|
|
|
|
package main
|
|
|
|
import (
|
|
"fmt"
|
|
"net/http"
|
|
)
|
|
|
|
const (
|
|
port = "5001"
|
|
)
|
|
|
|
func main() {
|
|
fmt.Printf("Listening for Alertmanager notifications on :%s\n", port)
|
|
_ = http.ListenAndServe(":"+port, http.HandlerFunc(func(_ http.ResponseWriter, _ *http.Request) {
|
|
fmt.Println("Alertmanager Notification Payload Received")
|
|
}))
|
|
}
|