Host an mlservicewrapper.core.services.Service as an HTTP API.
Using the development server is sufficient for testing, but should not be used in production.
| Parameter | Required? | Description | Format |
|---|---|---|---|
| --config | Yes | Path to service configuration file. | --config <path> |
| --host | No | Host to bind to. Defaults to 127.0.0.1. | --host <host name> |
| --port | No | Port to bind to. Defaults to 5000. | --host <host name> |
Use gunicorn to run in production:
export SERVICE_CONFIG_PATH=/path/to/config.json
gunicorn -w 4 -k uvicorn.workers.UvicornWorker mlservicewrapper.host.http.server