{"record":{"id":"8135cb3f34aa1287","repo":"fatedier/frp","slug":"type-http-not-supported-when-vhost-http-port-is","errorCode":null,"errorMessage":"type [http] not supported when vhost http port is not set","messagePattern":"type \\[http\\] not supported when vhost http port is not set","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"pkg/config/v1/validation/proxy.go","lineNumber":217,"sourceCode":"\treturn nil\n}\n\nfunc validateUDPProxyConfigForServer(c *v1.UDPProxyConfig, s *v1.ServerConfig) error {\n\treturn nil\n}\n\nfunc validateTCPMuxProxyConfigForServer(c *v1.TCPMuxProxyConfig, s *v1.ServerConfig) error {\n\tif c.Multiplexer == string(v1.TCPMultiplexerHTTPConnect) &&\n\t\ts.TCPMuxHTTPConnectPort == 0 {\n\t\treturn fmt.Errorf(\"tcpmux with multiplexer httpconnect not supported because this feature is not enabled in server\")\n\t}\n\n\treturn validateDomainConfigForServer(&c.DomainConfig, s)\n}\n\nfunc validateHTTPProxyConfigForServer(c *v1.HTTPProxyConfig, s *v1.ServerConfig) error {\n\tif s.VhostHTTPPort == 0 {\n\t\treturn fmt.Errorf(\"type [http] not supported when vhost http port is not set\")\n\t}\n\n\treturn validateDomainConfigForServer(&c.DomainConfig, s)\n}\n\nfunc validateHTTPSProxyConfigForServer(c *v1.HTTPSProxyConfig, s *v1.ServerConfig) error {\n\tif s.VhostHTTPSPort == 0 {\n\t\treturn fmt.Errorf(\"type [https] not supported when vhost https port is not set\")\n\t}\n\n\treturn validateDomainConfigForServer(&c.DomainConfig, s)\n}\n\nfunc validateSTCPProxyConfigForServer(c *v1.STCPProxyConfig, s *v1.ServerConfig) error {\n\treturn nil\n}\n\nfunc validateXTCPProxyConfigForServer(c *v1.XTCPProxyConfig, s *v1.ServerConfig) error {","sourceCodeStart":199,"sourceCodeEnd":235,"githubUrl":"https://github.com/fatedier/frp/blob/6c8a8d0a97d03b44e9528d30b30c70cb9d61b405/pkg/config/v1/validation/proxy.go#L199-L235","documentation":"Error \"type [http] not supported when vhost http port is not set\" thrown in fatedier/frp.","triggerScenarios":"Raised by validateProxyConfigForServer in pkg/config/v1/validation/proxy.go when an HTTP proxy is configured but vhostHTTPPort is not set on the server.","commonSituations":"A proxy of type http is declared while the server's vhostHTTPPort is 0/unset. Fix by setting vhostHTTPPort in the server config or using a tcp proxy instead.","solutions":["Set vhostHTTPPort in the frps configuration so HTTP proxies can be served.","Use a different proxy type (for example tcp) if the server has no vhost HTTP port."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"6c8a8d0a97d03b44e9528d30b30c70cb9d61b405","analyzedAt":"2026-08-15T06:53:27.215Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}