• Please be aware: Kaspersky Anti-Virus has been deprecated
    With the upgrade to Plesk Obsidian 18.0.64, "Kaspersky Anti-Virus for Servers" will be automatically removed from the servers it is installed on. We recommend that you migrate to Sophos Anti-Virus for Servers.
  • The Horde webmail has been deprecated. Its complete removal is scheduled for April 2025. For details and recommended actions, see the Feature and Deprecation Plan.
  • We’re working on enhancing the Monitoring feature in Plesk, and we could really use your expertise! If you’re open to sharing your experiences with server and website monitoring or providing feedback, we’d love to have a one-hour online meeting with you.

Question Run Python3.6 WebScripts?

UweP

Regular Pleskian
Hi all. My question is, how can I run Python3.6 Web Applications. What is the preferred way to do this with Plesk Onyx? I have mod_python but it's outdated. Thanks!
 
For Python support consider using mod_wsgi which is part of CentOS and also allows Python apps to run under Apache.
 
ah ok ;D thanks ;D im on debian 8. so i just install the mod_wsgi for apache, activate it somewhere in the panel and then i set a vhost configuration to use mod_wsgi? :)
 
I installed mod_wsgi, but how do I configure a vhost now? hm, trying to find documentation on this.
 
ok thanks, i checked the documentation, but is there any way i can enable it per vhost? eg. use / on vhost to serve the py file?
 
hm, it now says:
Template_Exception: Can not restart web server:

file: /opt/psa/admin/plib/Service/Driver/Web/Server/Apache.php

line: 109

code: 0
 
hm, it keeps saying bad gateway or internal server error when using this as the apache https configuration:

WSGIScriptAlias / /var/www/vhosts/mydomain.tld/s4.mydomain.de/vsearch4web.py

<Directory /var/www/vhosts/mydomain.tld/s4.mydomain.de/>
Order allow,deny
Allow from all
</Directory>
 
Last edited:
right now it keeps saying (when deactiving nginx) that i dont have permission to access that file also it wants to let me download if i access the file directly.
 
ok well i have two problems finding the instance of python the web interpreter is using. because i need to isntall flask on it.
 
Back
Top