forked from I2P_Developers/i2p.www
check in docker specific wsgi file
This commit is contained in:
@ -10,6 +10,7 @@ WORKDIR /var/www/i2p.www
|
|||||||
RUN apt-get update && \
|
RUN apt-get update && \
|
||||||
apt-get -y install apache2 apache2-utils libapache2-mod-wsgi python2-dev python-pip patch python-virtualenv git && \
|
apt-get -y install apache2 apache2-utils libapache2-mod-wsgi python2-dev python-pip patch python-virtualenv git && \
|
||||||
## Start setting up the site
|
## Start setting up the site
|
||||||
|
rm -rfv env && \
|
||||||
virtualenv --distribute env && \
|
virtualenv --distribute env && \
|
||||||
. env/bin/activate && \
|
. env/bin/activate && \
|
||||||
pip install -r etc/reqs.txt && \
|
pip install -r etc/reqs.txt && \
|
||||||
@ -19,7 +20,7 @@ RUN apt-get update && \
|
|||||||
## We've now updated the site
|
## We've now updated the site
|
||||||
## Next let's configure WSGI
|
## Next let's configure WSGI
|
||||||
## Set ownership of site to server
|
## Set ownership of site to server
|
||||||
cp etc/docker.i2p.wsgi i2p.wsgi && \
|
cp etc/docker.wsgi.i2p i2p.wsgi && \
|
||||||
chown -R www-data /var/www/i2p.www && \
|
chown -R www-data /var/www/i2p.www && \
|
||||||
## Make the WSGI script owned by the server
|
## Make the WSGI script owned by the server
|
||||||
chown www-data:www-data /var/www/i2p.www/i2p.wsgi && \
|
chown www-data:www-data /var/www/i2p.www/i2p.wsgi && \
|
||||||
@ -31,7 +32,6 @@ RUN apt-get update && \
|
|||||||
a2ensite i2p && \
|
a2ensite i2p && \
|
||||||
ls /etc/apache2 && \
|
ls /etc/apache2 && \
|
||||||
sed -i 's|IncludeOptional sites-enabled|# IncludeOptional sites-enabled|g' /etc/apache2/apache2.conf && \
|
sed -i 's|IncludeOptional sites-enabled|# IncludeOptional sites-enabled|g' /etc/apache2/apache2.conf && \
|
||||||
sed -i '1 i\IncludeOptional sites-enabled/i2p.conf' /etc/apache2/apache2.conf && \
|
sed -i '1 i\IncludeOptional sites-enabled/i2p.conf' /etc/apache2/apache2.conf
|
||||||
cat /etc/apache2/apache2.conf
|
|
||||||
|
|
||||||
CMD service apache2 restart && tail -f /var/log/apache2/access.log
|
CMD service apache2 restart && tail -f /var/log/apache2/access.log
|
||||||
|
5
etc/docker.wsgi.i2p
Normal file
5
etc/docker.wsgi.i2p
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
import sys
|
||||||
|
activate_this = '/var/www/i2p.www/env/bin/activate_this.py'
|
||||||
|
execfile(activate_this, dict(__file__=activate_this))
|
||||||
|
sys.path.insert(0, '/var/www/i2p.www')
|
||||||
|
from i2p2www import app as application
|
Reference in New Issue
Block a user