Opened 12 years ago

Last modified 11 years ago

#300 new defect

Handle Django static (e.g., admin) media in autoinstallers

Reported by: adehnert Owned by:
Priority: major Milestone: Fedora 20
Component: autoinstallers Keywords:

Description (last modified by adehnert)

Django 1.4 messed around with this. We should figure out a decent solution. See also -c scripts -i root tonight (ie, 2012-07-01 ~06:00).

To summarize the discussion from zephyr: I think we need to:

  1. Set STATIC_ROOT to something sane
  2. Set STATIC_URL to something sane
  3. Either run collectstatic at install time or make something Awesome that suppresses gathering admin files and redirects serving them to the global copy.

Attachments (2)

django-autoinstaller-updates.patch (1.8 KB) - added by lfaraone 11 years ago.
django-autoinstaller-updates.2.patch (1.9 KB) - added by lfaraone 11 years ago.

Download all attachments as: .zip

Change History (6)

comment:1 Changed 11 years ago by adehnert

  • Description modified (diff)

comment:2 Changed 11 years ago by achernya

  • Milestone set to Fedora 19

comment:3 Changed 11 years ago by lfaraone

Commit message I was intending to use:

Additional updates for Django 1.4/1.5: static files, admin interface, README

Here we provide proper support for static files on Scripts, see

This means we designate a path for static files (~/web_scripts/$name/static)
and refer to the static files by their full url over
HTTPS. This should work even if the user deploys the app on a subdomain or a
non-MIT hostname.

At the same time, we fix the rule to enable the admin interface,
which broke with the new URL pattern syntax a while ago. 

Finally, we run collectstatic to ensure that the relevant files are copied over.

In addition, a README was added to the web_scripts directory to help avoid
confusion over "where're my files?".

I don't know if there's a way to add that to the .patch the way I would in git, so enclosed above.

Last edited 11 years ago by lfaraone (previous) (diff)

Changed 11 years ago by lfaraone

Changed 11 years ago by lfaraone

comment:4 Changed 11 years ago by adehnert

Committed to locker-dev in r2443.

Note: See TracTickets for help on using tickets.