in https://uber-go.github.io/fx/get-started/http-server.html
it said
We used fx.Provide to add an HTTP server to the application. The server hooks into the Fx application lifecycle--it will start serving requests when we call App.Run, and it will stop running when the application receives a stop signal. We used fx.Invoke to request that the HTTP server is always instantiated, even if none of the other components in the application reference it directly.
maybe you need run fx.Invoke once?