Re: Queries regarding staticfiles | pgarchives - Mailing list pgsql-www

From Sahil Harpal
Subject Re: Queries regarding staticfiles | pgarchives
Date
Msg-id CAKi=nndMH=Qd=0O_6Su0gyL46_P-EUfhHjnHnmGqad2c6-F4nQ@mail.gmail.com
Whole thread Raw
In response to Re: Queries regarding staticfiles | pgarchives  (Magnus Hagander <magnus@hagander.net>)
Responses Re: Queries regarding staticfiles | pgarchives  (Magnus Hagander <magnus@hagander.net>)
List pgsql-www


On Wed, 15 Jun 2022 at 22:43, Magnus Hagander <magnus@hagander.net> wrote:
That depends on what webserver you're using. For example, in uwsgi you'd add something like:
static-map=/media-archives=/some/where/pgarchives/django/media 

For nginx, it'd be something like:
        location /media-archives/ {
                alias /some/where/pgarchives/django/media/;
        }

I tried this, but still, it is showing 404.
I created a .ini file and added the following values. and instead of running the server using runserver command I am using uwsgi.

[uwsgi]
http = localhost:8000
wsgi-file = archives/wsgi.py
static-map = /media-archives=/pgarchives/django/media 

Am I missing anything here?

Oh. Yes, anything outside of /list/ is loaded from pgweb. The dyncss is one of them. And yes, this is kind of a hacky and terrible way, but that's how it is right now. Certain parts of them have to be kept in sync.

We need them separately because the same pgarchives code is also run standalone, for our private archives. And in that scenario, there is no pgweb involved.

Okay, so let's say if I want to make some changes in https://www.postgresql.org/list/, https://www.postgresql.org/list/pgsql-admin/, https://www.postgresql.org/list/pgsql-admin/2022-06/ etc. In which file should I make changes? main.css of pgweb or pgarchives or both (since pgarchives can also run standalone)? 

Thanks,
Sahil Harpal

pgsql-www by date:

Previous
From: Magnus Hagander
Date:
Subject: Re: Queries regarding staticfiles | pgarchives
Next
From: Magnus Hagander
Date:
Subject: Re: can not download mbox