source: TI03-DataExtractor/trunk/pydxc/clientConfig.py @ 794

Subversion URL: http://proj.badc.rl.ac.uk/svn/ndg/TI03-DataExtractor/trunk/pydxc/clientConfig.py@794
Revision 794, 6.2 KB checked in by astephen, 13 years ago (diff)

Unstable but latest version with multi-variable support and split hooks
for CDML and CSML.

Line 
1#   Copyright (C) 2004 CCLRC & NERC( Natural Environment Research Council ).
2#   This software may be distributed under the terms of the
3#   Q Public License, version 1.0 or later. http://ndg.nerc.ac.uk/public_docs/QPublic_license.txt
4
5"""
6clientConfig.py
7=============
8
9Holds the main configuration details that must be set up in order
10for a version of the package to run on a new machine.
11
12Each option below is documented to guide the user through setting
13up the interface.
14
15All these global variables are used in various parts of the
16package. For consistency they are all CAPITALISED.
17
18"""
19
20# Import python modules
21import os   # used to combine paths in variables below
22
23# DEBUG:
24# Set to 1 if you want to be in DEBUG mode. This reports CGI errors
25# directly to the browser.
26DEBUG=0
27
28# CALL_METHOD
29# Method used for client to communicate with the server.
30# Either "WS" for Web Service or "Local" for local machine.
31CALL_METHOD="WS"
32
33# RESTRICTED_DATA:
34# Do you want security on (1) or off (0)?
35# Note that there is no in-built security implementation in
36# dx, just a set of hooks under which your security system
37# can be called.
38RESTRICTED_DATA=0
39
40# PACKAGE_NAME:
41# This will appear as the main title displayed
42# on the web interface.
43PACKAGE_NAME="Data Extractor"
44
45# LOCAL_RULES:
46# Do you want local rules switched on or off (1 or 0)?
47# This will apply to any parts of the code where local
48# modifications have been made and wrapped in an if clause.
49LOCAL_RULES=0
50
51# REGISTRATION_PAGE:
52# For restricted datasets, this is the web page from which users
53# can find registration details.
54REGISTRATION_PAGE="http://yourhost/your_link.html"
55
56# ADMIN_MAIL_ADDRESS:
57# The e-mail address of the adminstrator for this version. 
58ADMIN_MAIL_ADDRESS="yourmail@yourhost"
59
60# LOCAL_MAIL_HOST:
61# The outgoing mail box address for the host machine.
62# On many systems you can just use "localhost".
63LOCAL_MAIL_HOST="youroutbox.yourdomain"
64
65# ADMIN_NOTIFICATION:
66# Set this to 1 if you want to be notified by e-mail when an error has
67# occurred.
68ADMIN_NOTIFICATION=0
69
70# SOAP_SERVER_PORT:
71# Port over which the Web Service will run.
72SOAP_SERVER_PORT=8406
73
74# SOAP_SERVER_NAME:
75# URL of server. If client and server running lcoally
76# you can use "localhost".
77SOAP_SERVER_NAME="localhost"
78
79# LOCAL_SERVER_PACKAGE
80# Local path to Server Package if callable locally
81LOCAL_SERVER_PACKAGE="/home/as56/abstractWebService/dxs"
82
83# MAX_NUM_DATASETS:
84# A kind of fake maximum number of datasets
85# to make the CGI client behave sensibly.
86MAX_NUM_DATASETS=2
87
88# REQUEST_XML_DIR_LOCAL_PATH:
89# Directory for request document uploads and downloads on the local machine.
90# Probably a temporary store. This directory needs to be visible from the
91# webserver (e.g. /srv/www/htdocs/dx/request_xmls).
92REQUEST_XML_DIR_LOCAL_PATH="/srv/www/htdocs/request_xmls"
93
94# REQUEST_XML_DIR_URL_PATH:
95# The URL address of the REQUEST_XML_DIR_LOCAL_PATH
96REQUEST_XML_DIR_URL_PATH="http://localhost/request_xmls"
97
98# STATIC_WEBSERVER_URL_PATH
99# HTTP location of the webserver
100STATIC_WEBSERVER_URL_PATH="http://localhost"
101
102# STATIC_WEBSERVER_LOCAL_PATH
103# Location on the local machine of the webserver top level directory,
104# i.e. the htdocs directory.
105STATIC_WEBSERVER_LOCAL_PATH="/srv/www/htdocs"
106
107# WEB_EXTRAS_URL_PATH:
108# HTTP location of the web extras directory.
109WEB_EXTRAS_URL_PATH=os.path.join(STATIC_WEBSERVER_URL_PATH, "dx_extras")
110
111# WEB_EXTRAS_LOCAL_PATH:
112# Local location of the web extras directory.
113WEB_EXTRAS_LOCAL_PATH=os.path.join(STATIC_WEBSERVER_LOCAL_PATH, "dx_extras")
114
115# CGI_SCRIPT_URL_PATH:
116# The full path of the main CGI script on your system.
117# "http://yourdomain/cgi-bin/dxui" is the most likely but
118# you are free to rename the files if you wish.
119CGI_SCRIPT_URL_PATH=os.path.join(STATIC_WEBSERVER_URL_PATH, "cgi-bin/dxui")
120
121# CGI_SCRIPT_LOCAL_PATH:
122# The local path of the CGI script on your system.
123# "/srv/www/cgi-bin/apwsui.py" is likely on a SUSE system but
124# you are free to rename this as you wish.
125CGI_SCRIPT_LOCAL_PATH="/srv/www/cgi-bin/dxui"
126
127# TOKEN_VALID_LIFETIME:
128# Period before security token (cookie) should expire (in seconds)
129TOKEN_VALID_LIFETIME=60*60*8   # 8 hours
130
131# COOKIE_NAME:
132# Name of cookie to hold security information and user roles.
133COOKIE_NAME="dx_cookie"
134
135# TOKEN_DOMAIN:
136# The domain that should be written in the secure token (cookie).
137TOKEN_DOMAIN="localhost"
138
139# BASEDIR:
140# Full path to the main client package location.
141# "/usr/local/dxc" is recommended but you can change it as
142# you wish.
143BASEDIR="/home/as56/abstractWebService/dxc"
144
145# OUTPUT_DIR_LOCAL_PATH
146# The full path on the local machine of the output directory.
147OUTPUT_DIR_LOCAL_PATH=os.path.join(STATIC_WEBSERVER_LOCAL_PATH, "output")
148
149# OUTPUT_DIR_URL_PATH:
150# The URL address of the OUTPUT_DIR_LOCAL_PATH
151OUTPUT_DIR_URL_PATH=os.path.join(STATIC_WEBSERVER_URL_PATH, "output")
152
153# HTML_DIR_LOCAL_PATH:
154# Location of the HTML header and footer files in the package
155HTML_DIR_LOCAL_PATH=os.path.join(BASEDIR, "html")
156
157# LOGO_DIR:
158# Location of logos for the header section, this should be a
159# full or relative URL and NOT a directory path on your machine.
160LOGO_DIR=os.path.join(STATIC_WEBSERVER_URL_PATH, "dx_extras/logos")
161
162# LEFT_LOGO:
163# Name of logo file for left hand side of header.
164LEFT_LOGO="dx_logo.jpg"
165
166# RIGHT_LOGO:
167# Name of logo file for right hand side of header.
168RIGHT_LOGO="dx_logo.jpg"
169
170# MESSAGE_TO_USERS:
171# A message that will be written at the top of all web pages underneath
172# the main header.
173MESSAGE_TO_USERS="""This is a test version of the %s so it may contain bugs.
174Please contact <A HREF="mailto:%s">%s</A> if an
175error occurs so that we can improve this
176service.""" % (PACKAGE_NAME, ADMIN_MAIL_ADDRESS, ADMIN_MAIL_ADDRESS)
177
178# GEOSPLAT_URL_PATH:
179# The URL of the Visualisor package that the dx connects to
180# once files have been produced.
181GEOSPLAT_URL_PATH="/cgi-bin/splatui"
182
183# CONFIRMATION_PAGE:
184# Should the CGI interface include a confirmation page?
185# 1 for yes and 0 for no.
186CONFIRMATION_PAGE=1
187
188# MAP_APPLET_URL_PATH:
189# URL of map applet HTML page
190MAP_APPLET_URL_PATH="/dx_extras/LiveMap_30/extractorMap.html"
191
Note: See TracBrowser for help on using the repository browser.