i'm following the query of the documentation of nginx unit with fastapi => https://unit.nginx.org/howto/fastapi/
I ran this query : curl -X PUT --data-binary @config.json --unix-socket /var/run/control.unit.sock http://localhost/config/
but i got an error :
"error": "Invalid configuration.", "detail": "The module to run "python 3.8" is not found among the available application modules."
my config file (config.json) look like this :
{
"listeners": {
"*:80": {
"pass": "applications/fastapi"
}
},
"applications": {
"fastapi": {
"type": "python 3.8",
"path": "/home/ubuntu/inference1",
"home": "/home/ubuntu/anaconda3/envs/inference1/bin",
"module": "application",
"callable": "app"
}
}
}
the command line query i run to see the modules : ls /usr/lib/unit/modules gives me :
java11.unit.so perl.unit.so python2.7.unit.so python3.7.unit.so ruby.unit.so java8.unit.so php.unit.so python3.6.unit.so python3.8.unit.so
If someone knows why the query is returning me the error i cannot find it :'(