+++ /dev/null
-#!/bin/bash
-#
-# Use as:
-#
-# source <(curl d.nowoczesnapolska.org.pl)
-#
-
-
-PROJECT="$1"
-
-# Make it a function, so that it works with `source`
-start_project() {
-
-DJANGO_REQ='Django>=1.6,<1.7'
-DJANGO_ROOT='src'
-
-PYPI='http://pypi.nowoczesnapolska.org.pl/simple'
-PROJECT_TEMPLATE='http://git.nowoczesnapolska.org.pl/?p=fnpdjango.git;a=snapshot;h=project;sf=tgz'
-
-VIRTUALENVWRAPPER_PATHS="
- /etc/bash_completion.d/virtualenvwrapper
- /usr/bin/virtualenvwrapper.sh
- /usr/local/bin/virtualenvwrapper.sh
-"
-
-# Colorful output.
-strong='\e[0;32m'
-error='\e[1;31m'
-normal='\e[0m'
-
-echo "Create new Django project."
-while [ -z "$PROJECT" ]
-do
- echo "Name of the project:"
- read PROJECT
-done
-echo -e "Project: ${strong}${PROJECT}${normal}"
-
-for venv in $VIRTUALENVWRAPPER_PATHS
-do
- if [ -e "$venv" ]
- then
- VIRTUALENVWRAPPER="$venv"
- break
- fi
-done
-if [ "$VIRTUALENVWRAPPER" ]
-then
- echo "virtualenvwrapper found at $VIRTUALENVWRAPPER."
- source "$VIRTUALENVWRAPPER"
-else
- echo -e "${error}ERROR: virtualenvwrapper not found. Tried locations:${normal}"
- echo "$VIRTUALENVWRAPPER_PATHS"
- echo -e "${error}Install virtualenvwrapper or add the correct path to this script.${normal}"
- echo "Aborting."
- return
-fi
-
-echo -e "${strong}Creating virtualenv: $PROJECT...${normal}"
-mkvirtualenv "$PROJECT"
-echo -e "${strong}Installing Django...${normal}"
-pip install -i "$PYPI" "$DJANGO_REQ"
-pip install -i "$PYPI" --pre django-startproject-plus
-
-echo -e "${strong}Starting the project...${normal}"
-django-startproject.py \
- --template "$PROJECT_TEMPLATE" \
- --name NOTICE \
- --extra_context='{"year": "`date +%Y`"}' \
- "$PROJECT"
-
-cd "$PROJECT"
-
-# GitWeb adds a top directory to the snapshot, let's remove it.
-if [ ! -e .gitignore ]
-then
- WRAPPER="`ls`"
- mv "$WRAPPER/"* "$WRAPPER/".gitignore .
- rmdir "$WRAPPER"
-fi
-
-chmod +x "$DJANGO_ROOT"/manage.py
-mv "$DJANGO_ROOT/$PROJECT/localsettings.py.dev" "$DJANGO_ROOT/$PROJECT/localsettings.py"
-
-echo -e "${strong}Installing requirements...${normal}"
-pip install -i "$PYPI" -r requirements.txt
-echo -e "${strong}Installing developer requirements...${normal}"
-pip install -i "$PYPI" -r requirements-dev.txt
-echo -e "${strong}Running syncdb...${normal}"
-"$DJANGO_ROOT"/manage.py syncdb --noinput
-
-echo -e "${strong}Starting new git repository...${normal}"
-git init
-
-echo -e "${strong}What next?${normal}"
-echo " * Work on your app, commit to git."
-echo " * Review fabfile, use fab for deployment."
-
-
-}
-start_project
-
-# The following is just for displaying it as a webpage:<!--
-#--><style>body{white-space:pre;color:#ddd}</style><h1 style="color:#000;text-align:center;position:fixed;top:0;bottom:0;left:0;right:0;white-space:normal">source <(curl <span id="location"></span>)</h1><script>document.getElementById('location').innerHTML=window.location;</script>
-
+++ /dev/null
-#!/bin/bash -
-#
-# File: git-archive-all.sh
-#
-# Description: A utility script that builds an archive file(s) of all
-# git repositories and submodules in the current path.
-# Useful for creating a single tarfile of a git super-
-# project that contains other submodules.
-#
-# Examples: Use git-archive-all.sh to create archive distributions
-# from git repositories. To use, simply do:
-#
-# cd $GIT_DIR; git-archive-all.sh
-#
-# where $GIT_DIR is the root of your git superproject.
-#
-# License: GPL3
-#
-###############################################################################
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2 of the License, or
-# (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program; if not, write to the Free Software
-# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
-#
-###############################################################################
-
-# DEBUGGING
-set -e
-set -C # noclobber
-
-# TRAP SIGNALS
-trap 'cleanup' QUIT EXIT
-
-# For security reasons, explicitly set the internal field separator
-# to newline, space, tab
-OLD_IFS=$IFS
-IFS='
- '
-
-function cleanup () {
- rm -f $TMPFILE
- rm -f $TOARCHIVE
- IFS="$OLD_IFS"
-}
-
-function usage () {
- echo "Usage is as follows:"
- echo
- echo "$PROGRAM <--version>"
- echo " Prints the program version number on a line by itself and exits."
- echo
- echo "$PROGRAM <--usage|--help|-?>"
- echo " Prints this usage output and exits."
- echo
- echo "$PROGRAM [--format <fmt>] [--prefix <path>] [--verbose|-v] [--separate|-s] [output_file]"
- echo " Creates an archive for the entire git superproject, and its submodules"
- echo " using the passed parameters, described below."
- echo
- echo " If '--format' is specified, the archive is created with the named"
- echo " git archiver backend. Obviously, this must be a backend that git archive"
- echo " understands. The format defaults to 'tar' if not specified."
- echo
- echo " If '--prefix' is specified, the archive's superproject and all submodules"
- echo " are created with the <path> prefix named. The default is to not use one."
- echo
- echo " If '--separate' or '-s' is specified, individual archives will be created"
- echo " for each of the superproject itself and its submodules. The default is to"
- echo " concatenate individual archives into one larger archive."
- echo
- echo " If 'output_file' is specified, the resulting archive is created as the"
- echo " file named. This parameter is essentially a path that must be writeable."
- echo " When combined with '--separate' ('-s') this path must refer to a directory."
- echo " Without this parameter or when combined with '--separate' the resulting"
- echo " archive(s) are named with a dot-separated path of the archived directory and"
- echo " a file extension equal to their format (e.g., 'superdir.submodule1dir.tar')."
- echo
- echo " If '--verbose' or '-v' is specified, progress will be printed."
-}
-
-function version () {
- echo "$PROGRAM version $VERSION"
-}
-
-# Internal variables and initializations.
-readonly PROGRAM=`basename "$0"`
-readonly VERSION=0.2
-
-OLD_PWD="`pwd`"
-TMPDIR=${TMPDIR:-/tmp}
-TMPFILE=`mktemp "$TMPDIR/$PROGRAM.XXXXXX"` # Create a place to store our work's progress
-TOARCHIVE=`mktemp "$TMPDIR/$PROGRAM.toarchive.XXXXXX"`
-OUT_FILE=$OLD_PWD # assume "this directory" without a name change by default
-SEPARATE=0
-VERBOSE=0
-
-FORMAT=tar
-PREFIX=
-TREEISH=HEAD
-
-# RETURN VALUES/EXIT STATUS CODES
-readonly E_BAD_OPTION=254
-readonly E_UNKNOWN=255
-
-# Process command-line arguments.
-while test $# -gt 0; do
- case $1 in
- --format )
- shift
- FORMAT="$1"
- shift
- ;;
-
- --prefix )
- shift
- PREFIX="$1"
- shift
- ;;
-
- --separate | -s )
- shift
- SEPARATE=1
- ;;
-
- --version )
- version
- exit
- ;;
-
- --verbose | -v )
- shift
- VERBOSE=1
- ;;
-
- -? | --usage | --help )
- usage
- exit
- ;;
-
- -* )
- echo "Unrecognized option: $1" >&2
- usage
- exit $E_BAD_OPTION
- ;;
-
- * )
- break
- ;;
- esac
-done
-
-if [ ! -z "$1" ]; then
- OUT_FILE="$1"
- shift
-fi
-
-# Validate parameters; error early, error often.
-if [ $SEPARATE -eq 1 -a ! -d $OUT_FILE ]; then
- echo "When creating multiple archives, your destination must be a directory."
- echo "If it's not, you risk being surprised when your files are overwritten."
- exit
-elif [ `git config -l | grep -q '^core\.bare=false'; echo $?` -ne 0 ]; then
- echo "$PROGRAM must be run from a git working copy (i.e., not a bare repository)."
- exit
-fi
-
-# Create the superproject's git-archive
-if [ $VERBOSE -eq 1 ]; then
- echo -n "creating superproject archive..."
-fi
-git archive --format=$FORMAT --prefix="$PREFIX" $TREEISH > $TMPDIR/$(basename $(pwd)).$FORMAT
-if [ $VERBOSE -eq 1 ]; then
- echo "done"
-fi
-echo $TMPDIR/$(basename $(pwd)).$FORMAT >| $TMPFILE # clobber on purpose
-superfile=`head -n 1 $TMPFILE`
-
-if [ $VERBOSE -eq 1 ]; then
- echo -n "looking for subprojects..."
-fi
-# find all '.git' dirs, these show us the remaining to-be-archived dirs
-# we only want directories that are below the current directory
-find . -mindepth 2 -name '.git' -type d -print | sed -e 's/^\.\///' -e 's/\.git$//' >> $TOARCHIVE
-# as of version 1.7.8, git places the submodule .git directories under the superprojects .git dir
-# the submodules get a .git file that points to their .git dir. we need to find all of these too
-find . -mindepth 2 -name '.git' -type f -print | xargs grep -l "gitdir" | sed -e 's/^\.\///' -e 's/\.git$//' >> $TOARCHIVE
-if [ $VERBOSE -eq 1 ]; then
- echo "done"
- echo " found:"
- cat $TOARCHIVE | while read arch
- do
- echo " $arch"
- done
-fi
-
-if [ $VERBOSE -eq 1 ]; then
- echo -n "archiving submodules..."
-fi
-while read path; do
- TREEISH=$(git submodule | grep "^ .*${path%/} " | cut -d ' ' -f 2) # git submodule does not list trailing slashes in $path
- cd "$path"
- git archive --format=$FORMAT --prefix="${PREFIX}$path" ${TREEISH:-HEAD} > "$TMPDIR"/"$(echo "$path" | sed -e 's/\//./g')"$FORMAT
- if [ $FORMAT == 'zip' ]; then
- # delete the empty directory entry; zipped submodules won't unzip if we don't do this
- zip -d "$(tail -n 1 $TMPFILE)" "${PREFIX}${path%/}" >/dev/null # remove trailing '/'
- fi
- echo "$TMPDIR"/"$(echo "$path" | sed -e 's/\//./g')"$FORMAT >> $TMPFILE
- cd "$OLD_PWD"
-done < $TOARCHIVE
-if [ $VERBOSE -eq 1 ]; then
- echo "done"
-fi
-
-if [ $VERBOSE -eq 1 ]; then
- echo -n "concatenating archives into single archive..."
-fi
-# Concatenate archives into a super-archive.
-if [ $SEPARATE -eq 0 ]; then
- if [ $FORMAT == 'tar' ]; then
- sed -e '1d' $TMPFILE | while read file; do
- tar --concatenate -f "$superfile" "$file" && rm -f "$file"
- done
- elif [ $FORMAT == 'zip' ]; then
- sed -e '1d' $TMPFILE | while read file; do
- # zip incorrectly stores the full path, so cd and then grow
- cd `dirname "$file"`
- zip -g "$superfile" `basename "$file"` && rm -f "$file"
- done
- cd "$OLD_PWD"
- fi
-
- echo "$superfile" >| $TMPFILE # clobber on purpose
-fi
-if [ $VERBOSE -eq 1 ]; then
- echo "done"
-fi
-
-if [ $VERBOSE -eq 1 ]; then
- echo -n "moving archive to $OUT_FILE..."
-fi
-while read file; do
- mv "$file" "$OUT_FILE"
-done < $TMPFILE
-if [ $VERBOSE -eq 1 ]; then
- echo "done"
-fi
+++ /dev/null
-"""
-Generic fabric deployment script.
-Create a fabfile.py in the project and start it with:
-
- from fnpdjango.deploy import *
-
-Then set up some env properties:
- project_name: slug-like project name
- hosts: list of target host names
- user: remote user name
- app_path: where does the app go
- services: list of tasks to run after deployment
- django_root_path (optional): path to the directory
- containing django project, relative to the
- root of the repository (defaults to '.')
- localsettings_dst_path (optional): path indicating
- where to copy the localsettings file, relative
- to django_root_path (defaults to project_name/localsettings.py)
- migrate_fake (optional): list of (app, migration) pairs to fake-migrate
- skip_collect_static (optional): if True, Django collectstatic command is not called
-"""
-from subprocess import check_output
-from os.path import abspath, dirname, exists, join
-from django.utils.crypto import get_random_string
-from fabric.api import *
-from fabric.context_managers import settings
-from fabric.contrib import files
-from fabric.tasks import Task, execute
-
-env.virtualenv = '/usr/bin/virtualenv'
-env.services = None
-
-
-@task
-def setup():
- """
- Setup all needed directories.
- """
- require('hosts', 'app_path')
-
- if not files.exists(env.app_path):
- run('mkdir -p %(app_path)s' % env, pty=True)
- with cd(env.app_path):
- for subdir in 'releases', 'packages', 'log', 'samples':
- if not files.exists(subdir):
- run('mkdir -p %s' % subdir, pty=True)
- # Install helper manage.py script into root dir.
- if not files.exists('manage.py'):
- with settings(full_django_root=get_django_root_path('current')):
- upload_sample('manage.py', where='', ext='', mode=0755)
- with cd('%(app_path)s/releases' % env):
- if not files.exists('current'):
- run('ln -sfT . current', pty=True)
- if not files.exists('previous'):
- run('ln -sfT . previous', pty=True)
-
- upload_samples()
-
-
-def check_localsettings():
- return files.exists('%(app_path)s/localsettings.py' % env)
-
-
-@task(default=True)
-def deploy():
- """
- Deploy the latest version of the site to the servers,
- install any required third party modules,
- install the virtual host and then restart the webserver
- """
- require('hosts', 'app_path')
-
- import time
- env.release = '%s_%s' % (time.strftime('%Y-%m-%dT%H%M'), check_output(['git', 'rev-parse', 'HEAD']).strip())
-
- setup()
- if not check_localsettings():
- abort('Setup is complete, but\n %(app_path)s/localsettings.py\n'
- 'is needed for actual deployment.' % env)
- upload_tar_from_git()
- copy_localsettings()
- install_requirements()
- symlink_current_release()
- migrate()
- pre_collectstatic()
- collectstatic()
- restart()
-
-@task
-def rollback():
- """
- Limited rollback capability. Simple loads the previously current
- version of the code. Rolling back again will swap between the two.
- Warning: this will almost certainly go wrong, it there were any migrations
- in the meantime!
- """
- require('hosts', 'app_path')
- with cd(env.path):
- run('mv releases/current releases/_previous;', pty=True)
- run('mv releases/previous releases/current;', pty=True)
- run('mv releases/_previous releases/previous;', pty=True)
- collectstatic()
- restart()
-
-@task
-def deploy_version(version):
- """
- Loads the specified version.
- Warning: this will almost certainly go wrong, it there were any migrations
- in the meantime!
- """
- "Specify a specific version to be made live"
- require('hosts', 'app_path')
- env.version = version
- with cd(env.path):
- run('rm releases/previous; mv releases/current releases/previous;', pty=True)
- run('ln -s %(version)s releases/current' % env, pty=True)
- collectstatic()
- restart()
-
-@task
-def restart():
- for service in env.services or ():
- execute(service)
-
-
-# =====================================================================
-# = Helpers. These are called by other functions rather than directly =
-# =====================================================================
-
-class Service(Task):
- def upload_sample(self):
- pass
-
-class DebianGunicorn(Service):
- def __init__(self, name):
- super(Task, self).__init__()
- self.name = name
-
- def run(self):
- print '>>> restart webserver using gunicorn-debian'
- sudo('gunicorn-debian restart %s' % self.name, shell=False)
-
- def upload_sample(self):
- with settings(full_django_root=get_django_root_path('current')):
- upload_sample('gunicorn')
-
-class Apache(Service):
- def run(self):
- print '>>> restart webserver by touching WSGI'
- with path('/sbin'):
- run('touch %(app_path)s/%(project_name)s/wsgi.py' % env)
-
-class Supervisord(Service):
- def __init__(self, name):
- super(Task, self).__init__()
- self.name = name
-
- def run(self):
- print '>>> supervisord: restart %s' % self.name
- sudo('supervisorctl restart %s' % self.name, shell=False)
-
-class Command(Task):
- def __init__(self, commands, working_dir):
- if not hasattr(commands, '__iter__'):
- commands = [commands]
- self.name = 'Command: %s @ %s' % (commands, working_dir)
- self.commands = commands
- self.working_dir = working_dir
-
- def run(self):
- require('app_path')
- with cd(join('%(app_path)s/releases/current' % env, self.working_dir)):
- for command in self.commands:
- run(command)
-
-def upload_samples():
- upload_localsettings_sample()
- upload_nginx_sample()
- for service in env.services:
- service.upload_sample()
-
-def upload_sample(name, where="samples/", ext='.sample', **kwargs):
- require('app_path', 'project_name')
- upload_path = '%s/%s%s%s' % (env['app_path'], where, name, ext)
- if files.exists(upload_path):
- return
- print '>>> upload %s template' % name
- template = '%(project_name)s/' % env + name + '.template'
- if not exists(template):
- template = join(dirname(abspath(__file__)), 'templates/' + name + '.template')
- files.upload_template(template, upload_path, env, **kwargs)
-
-def upload_localsettings_sample():
- "Fill out localsettings template and upload as a sample."
- env.secret_key = get_random_string(50)
- upload_sample('localsettings.py', where="")
-
-upload_nginx_sample = lambda: upload_sample('nginx')
-
-def upload_tar_from_git():
- "Create an archive from the current Git branch and upload it"
- print '>>> upload tar from git'
- require('release', provided_by=[deploy])
- require('app_path')
- local('git-archive-all.sh --format tar %(release)s.tar' % env)
- local('gzip %(release)s.tar' % env)
- run('mkdir -p %(app_path)s/releases/%(release)s' % env, pty=True)
- run('mkdir -p %(app_path)s/packages' % env, pty=True)
- put('%(release)s.tar.gz' % env, '%(app_path)s/packages/' % env)
- run('cd %(app_path)s/releases/%(release)s && tar zxf ../../packages/%(release)s.tar.gz' % env, pty=True)
- local('rm %(release)s.tar.gz' % env)
-
-def install_requirements():
- "Install the required packages from the requirements file using pip"
- print '>>> install requirements'
- require('release', provided_by=[deploy])
- require('app_path')
- if not files.exists('%(app_path)s/ve' % env):
- require('virtualenv')
- run('%(virtualenv)s %(app_path)s/ve' % env, pty=True)
- with cd('%(app_path)s/releases/%(release)s' % env):
- run('%(app_path)s/ve/bin/pip install -r requirements.txt' % env, pty=True)
- with cd(get_django_root_path(env['release'])):
- # Install DB requirement
- database_reqs = {
- 'django.db.backends.postgresql_psycopg2': 'psycopg2',
- 'django.db.backends.mysql': 'MySQL-python',
- }
- databases = run('''DJANGO_SETTINGS_MODULE=%(project_name)s.settings %(app_path)s/ve/bin/python -c 'from django.conf import settings; print " ".join(set([d["ENGINE"] for d in settings.DATABASES.values()]))' ''' % env)
- for database in databases.split():
- if database in database_reqs:
- # TODO: set pip default pypi
- run('%(app_path)s/ve/bin/pip install ' % env + database_reqs[database])
-
-
-def copy_localsettings():
- "Copy localsettings.py from root directory to release directory (if this file exists)"
- print ">>> copy localsettings"
- require('release', provided_by=[deploy])
- require('app_path', 'project_name')
-
- with settings(warn_only=True):
- copy_to = join(get_django_root_path(env['release']), env.get('localsettings_dst_path', env['project_name']))
- run('cp %(app_path)s/localsettings.py ' % env + copy_to)
-
-def symlink_current_release():
- "Symlink our current release"
- print '>>> symlink current release'
- require('release', provided_by=[deploy])
- require('app_path')
- with cd(env.app_path):
- run('rm releases/previous; mv releases/current releases/previous')
- run('ln -s %(release)s releases/current' % env)
-
-def migrate():
- "Update the database"
- print '>>> migrate'
- require('app_path', 'project_name')
- with cd(get_django_root_path('current')):
- run('%(app_path)s/ve/bin/python manage.py syncdb --noinput' % env, pty=True)
- for app, migration in env.get('migrate_fake', ()):
- run('%s/ve/bin/python manage.py migrate %s --fake %s' % (env.app_path, app, migration), pty=True)
- run('%(app_path)s/ve/bin/python manage.py migrate' % env, pty=True)
-
-def pre_collectstatic():
- print '>>> pre_collectstatic'
- for task in env.get('pre_collectstatic', []):
- execute(task)
-
-def collectstatic():
- """Collect static files"""
- print '>>> collectstatic'
- if env.get('skip_collect_static', False):
- print '... skipped'
- return
- require('app_path', 'project_name')
- with cd(get_django_root_path('current')):
- run('%(app_path)s/ve/bin/python manage.py collectstatic --noinput' % env, pty=True)
-
-
-def get_django_root_path(release):
- require('app_path')
- path = '%(app_path)s/releases/%(release)s' % dict(app_path = env['app_path'], release = release)
- if 'django_root_path' in env:
- path = join(path, env['django_root_path'])
- return path
+++ /dev/null
-CONFIG = {
- 'mode': 'wsgi',
- 'working_dir': '%(full_django_root)s',
- 'python': '%(app_path)s/ve/bin/python',
- 'user': '%(user)s',
- 'group': '%(user)s',
- 'args': (
- '--bind=unix:/tmp/gunicorn-%(project_name)s.socket',
- '--workers=1',
- '--timeout=180',
- '%(project_name)s.wsgi:application',
- '--access-logfile=%(app_path)s/log/gunicorn.log',
- '--error-logfile=%(app_path)s/log/gunicorn-error.log',
- ),
-}
+++ /dev/null
-# Review this file and copy it to %(app_path)s/localsettings.py
-
-ADMINS = (
- ('Lista IT', 'it@listy.nowoczesnapolska.org.pl'),
-)
-MANAGERS = (
- ('Lista IT', 'it@listy.nowoczesnapolska.org.pl'),
-)
-
-DATABASES = {
- 'default': {
- 'ENGINE': 'django.db.backends.postgresql_psycopg2', # Add 'postgresql_psycopg2', 'postgresql', 'mysql', 'sqlite3' or 'oracle'.
- 'NAME': '%(project_name)s', # Or path to database file if using sqlite3.
- 'USER': '%(project_name)s', # Not used with sqlite3.
- 'PASSWORD': '', # Not used with sqlite3.
- 'HOST': '', # Set to empty string for localhost. Not used with sqlite3.
- 'PORT': '', # Set to empty string for default. Not used with sqlite3.
- }
-}
-
-SECRET_KEY = '%(secret_key)s'
-ALLOWED_HOSTS = (
- '%(project_name)s.nowoczesnapolska.org.pl',
-)
-
-PIWIK_URL = '//piwik.nowoczesnapolska.org.pl/nocas/'
-PIWIK_SITE_ID = -1
-
-MEDIA_ROOT = '%(app_path)s/media/'
-STATIC_ROOT = '%(app_path)s/static/'
-
-
-# Those should be set to True if you are behind Nginx.
-FNPDJANGO_REALIP = True
-FNPDJANGO_XACCEL = True
+++ /dev/null
-#!/bin/bash
-# Simple wrapper for running current manage.py with the right Python.
-exec %(app_path)s/ve/bin/python %(full_django_root)s/manage.py "$@"
+++ /dev/null
-server {
- listen [::]:80;
- listen 80;
- server_name %(project_name)s.nowoczesnapolska.org.pl?;
- access_log %(app_path)s/log/nginx.log;
- error_log %(app_path)s/log/nginx-error.log;
-
- root %(app_path)s;
- location /media/ {
- }
- location /static/ {
- }
- location / {
- include /etc/nginx/proxy.conf;
- proxy_pass http://unix:/tmp/gunicorn-%(project_name)s.socket;
- }
-}
setup(
name='fnpdjango',
- version='0.1.19-1',
+ version='0.2',
author='Radek Czajka',
author_email='radekczajka@nowoczesnapolska.org.pl',
url = '',
packages=find_packages(),
package_data={
'fnpdjango': whole_trees('fnpdjango', ['templates', 'locale', 'static']),
- 'fnpdjango.deploy': ['templates/*.template'],
'fnpdjango.management.commands': ['babel.cfg'],
},
- scripts=[
- 'bin/git-archive-all.sh',
- 'bin/fnpdjango_bootstrap.sh',
- ],
install_requires=[
- 'django>=1.4,<1.7',
+ 'Django>=1.4,<1.7',
'textile==2.1.5',
],
license='LICENSE',