Files
mtusi2026lab6/internal/controller/fx.go
T

9 lines
243 B
Go

package controller
import "go.uber.org/fx"
// RunControllerFx lets Fx own startup, signal handling and graceful shutdown.
func RunControllerFx(lc fx.Lifecycle, ctrl Controller) {
lc.Append(fx.Hook{OnStart: ctrl.Start, OnStop: ctrl.Stop})
}