aboutsummaryrefslogtreecommitdiff
path: root/etc/default_settings.py
diff options
context:
space:
mode:
authorPjotr Prins2017-05-21 07:21:44 +0000
committerPjotr Prins2017-05-21 07:21:44 +0000
commit8677d1b7bd5b32791c440bf0de2fc4c61c98299f (patch)
treed5f46ddc75bb6a7b4135147cc1c25a1cfa64a871 /etc/default_settings.py
parent02ce39e33fd32b68411ac7b30449507c3f567192 (diff)
downloadgenenetwork2-8677d1b7bd5b32791c440bf0de2fc4c61c98299f.tar.gz
Merge from the diet branch.
* refactored ./bin/genenetwork2 and /etc/default_settings - better detection of Guix - removed unused parameters, such as GEMMA_RESULT_PATH and TEMP_TRAITS - removing some default settings, such as PYLMM_COMMAND - rename some settings, such as SQL_URI and LOG_SQL_ALCHEMY - added GUIX_JS_PATH for JS modules * Added documentation on installing binary GN2 * Updated Twitter board to latest version in Guix - it had broken * Updated many tools in the latest Guix profile
Diffstat (limited to 'etc/default_settings.py')
-rw-r--r--etc/default_settings.py33
1 files changed, 17 insertions, 16 deletions
diff --git a/etc/default_settings.py b/etc/default_settings.py
index 6acea637..4f3a6f5c 100644
--- a/etc/default_settings.py
+++ b/etc/default_settings.py
@@ -9,6 +9,8 @@
# env LOG_SQL=True USE_REDIS=False ./bin/genenetwork2
# env LOG_LEVEL=DEBUG ./bin/genenetwork2 ~/gn2_settings.py
#
+# Typically you need to set GN2_PROFILE too.
+#
# Note also that in the near future we will additionally fetch
# settings from a JSON file
#
@@ -18,10 +20,9 @@
import os
import sys
-GN_VERSION = open("../VERSION","r").read()
+GN_VERSION = open("../etc/VERSION","r").read()
SQL_URI = "mysql://gn2:mysql_password@localhost/db_webqtl_s"
-SQLALCHEMY_DATABASE_URI = 'mysql://gn2:mysql_password@localhost/db_webqtl_s'
-SQLALCHEMY_POOL_RECYCLE = 3600
+SQL_ALCHEMY_POOL_RECYCLE = 3600
GN_SERVER_URL = "http://localhost:8880/"
# ---- Flask configuration (see website)
@@ -45,24 +46,24 @@ WEBSERVER_DEPLOY = None # Deployment specifics (nyi)
LOG_LEVEL = 'WARNING' # Logger mode (DEBUG|INFO|WARNING|ERROR|CRITICAL)
LOG_LEVEL_DEBUG = '0' # logger.debugf log level (0-5, 5 = show all)
LOG_SQL = 'False' # Log SQL/backend and GN_SERVER calls
-LOG_SQLALCHEMY = 'False'
+LOG_SQL_ALCHEMY = 'False'
LOG_BENCH = True # Log bench marks
USE_REDIS = True # REDIS caching (note that redis will be phased out)
USE_GN_SERVER = 'False' # Use GN_SERVER SQL calls
+HOME = os.environ['HOME']
-# Paths to JS libraries
-
-TWITTER_POST_FETCHER_JS_PATH = os.environ['HOME']+"/genenetwork/Twitter-Post-Fetcher"
+# ---- Path overrides for Genenetwork - the defaults are normally
+# picked up from Guix or in the HOME directory
-# ---- Path overrides for Genenetwork
# TMPDIR is normally picked up from the environment
-HOME=os.environ['HOME']
-LOGFILE = HOME+"/genenetwork2.log"
-GENENETWORK_FILES = HOME+"/gn2_data" # base dir for all static data files
-LOCAL_PRIVATE_FILES = HOME+"/gn2_private_data" # private static data files
+# GENENETWORK_FILES = HOME+"/gn2_data" # base dir for all static data files
+# PRIVATE_FILES = HOME+"/gn2_private_data" # private static data files (unused)
+
+# ---- Local path to JS libraries - for development modules (only)
+# GN2_JS_PATH = os.environ['HOME']+"/genenetwork/javascript" (unused)
-# ---- GN2 Executables
-PYLMM_COMMAND = str.strip(os.popen("which pylmm_redis").read())
-PLINK_COMMAND = str.strip(os.popen("which plink2").read())
-GEMMA_COMMAND = str.strip(os.popen("which gemma").read())
+# ---- GN2 Executables (overwrite for testing only)
+# PYLMM_COMMAND = str.strip(os.popen("which pylmm_redis").read())
+# PLINK_COMMAND = str.strip(os.popen("which plink2").read())
+# GEMMA_COMMAND = str.strip(os.popen("which gemma").read())