admin管理员组

文章数量:1123011

I’ve been working on setting up OpenWISP with Ansible, and here’s what I’ve done so far:

Installed Ansible OpenWISP on my local system. Located the CSS file I wanted to modify at /opt/openwisp2/static/admin/css/openwisp.css. Instead of modifying the file directly, I created a custom CSS file in /opt/openwisp2/static_custom and updated it there. Ran python manage.py collectstatic to gather all static files into the STATIC_ROOT directory. Restarted Nginx to ensure the changes would take effect. Despite all these steps, the CSS changes are not reflecting in the browser. I’ve tried:

Clearing the browser cache and using Ctrl + F5. Verifying that the updated file is present in the STATIC_ROOT directory. Checking Nginx logs for any errors. What could I be missing? Is there any additional configuration needed for Nginx, Django, or OpenWISP to properly serve the updated CSS file?

Any help or insights would be greatly appreciated.

Thanks in advance!

What I Tried:

Located the CSS file I wanted to update: /opt/openwisp2/static/admin/css/openwisp.css. Added my changes in a custom directory: /opt/openwisp2/static_custom. Ran python manage.py collectstatic to update static files in the STATIC_ROOT directory. Restarted Nginx to apply the changes. Cleared my browser cache and force-refreshed the page (Ctrl + F5). What I Expected: I expected the updated CSS styles to be reflected on the web pages served by OpenWISP.

What Happened Instead: The old styles are still being applied, and the changes made to the custom CSS file are not reflected on the site.

This concise explanation makes it clear what you did, what you wanted to happen, and what the issue is.

本文标签: