Skip to content
Snippets Groups Projects
Commit b4037861 authored by Marco Molinaro's avatar Marco Molinaro
Browse files

first vlkb.ia2 setup and port on ViaLactea group

parent 3d06210e
Branches
Tags
No related merge requests found
*.h5
......@@ -8,7 +8,7 @@ def query_out(parameters):
query1=parsequery.replace('%27', '')
query_final=unquote(query1)
table=pd.read_hdf('/sed-data/vlkb_1.h5')
table=pd.read_hdf('/sed-data/sedmodels.h5')
myquery=table.query(query_final)
return myquery
# test mod_wsgi app
def application(environ, start_response):
status = '200 OK'
output = b'Ciao Mondo!'
getstring = environ['QUERY_STRING']
output += getstring.encode('utf-8')
response_headers = [('Content-type', 'text/plain'),
('Content-Length', str(len(output)))]
start_response(status, response_headers)
return [output]
......@@ -16,10 +16,10 @@ import pandas as pd
class QueryMaker(object):
dataset=pd.read_hdf('vlkb_1.h5')
dataset=pd.read_hdf('/sed-data/sedmodels.h5')
def query_out(self, parameters):
dataset=pd.read_hdf('vlkb_1.h5')
dataset=pd.read_hdf('/sed-data/sedmodels.h5')
parsequery=parameters.replace(' ', '')
query1=parsequery.replace('%27', '')
......
......@@ -3,7 +3,7 @@ import sys
import pandas
sys.path.insert(0,"/var/www/html/")
from parquet_query import query_out
#from parquet_query import query_out
import Pyro4
def application(environ, start_response):
......
......@@ -4,14 +4,11 @@
# Configuration for various python/WSGI tests
# Basic Hello World app alias - at least this one must work
WSGIScriptAlias /myapp /var/www/wsgi-scripts/myapp.wsgi
# Plain SED models HDF5 query
WSGIScriptAlias /sedsearch /var/www/wsgi-scripts/wsgi.py
WSGIScriptAlias /search /var/www/wsgi-scripts/wsgi.py
# Daemon based SED models HDF5 query
# WSGIScriptAlias /seddeamon /var/www/wsgi-scripts/wsgid.py
WSGIScriptAlias /searchd /var/www/wsgi-scripts/wsgid.py
# Directory to deploy the python part into
<Directory /var/www/wsgi-scripts>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment