2
0
mirror of https://expo.survex.com/repositories/troggle/.git synced 2024-11-25 00:31:55 +00:00

Up to 1.6.11 on stretch. New manage.py. Some tidying

This commit is contained in:
Sam Wenham 2018-04-15 12:00:59 +01:00
parent cfa888fde6
commit 7877efba0a
8 changed files with 52 additions and 17 deletions

View File

@ -62,7 +62,7 @@ class EntranceForm(ModelForm):
CaveAndEntranceFormSet = modelformset_factory(CaveAndEntrance, exclude=('cave'))
CaveAndEntranceFormSet = modelformset_factory(CaveAndEntrance, exclude=('cave',))
class EntranceLetterForm(ModelForm):
class Meta:

View File

@ -1,6 +1,10 @@
FROM python:2.7-jessie
FROM python:2.7-stretch
RUN apt-get -y update && apt-get install -y mercurial fonts-freefont-ttf survex locales
#COPY backports.list /etc/apt/sources.list.d/
RUN apt-get -y update && apt-get install -y mercurial fonts-freefont-ttf locales survex
#RUN apt-get -y -t -backports install survex
# Set the locale
RUN locale-gen en_GB.UTF-8
@ -11,8 +15,12 @@ ENV LC_ALL en_GB.UTF-8
WORKDIR /opt/expo/troggle
COPY requirements.txt .
RUN pip install --upgrade pip
RUN pip install -r requirements.txt
EXPOSE 8000
WORKDIR /expo/troggle
#CMD ["python","manage.py","runserver","0.0.0.0:8000"]

View File

@ -0,0 +1,26 @@
FROM python:2.7-jessie
COPY backports.list /etc/apt/sources.list.d/
RUN apt-get -y update && apt-get install -y mercurial fonts-freefont-ttf locales
RUN apt-get -y -t jessie-backports install survex
# Set the locale
RUN locale-gen en_GB.UTF-8
ENV LANG en_GB.UTF-8
ENV LANGUAGE en_GB:en
ENV LC_ALL en_GB.UTF-8
WORKDIR /opt/expo/troggle
COPY requirements.txt .
RUN pip install --upgrade pip
RUN pip install -r requirements.txt
EXPOSE 8000
WORKDIR /expo/troggle
#CMD ["python","manage.py","runserver","0.0.0.0:8000"]

1
docker/backports.list Normal file
View File

@ -0,0 +1 @@
deb http://ftp.debian.org/debian jessie-backports main

View File

@ -1,4 +1,4 @@
Django==1.5.12
Django==1.6.11
django-registration==1.0
mysql
imagekit

View File

@ -0,0 +1,7 @@
Django==1.5.12
django-registration==1.0
mysql
imagekit
Image
django-tinymce==1.5.3
smartencoding

View File

@ -1,11 +1,8 @@
#!/usr/bin/env python
from django.core.management import execute_manager
try:
import settings # Assumed to be in the same directory.
except ImportError:
import sys
sys.stderr.write("Error: Can't find the file 'settings.py' in the directory containing %r. It appears you've customized things.\nYou'll have to run django-admin.py, passing it your settings module.\n(If the file settings.py does indeed exist, it's causing an ImportError somehow.)\n" % __file__)
sys.exit(1)
import os, sys
if __name__ == "__main__":
execute_manager(settings)
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "settings")
from django.core.management import execute_from_command_line
execute_from_command_line(sys.argv)

View File

@ -298,7 +298,3 @@ def LoadTunnelFiles():
for tunnelfile in TunnelFile.objects.all():
SetTunnelfileInfo(tunnelfile)