Files
teletypegames/http/http.go
T
2026-01-27 20:01:25 +01:00

21 lines
588 B
Go
Executable File

package http
import (
"teletype_softwares/domain"
"teletype_softwares/lib/http_utils"
)
func StartHttpServer(domainInstance domain.Domain) {
router := NewRouter(
NewSoftwareController(domainInstance.SoftwareService),
NewSoftwareUpdaterController(domainInstance.SoftwareUpdaterService),
NewDownloadController(domainInstance.DownloadService),
NewPlayController(domainInstance.SoftwareService, domainInstance.FileService),
NewRootController(),
).Init()
http_utils.StartGenericHTTPServer(http_utils.StartGenericHTTPServerContext{
Router: router,
})
}