Skip to content

Commit

Permalink
feat: healthcheck for aws ALB (#33)
Browse files Browse the repository at this point in the history
* feat: healthcheck for aws ALB

* quick fix

* quick fix

---------

Co-authored-by: Nathan Pierce <[email protected]>
  • Loading branch information
tim-goto and NorseGaud authored Oct 14, 2024
1 parent d90b344 commit e0f8c4f
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
1 change: 1 addition & 0 deletions .github/workflows/check-pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ jobs:
uses: actions/setup-go@v4
with:
go-version: 1.22.2
cache: false
- name: Run GoReleaser build
uses: goreleaser/goreleaser-action@v4
with:
Expand Down
4 changes: 4 additions & 0 deletions plugins/receivers/github/github.go
Original file line number Diff line number Diff line change
Expand Up @@ -174,6 +174,10 @@ func Run(
}

server := &http.Server{Addr: ":" + ctxPlugin.Port}
http.HandleFunc("/healthcheck", func(w http.ResponseWriter, r *http.Request) {
w.WriteHeader(http.StatusOK)
w.Write([]byte("ok"))
})
http.HandleFunc("/jobs/v1/receiver", func(w http.ResponseWriter, r *http.Request) {
databaseContainer, err := database.GetDatabaseFromContext(pluginCtx)
if err != nil {
Expand Down

0 comments on commit e0f8c4f

Please sign in to comment.