Guest User

Untitled

a guest
Jan 18th, 2019
81
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.25 KB | None | 0 0
  1. <VirtualHost *:80>
  2. ServerName japanesepractice.local
  3. ServerAlias www.japanesepractice.local
  4.  
  5. WSGIDaemonProcess japanesepractice user=leonardo group=leonardo threads=5
  6. WSGIScriptAlias / /var/www/japanesepractice.local/japanese.wsgi
  7. <Directory /var/www/japanesepractice.local>
  8. WSGIProcessGroup japanesepractice
  9. WSGIApplicationGroup %{GLOBAL}
  10. Order allow,deny
  11. Allow from all
  12. </Directory>
  13.  
  14. Alias /static/ /var/www/japanesepractice.local/static
  15. <Directory /var/www/japanesepractice.local/static>
  16. Order allow,deny
  17. Allow from all
  18. </Directory>
  19.  
  20. ErrorLog ${APACHE_LOG_DIR}/error.log
  21. CustomLog ${APACHE_LOG_DIR}/access.log combined
  22. </VirtualHost>
  23.  
  24. # vim: syntax=apache ts=4 sw=4 sts=4 sr noet
  25.  
  26. # -*- coding: utf-8 -*-
  27. from flask import Flask
  28. from flask import render_template
  29. from flask import request
  30.  
  31. from service import kanjiservice
  32.  
  33. app = Flask(__name__)
  34.  
  35.  
  36. @app.route('/')
  37. def homepage():
  38. return render_template('index.html')
  39.  
  40. #!/usr/bin/python2
  41.  
  42. activate_this = '/var/www/japanesepractice.local/venv/bin/activate_this.py'
  43. execfile(activate_this, dict(__file__=activate_this))
  44.  
  45. import sys
  46. sys.path.insert(0, '/var/www/japanesepractice.local')
  47.  
  48. from app import app as application
Add Comment
Please, Sign In to add comment