• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion

Resolved Serve static content from /home directory

Stefano#7366

New Pleskian
Hello there!

Bare with me as I'm new to Plesk, and setting something up for a client.
Currently we've got a problem where we want to serve the static content for a Django/Python application through a apache config.

The problem we're getting however, is the static content not showing up at all.

1600509745627.png
The broken image is the static content, and it resides in "domain.com/static/assets/images/white_logo.png".

The current config we're using in the apache and nginx settings menu is:
Apache config:
ServerName shop.visengaming.com
ServerAlias www.shop.visengaming.com
DocumentRoot /home/donationstore/env
ServerAdmin [email protected]
UseCanonicalName Off

# Donation Store
ProxyPass /static/ !
ProxyPass / http://135.181.2.162:8000/
Alias /static/ /home/donationstore/env/static/
 
Nevermind, issue has been solved:
Config used:

Code:
DocumentRoot /home/donationstore/env
ServerAdmin [email protected]
UseCanonicalName Off

# Donation Store
ProxyPass /static/ !
ProxyPass / http://IP:8000/
Alias /static/ /home/donationstore/env/static/

<Directory "/home/donationstore/env/static/">
        Options +Indexes +FollowSymLinks +ExecCGI
        AllowOverride All
                Order allow,deny
        Allow from all
        Require all granted
</Directory>

I had to add the override and directory because of the 403's
 
Back
Top