From 5a3be1b5753541ec526c41b00692c48398c7256c Mon Sep 17 00:00:00 2001 From: David Ormsbee Date: Mon, 6 Feb 2012 15:33:30 -0500 Subject: [PATCH] extend AWS S3 expiration to 10 years so that we don't have askbot images disappearing --- settings_new_askbot.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/settings_new_askbot.py b/settings_new_askbot.py index 8c63960b38..9dadc0836e 100644 --- a/settings_new_askbot.py +++ b/settings_new_askbot.py @@ -39,6 +39,13 @@ HTTPS = 'on' MEDIA_URL = '' MEDIA_ROOT = '' +# S3BotoStorage insists on a timeout for uploaded assets. We should make it +# permanent instead, but rather than trying to figure out exactly where that +# setting is, I'm just bumping the expiration time to something absurd (100 +# years). This is only used if DEFAULT_FILE_STORAGE is overriden to use S3 +# in the global settings.py +AWS_QUERYSTRING_EXPIRE = 10 * 365 * 24 * 60 * 60 # 10 years + # Needed for Askbot # Deployed machines: Move to S3 DEFAULT_FILE_STORAGE = 'django.core.files.storage.FileSystemStorage'