rename
This commit is contained in:
parent
4aaf03c4e9
commit
47720f49ee
9 changed files with 38 additions and 37 deletions
19
README
19
README
|
@ -1,26 +1,25 @@
|
|||
pdfvideo - share pdfs with video overlays
|
||||
videopdf - share pdfs with video overlays
|
||||
|
||||
Get:
|
||||
cd /srv
|
||||
bzr branch http://code.0x2620.org/pdfvideo
|
||||
cd pdfvideo
|
||||
bzr branch http://code.0x2620.org/videopdf
|
||||
cd videopdf
|
||||
virtualenv --system-site-packages .
|
||||
. bin/activate
|
||||
pip install -r requirements.txt
|
||||
|
||||
Develop:
|
||||
|
||||
cd /srv/pdfvideo
|
||||
create pdfvideo/local_settings.py
|
||||
cd /srv/videopdf
|
||||
./manage.py runserver
|
||||
|
||||
Deploy:
|
||||
|
||||
cd /srv/pdfvideo
|
||||
create pdfvideo/local_settings.py
|
||||
cd /srv/videopdf
|
||||
|
||||
create /etc/apache2/sites-availavle/sitename.conf
|
||||
create /etc/init/pdfvideo.conf
|
||||
# create videopdf/local_settings.py with your database settings
|
||||
# create /etc/apache2/sites-availavle/sitename.conf (use etc/apache2/videopdf.conf as template)
|
||||
#create /etc/init/videopdf.conf (ues etc/init/videopdf.conf as template)
|
||||
|
||||
service pdfvideo start
|
||||
service videopdf start
|
||||
|
||||
|
|
|
@ -2,13 +2,13 @@
|
|||
ServerName pdf.0x2620.org
|
||||
|
||||
LogLevel warn
|
||||
ErrorLog /var/log/apache2/pdfvideo.org_error.log
|
||||
CustomLog /var/log/apache2/pdfvideo.org_access.log combined
|
||||
ErrorLog /var/log/apache2/videopdf.org_error.log
|
||||
CustomLog /var/log/apache2/videopdf.org_access.log combined
|
||||
|
||||
<Location />
|
||||
Options -Indexes
|
||||
</Location>
|
||||
<Directory /srv/pdfvideo>
|
||||
<Directory /srv/videopdf>
|
||||
Order deny,allow
|
||||
Allow from all
|
||||
</Directory>
|
||||
|
@ -18,13 +18,13 @@
|
|||
XSendFileAllowAbove on
|
||||
</Location>
|
||||
|
||||
Alias /.bzr /srv/pdfvideo/.bzr
|
||||
Alias /static/admin /srv/pdfvideo/src/django/django/contrib/admin/static/admin
|
||||
Alias /static /srv/pdfvideo/static
|
||||
Alias /robots.txt /srv/pdfvideo/pdfvideo/static/robots.txt
|
||||
Alias /favicon.ico /srv/pdfvideo/pdfvideo/static/favicon.ico
|
||||
Alias /data /srv/pdfvideo/data
|
||||
Alias /admin/media /srv/pdfvideo/src/django/django/contrib/admin/media
|
||||
Alias /.bzr /srv/videopdf/.bzr
|
||||
Alias /static/admin /srv/videopdf/src/django/django/contrib/admin/static/admin
|
||||
Alias /static /srv/videopdf/static
|
||||
Alias /robots.txt /srv/videopdf/videopdf/static/robots.txt
|
||||
Alias /favicon.ico /srv/videopdf/videopdf/static/favicon.ico
|
||||
Alias /data /srv/videopdf/data
|
||||
Alias /admin/media /srv/videopdf/src/django/django/contrib/admin/media
|
||||
|
||||
ProxyPass /static !
|
||||
ProxyPass /favicon.ico !
|
|
@ -1,21 +1,21 @@
|
|||
# pdfvideo gunicorn daemon
|
||||
# videopdf gunicorn daemon
|
||||
#
|
||||
|
||||
description "pdfvideo daemon"
|
||||
description "videopdf daemon"
|
||||
|
||||
start on runlevel [2345]
|
||||
stop on runlevel [!2345]
|
||||
kill timeout 5
|
||||
respawn
|
||||
|
||||
env NAME=pdfvideo
|
||||
env VENV=/srv/pdfvideo
|
||||
env DAEMON_USER=pdfvideo
|
||||
env HOME=/home/pdfvideo
|
||||
env NAME=videopdf
|
||||
env VENV=/srv/videopdf
|
||||
env DAEMON_USER=videopdf
|
||||
env HOME=/home/videopdf
|
||||
|
||||
script
|
||||
test -e /var/log/$NAME || (mkdir -p /var/log/pdfvideo && chown $DAEMON_USER:$DAEMON_USER /var/log/$NAME)
|
||||
cd $VENV/pdfvideo
|
||||
test -e /var/log/$NAME || (mkdir -p /var/log/videopdf && chown $DAEMON_USER:$DAEMON_USER /var/log/$NAME)
|
||||
cd $VENV/videopdf
|
||||
exec /usr/bin/sudo -u $DAEMON_USER $VENV/bin/gunicorn_django \
|
||||
--bind 127.0.0.1:2688 \
|
||||
--timeout 90 \
|
|
@ -3,7 +3,7 @@ import os
|
|||
import sys
|
||||
|
||||
if __name__ == "__main__":
|
||||
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "pdfvideo.settings")
|
||||
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "videopdf.settings")
|
||||
|
||||
from django.core.management import execute_from_command_line
|
||||
|
||||
|
|
|
@ -1232,7 +1232,9 @@ var PDFView = {
|
|||
var zoom = store.get('zoom', PDFView.currentScale);
|
||||
var left = store.get('scrollLeft', '0');
|
||||
var top = store.get('scrollTop', '0');
|
||||
|
||||
if(document.location.hash) {
|
||||
page = document.location.hash.substring(1);
|
||||
}
|
||||
storedHash = 'page=' + page + '&zoom=' + zoom + ',' + left + ',' + top;
|
||||
}
|
||||
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
# Django settings for pdfvideo project.
|
||||
# Django settings for videopdf project.
|
||||
import os
|
||||
from os.path import join,dirname,normpath
|
||||
|
||||
|
@ -101,10 +101,10 @@ MIDDLEWARE_CLASSES = (
|
|||
# 'django.middleware.clickjacking.XFrameOptionsMiddleware',
|
||||
)
|
||||
|
||||
ROOT_URLCONF = 'pdfvideo.urls'
|
||||
ROOT_URLCONF = 'videopdf.urls'
|
||||
|
||||
# Python dotted path to the WSGI application used by Django's runserver.
|
||||
WSGI_APPLICATION = 'pdfvideo.wsgi.application'
|
||||
WSGI_APPLICATION = 'videopdf.wsgi.application'
|
||||
|
||||
TEMPLATE_DIRS = (
|
||||
join(PROJECT_ROOT, 'templates')
|
|
@ -10,8 +10,8 @@ admin.autodiscover()
|
|||
|
||||
urlpatterns = patterns('',
|
||||
# Examples:
|
||||
# url(r'^$', 'pdfvideo.views.home', name='home'),
|
||||
# url(r'^pdfvideo/', include('pdfvideo.foo.urls')),
|
||||
# url(r'^$', 'videopdf.views.home', name='home'),
|
||||
# url(r'^videopdf/', include('videopdf.foo.urls')),
|
||||
|
||||
# Uncomment the admin/doc line below to enable admin documentation:
|
||||
url(r'^admin/doc/', include('django.contrib.admindocs.urls')),
|
|
@ -1,5 +1,5 @@
|
|||
"""
|
||||
WSGI config for pdfvideo project.
|
||||
WSGI config for videopdf project.
|
||||
|
||||
This module contains the WSGI application used by Django's development server
|
||||
and any production WSGI deployments. It should expose a module-level variable
|
||||
|
@ -15,7 +15,7 @@ framework.
|
|||
"""
|
||||
import os
|
||||
|
||||
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "pdfvideo.settings")
|
||||
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "videopdf.settings")
|
||||
|
||||
# This application object is used by any WSGI server configured to use this
|
||||
# file. This includes Django's development server, if the WSGI_APPLICATION
|
Loading…
Reference in a new issue