httpServer.go 353 B

12345678910111213141516
  1. package httpservers
  2. import (
  3. config "github.com/jamesread/OliveTin/internal/config"
  4. )
  5. // StartServers will start 3 HTTP servers. The WebUI, the Rest API, and a proxy
  6. // for both of them.
  7. func StartServers(cfg *config.Config) {
  8. go startWebUIServer(cfg)
  9. go startRestAPIServer(cfg)
  10. if cfg.UseSingleHTTPFrontend {
  11. StartSingleHTTPFrontend(cfg)
  12. }
  13. }