ConceptsServices
Web services
A web service is a public HTTP app. The proxy sends its requests to the instances in turn.
The proxy receives each request for the hostname of the service.
1 / 3
A web service is a public HTTP app. The proxy gives the requests to its instances in turn. This is load balancing.
The proxy sends <name>.<domain> to the service, for each domain of the server. It also sends each custom domain of the service to it.
HTTP/1.1, HTTP/2 and WebSockets pass through the proxy.
Create a web service
ferry create api --repo https://github.com/you/api --health /healthz --instances 2--health sets the path of the health check. --instances sets the number of instances.
What your app must do
Your app must listen on the port in the PORT environment variable, on the address 0.0.0.0.
An app that listens on 127.0.0.1 in its container gets no traffic.