Deploy on VPS or PC (Binary)
Here I suppose you're using Linux server (Windows is similar).
Steps
- Download the latest version from Release page and extract it to your machine, let's say
/opt/subconv. It should containapifile andstaticfolder. cd /opt/subconvto enter the directorychmod +x api.pyto give it execution permission- Run
./api -G defaultto generate the default configuration file. Then modify it as needed. If you need to use ZJU's configuration file, you can use./api -G zjuto generate ZJU's configuration file. For detailed configuration items, please refer to Configuration ./api -hto see the help message.
For example, you can use./api -H 127.0.0.1 -P 2534' or './api -H 127.0.0.1 -P 2534to specify the host and port to listen. If all parameters are omitted, the host will be0.0.0.0and the port will be8080Note: If you're not using a privileged user, you usually can't bind to a port below 1024. It's recommended to use a high port or you can use
setcapto give python the permission to bind to a low port.- Use reverse proxy (optional)