Commit 9fdd56e82842c5f7b2e02786031e4e881aebb078

Authored by Luan
2 parents 4eff79a2 65e58268

Merge branch 'master' of github.com:TracyWebTech/colab

puppet/modules/colab/manifests/init.pp
... ... @@ -45,7 +45,7 @@ class colab {
45 45 }
46 46  
47 47 supervisor::app { 'colab':
48   - command => '/home/colab/.virtualenvs/colab/bin/gunicorn colab.wsgi:application -t 300',
  48 + command => '/home/colab/.virtualenvs/colab/bin/gunicorn colab.wsgi:application --timeout=300 --worker-class=gevent --workers=5',
49 49 directory => '/home/colab/colab/src/',
50 50 user => 'colab',
51 51 }
... ...
puppet/modules/colab/manifests/requirements.pp
... ... @@ -88,4 +88,9 @@ class colab::requirements {
88 88 package { 'openjdk-7-jre':
89 89 ensure => installed,
90 90 }
  91 +
  92 + package { 'memcached':
  93 + ensure => installed,
  94 + }
  95 +
91 96 }
... ...
requirements.txt
... ... @@ -13,6 +13,7 @@ pysolr==2.1
13 13 etiquetando==0.1
14 14 html2text
15 15 django-taggit
  16 +python-memcached
16 17  
17 18 gunicorn
18 19 gevent
... ...
src/colab/custom_settings.py
... ... @@ -63,6 +63,13 @@ DATABASES = {
63 63 }
64 64 }
65 65  
  66 +CACHES = {
  67 + 'default': {
  68 + 'BACKEND': 'django.core.cache.backends.memcached.MemcachedCache',
  69 + 'LOCATION': '127.0.0.1:11211',
  70 + }
  71 +}
  72 +
66 73 DATABASE_ROUTERS = ['colab.routers.TracRouter',]
67 74  
68 75 INSTALLED_APPS = INSTALLED_APPS + (
... ...
src/templates/404.html
  1 +{% extends "base.html" %}
1 2 {% load i18n %}
2 3  
3   -<h1>{% trans "Not found. Keep searching! :)" %}</h1>
  4 +{% block main-content %}
  5 + <h1>{% trans "Not found. Keep searching! :)" %}</h1>
  6 +{% endblock %}
  7 +
  8 +{% block footer %}{% endblock %}
... ...
src/templates/500.html
  1 +{% extends "base.html" %}
1 2 {% load i18n %}
2 3  
3   -<h1>{% trans "Ooopz... something went wrong!" %}</h1>
  4 +{% block main-content %}
  5 + <h1>{% trans "Ooopz... something went wrong!" %}</h1>
  6 +{% endblock %}
  7 +
  8 +{% block footer %}{% endblock %}
... ...
src/templates/home.html
... ... @@ -6,13 +6,7 @@
6 6 {% endblock %}
7 7  
8 8 {% block header %}
9   - <div class="row hidden-xs hidden-sm">
10   - <div class="col-lg-2 col-lg-offset-5 text-center">
11   - <img src="{{ STATIC_URL }}img/logo.png" />
12   - </div>
13   - </div>
14   -
15   - <h3 class="text-center hidden-xs hidden-sm">{% trans "INTERLEGIS COMMUNITIES" %}</h3>
  9 + {% include "includes/big_header.html" %}
16 10 {% endblock %}
17 11  
18 12 {% block main-content %}
... ...
src/templates/includes/big_header.html 0 → 100644
... ... @@ -0,0 +1,9 @@
  1 +{% load i18n %}
  2 +
  3 +<div class="row hidden-xs hidden-sm">
  4 + <div class="col-lg-2 col-lg-offset-5 text-center">
  5 + <img src="{{ STATIC_URL }}img/logo.png" />
  6 + </div>
  7 +</div>
  8 +
  9 +<h3 class="text-center hidden-xs hidden-sm">{% trans "INTERLEGIS COMMUNITIES" %}</h3>
... ...