Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mplesa omaha sync #12

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter...
Filter file types
Jump to…
Jump to file
Failed to load files.

Always

Just for now

@@ -7,7 +7,7 @@ RUN \
apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys ABF5BD827BD9BF62 && \
echo 'deb http://nginx.org/packages/ubuntu/ trusty nginx' | tee --append /etc/apt/sources.list && \
apt-get update && \
apt-get install -y --no-install-recommends jq python-pip python-dev python-lxml python-psycopg2 libpq-dev supervisor nginx liblua5.1-dev lua-zlib libtiff5-dev libjpeg8-dev zlib1g-dev libfreetype6-dev liblcms2-dev libwebp-dev python-pil build-essential libfuse-dev libcurl4-openssl-dev libxml2-dev mime-support automake libtool pkg-config libssl-dev wget tar && \
apt-get install -y --no-install-recommends python-pip python-dev python-lxml python-psycopg2 libpq-dev supervisor nginx liblua5.1-dev lua-zlib libtiff5-dev libjpeg8-dev zlib1g-dev libfreetype6-dev liblcms2-dev libwebp-dev python-pil build-essential libfuse-dev libcurl4-openssl-dev libxml2-dev mime-support automake libtool pkg-config libssl-dev wget tar jq && \
apt-get clean && \
apt-get autoremove -y && \
rm -rf /var/lib/{apt,dpkg,cache,log}/ && \
@@ -7,7 +7,7 @@ load_module modules/ndk_http_module.so;
load_module modules/ngx_http_lua_module.so;

events {
worker_connections 20000;
worker_connections 2048;
# multi_accept on;
}

@@ -7,5 +7,5 @@ chunked-input-timeout = 300
socket-timeout = 300
buffer-size = 65535
master = 1
workers = 64
workers = 512
listen = 1024
@@ -6,7 +6,6 @@

import os


class BaseS3Storage(S3BotoStorage):
def url(self, name):
url = super(BaseS3Storage, self).url(name)
@@ -15,7 +14,7 @@ def url(self, name):
if 'x-amz-security-token' in f.args:
del f.args['x-amz-security-token']
url = f.url
if os.environ.get('CDN_FRONTEND'):
if os.environ.get('CDN_NAME'):
f = furl(url)
f.set(host=os.environ.get('CDN_NAME'))
url = f.url
@@ -0,0 +1,12 @@
from .settings_prod import *

# TODO: should work by default
STATIC_URL = 'https://{}.s3.amazonaws.com/'.format(os.environ.get('AWS_STORAGE_BUCKET_NAME'))
MEDIA_URL = 'https://{}.s3.amazonaws.com/'.format(os.environ.get('AWS_STORAGE_BUCKET_NAME'))

if os.environ.get('CDN_NAME'):
CDN_NAME = os.environ.get('CDN_NAME')

CUP_PEM_KEYS = {
'1': '/run/secrets/cup_key'
}
ProTip! Use n and p to navigate between commits in a pull request.
You can’t perform that action at this time.