Skip to content

Commit

Permalink
Merge pull request #45 from nextmn/fixup-port-http
Browse files Browse the repository at this point in the history
Fix port http
  • Loading branch information
louisroyer committed Jun 19, 2024
2 parents c3092ff + c06f52d commit 8fbd167
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
2 changes: 2 additions & 0 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,8 @@ github.com/nextmn/gopacket-srv6 v0.0.7 h1:GXDcb1S91VkC61uEJ6nyIMk34Wu6Wk1LfdoDXy
github.com/nextmn/gopacket-srv6 v0.0.7/go.mod h1:d00D3jb/joNiUXxCukaeymKdFL35ey7mmb+vr02MPmg=
github.com/nextmn/json-api v0.0.2 h1:Xo18bv+eWPc+BBfjNP5MdA0bWokaupzEGW5kt1BwYxg=
github.com/nextmn/json-api v0.0.2/go.mod h1:gi9IhsD+FFg7iEnJaZtEaY1WlZkQ75KBBk0z5FmSJBU=
github.com/nextmn/json-api v0.0.3 h1:COfRvrXsPOnkYTMoEfcX55n2H1dDKJh86AqT8+N6qZo=
github.com/nextmn/json-api v0.0.3/go.mod h1:gi9IhsD+FFg7iEnJaZtEaY1WlZkQ75KBBk0z5FmSJBU=
github.com/pelletier/go-toml/v2 v2.2.2 h1:aYUidT7k73Pcl9nb2gScu7NSrKCSHIDE89b3+6Wq+LM=
github.com/pelletier/go-toml/v2 v2.2.2/go.mod h1:1t835xjRzz80PqgE6HHgN2JOsmgYu/h4qDAS4n929Rs=
github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=
Expand Down
3 changes: 2 additions & 1 deletion internal/app/setup.go
Original file line number Diff line number Diff line change
Expand Up @@ -65,11 +65,12 @@ func (s *Setup) AddTasks() {
} else {
httpURI = httpURI + s.config.HTTPAddress.String() + ":" + httpPort
}
httpAddr := fmt.Sprintf("[%s]:%s", s.config.HTTPAddress, httpPort)

// 0.3 http server

rr := tasks.NewRulesRegistry()
s.RegisterTask("ctrl.rest-api", tasks.NewHttpServerTask(httpURI, rr))
s.RegisterTask("ctrl.rest-api", tasks.NewHttpServerTask(httpAddr, rr))

// 0.4 controller registry
if s.config.Locator != nil {
Expand Down

0 comments on commit 8fbd167

Please sign in to comment.