Skip to content

When self-hosting, static files do not seem to be available despite being generated within the container #51

Open

Description

@zaniyah

Django generates the files and the permissions etc are correct. I do not see any errors, but the static files are not available.

I know that it can be worked around by eg getting nginx to serve the static files instead, but this does not seem to be documented if that is the expected best way to do it.

Activity

  1. developerfromjokela commented on Sep 12, 2026

    @developerfromjokela
    Owner

    Django generates the files and the permissions etc are correct. I do not see any errors, but the static files are not available.

    I know that it can be worked around by eg getting nginx to serve the static files instead, but this does not seem to be documented if that is the expected best way to do it.

    Yeah, django does not serve them unfortunately for production. I assume since they're just static files, their idea is to not serve them with backend.

    Docker compose could include a nginx server. But I guess many people will have nginx, so there will be two nginx instances :D

    Do you have any suggestions? Open to ideas.

  2. zaniyah commented on Sep 16, 2026

    @zaniyah
    Author

    I had been thinking of adding nginx to the docker-compose.yml, and updating the documentation so that those who want to run it separately know where to look for the configuration they would need. They could then comment out that part of the docker-compose.yml. This would also allow us to add the proxy there. However, it does make it more difficult to set up your certificates, and many will be wanting to use letsencrypt (I hope).

    This may not be the best approach. I am unsure what the majority of users are doing when they self-host.

    I would also maybe add a firewalld rules suggestion, but that should probably be a separate issue for the documentation only.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentationImprovements or additions to documentation

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions