This repository has been archived by the owner. It is now read-only.

Add attribute s3_media_base_url #394

Closed
wants to merge 14 commits into
from
View
@@ -31,6 +31,7 @@ r2/count.pickle
r2/srcount.pickle
r2/myproduction.ini
r2/run.ini
+r2/example.ini
.DS_Store
r2/r2.egg-info/**
r2/r2/public/static/sprite*.png
View
@@ -73,16 +73,11 @@ clean_i18n:
UPDATE_FILES := $(wildcard *.update)
INIFILES := $(UPDATE_FILES:.update=.ini)
-.PHONY: clean_ini
-
ini: $(INIFILES)
$(INIFILES): %.ini: %.update
./updateini.py example.ini $< > $@ || rm $@
-clean_ini:
- rm $(INIFILES)
-
#################### Static Files
STATIC_DIR := r2/public/static
View
@@ -373,9 +373,11 @@ s3_old_thumb_bucket =
# May be one bucket, or many buckets seperated by commas
s3_media_buckets =
+s3_media_base_url = s3.amazonaws.com
+
# Store direct urls for images, rather than buckets
# For the bucket mybucket with the image helloworld.jpg the stored url would be:
-# true: http://s3.amazonaws.com/mybucket/helloworld.jpg
+# true: http://s3_media_base_url/mybucket/helloworld.jpg
# false: http://mybucket/helloworld.jpg
s3_media_direct = true
@@ -18,8 +18,6 @@
"i": ("compact", "text/html; charset=UTF-8"),
}
-API_TYPES = ('api', 'json')
-
def set_extension(environ, ext):
environ["extension"] = ext
environ["render_style"], environ["content_type"] = extension_mapping[ext]
View
@@ -51,7 +51,6 @@ def make_map(global_conf={}, app_conf={}):
mc('/about/message/:where', controller='message', action='listing')
mc('/about/log', controller='front', action='moderationlog')
- mc('/about', controller='front', action='about')
mc('/about/:location', controller='front',
action='editreddit', location = 'about')
@@ -81,7 +80,7 @@ def make_map(global_conf={}, app_conf={}):
mc('/awards', controller='front', action='awards')
mc('/i18n', controller='redirect', action='redirect',
- dest='http://www.reddit.com/r/i18n')
+ dest='http://www.populr.de/r/i18n')
mc('/feedback', controller='feedback', action='feedback')
mc('/ad_inq', controller='feedback', action='ad_inq')
@@ -106,11 +105,6 @@ def make_map(global_conf={}, app_conf={}):
where='overview')
mc('/u/:username', controller='redirect', action='user_redirect')
- # preserve timereddit URLs from 4/1/2012
- mc('/t/:timereddit', controller='redirect', action='timereddit_redirect')
- mc('/t/:timereddit/*rest', controller='redirect',
- action='timereddit_redirect')
-
mc('/prefs/:location', controller='forms',
action='prefs', location='options')
@@ -210,7 +204,6 @@ def make_map(global_conf={}, app_conf={}):
mc('/post/:action', controller='post',
requirements=dict(action="options|over18|unlogged_options|optout|optin|login|reg"))
- mc('/api', controller='redirect', action='redirect', dest='/dev/api')
mc('/api/distinguish/:how', controller='api', action="distinguish")
# wherever this is, google has to agree.
mc('/api/gcheckout', controller='ipn', action='gcheckout')
@@ -231,9 +224,6 @@ def make_map(global_conf={}, app_conf={}):
mc("/api/v1/:action", controller="oauth2access", requirements=dict(action="access_token"))
mc("/api/v1/:action", controller="apiv1")
- mc('/dev', controller='redirect', action='redirect', dest='/dev/api')
- mc('/dev/api', controller='apidocs', action='docs')
-
mc("/button_info", controller="api", action="info", limit = 1)
mc('/captcha/:iden', controller='captcha', action='captchaimg')
@@ -249,7 +239,7 @@ def make_map(global_conf={}, app_conf={}):
dest='http://github.com/reddit/')
mc('/mobile', controller='redirect', action='redirect',
- dest='http://m.reddit.com/')
+ dest='http://m.populr.de/')
mc('/authorize_embed', controller = 'front', action = 'authorize_embed')
@@ -60,7 +60,6 @@
from api import ApiController
from api import ApiminimalController
-from api_docs import ApidocsController
from apiv1 import APIv1Controller as Apiv1Controller
from oauth2 import OAuth2FrontendController as Oauth2frontendController
from oauth2 import OAuth2AccessController as Oauth2accessController
Oops, something went wrong.