From fcba81c3a48ebfad7e48b267ab2ba2a18be72542 Mon Sep 17 00:00:00 2001 From: jeb228 Date: Wed, 3 Feb 2010 15:10:24 +0000 Subject: [PATCH] NIHVIVO-15 Adjust to the changes in the Vitro configuration properties files. --- build.xml | 18 +----- config/LuceneSetup.properties.template | 11 ---- config/build.properties | 10 +--- config/connection.properties.template | 80 -------------------------- config/upload.properties.template | 26 --------- config/vitrodeploy.properties.template | 45 +++++++++++++++ 6 files changed, 51 insertions(+), 139 deletions(-) delete mode 100644 config/LuceneSetup.properties.template delete mode 100644 config/connection.properties.template delete mode 100644 config/upload.properties.template create mode 100644 config/vitrodeploy.properties.template diff --git a/build.xml b/build.xml index 2beb1a0f..62d1a8b7 100644 --- a/build.xml +++ b/build.xml @@ -94,7 +94,7 @@ deploy -- Rssembles the VIVO application and deploys it to the "webapps" + files="${globalbuild.properties.file},${vitrodeploy.properties.file},${vitroUsers.owl.file}" /> - - - - - - - - - - - - - diff --git a/config/LuceneSetup.properties.template b/config/LuceneSetup.properties.template deleted file mode 100644 index 5ac3a897..00000000 --- a/config/LuceneSetup.properties.template +++ /dev/null @@ -1,11 +0,0 @@ -#this is an example of what needs to be in this -#file to setup the lucene index directory -# -# The default location is /usr/local/lucene/vitrodefault - -#You could hard code the location like this: -#LuceneSetup.indexDir=/usr/local/lucene/example - -#this line will be setup by ant to work for clones -#if you hardcode the dir, this line should be commented out -LuceneSetup.indexDir=${deploy.LuceneSetup.indexDir} diff --git a/config/build.properties b/config/build.properties index bb330e7c..6cf14add 100644 --- a/config/build.properties +++ b/config/build.properties @@ -6,18 +6,14 @@ deploy.staging.dir = .deployStaging # # Setting up the config properties. # -deploy.properties.file = deploy.properties +deploy.properties.file = deploy.properties globalbuild.template.file = config/globalbuild.properties.template -connection.template.file = config/connection.properties.template -upload.template.file = config/upload.properties.template -lucene.template.file = config/LuceneSetup.properties.template +vitrodeploy.template.file = config/vitrodeploy.properties.template vitroUsers.template.file = config/vitroUsers.owl.template globalbuild.properties.file = ${deploy.staging.dir}/config/globalbuild.properties -connection.properties.file = ${deploy.staging.dir}/webapp/config/connection.properties -upload.properties.file = ${deploy.staging.dir}/webapp/config/upload.properties -lucene.properties.file = ${deploy.staging.dir}/webapp/config/LuceneSetup.properties +vitrodeploy.properties.file = ${deploy.staging.dir}/webapp/config/deploy.properties vitroUsers.owl.file = ${deploy.staging.dir}/webapp/ontologies/auth/vitroUsers.owl # diff --git a/config/connection.properties.template b/config/connection.properties.template deleted file mode 100644 index 026197db..00000000 --- a/config/connection.properties.template +++ /dev/null @@ -1,80 +0,0 @@ -################################################################################ -# DataSource properties file -################################################################################ - -######################### DataSource Properties ################################ - -VitroConnection.DataSource.url=${deploy.VitroConnection.DataSource.url} -VitroConnection.DataSource.username=${deploy.VitroConnection.DataSource.username} -VitroConnection.DataSource.password=${deploy.VitroConnection.DataSource.password} - -####################### Other Important Properties ############################# - -# CHANGE the following property unless you're using Cornell's VIVO ontology -Vitro.defaultNamespace=${deploy.Vitro.defaultNamespace} - -# Uncomment this next line and specify an SMTP host to activate the Contact Us form -#Vitro.smtpHost= - -################################################################################ - - - - - - - - - - - - - -# maximum number of connections to the db server -# This must not be greater than the mysql max_connection parameter. -# defaults to 40 -#VitroConnection.DataSource.MaxActive=40 - -# maximum number of connections to the db server to keep -# around when nothing is happening. -# defaults to 10 -#VitroConnection.DataSource.MaxIdle=10 - -# Time to wait in msec for a result from the sql server -# defaults to 10000 -#VitroConnection.DataSource.MaxWait=10000 - -# query to use to test to see if a connection to the db server is live. -# defaults to SELECT 1 -#VitroConnection.DataSource.ValidationQuery=SELECT 1 - -# should the connection pool test the connections it gets from the pool? -#defaults to true -#VitroConnection.DataSource.TestOnBorrow=true - -# should the connection pool test connections it puts back in pool? -#defaults to true -#VitroConnection.DataSource.TestOnReturn=true - -# Nnumber of milliseconds to sleep between runs of the idle object -# evictor thread. When non-positive, no idle object evictor thread will -# be run. defaults to 30min -#VitroConnection.DataSource.TimeBetweenEvictions= - -# The number of objects to examine during each -# run of the idle object evictor thread (if any). -# defaults to 3 -#VitroConnection.DataSource.TestsPerEviction=3 - -# The minimum amount of time -# an object may sit idle in the pool before it is eligable for eviction -# by the idle object evictor (if any). -# defaults to 30min -#VitroConnection.DataSource.MinEvictionIdleTime= - -################################################ # other notes: -# The file checked into source control is example.connection.properties so -# that if you have a connection.properties on your machine it will not be -# under source control. This is useful so that your customizations for your -# database setup are less likely to be checked into source control and then -# overwrite other folks' customizations. diff --git a/config/upload.properties.template b/config/upload.properties.template deleted file mode 100644 index 0b8cf3ee..00000000 --- a/config/upload.properties.template +++ /dev/null @@ -1,26 +0,0 @@ -# The UploadImagesServlet will upload the images to a directory -# that is under tomcat and serve them from there. -# This causes a problem when the tomcat/webapps dir is deleted -# or deployed because you will lose all the images that the -# curators have uploaded. We deal with this by copying -# the files to another directory, one that is under version control. - -# This property indicates which non-tomcat directory to save the images in. -# ${uploadDir} is defined in the main build.xml via the following statements: -# -# -# -# -# -# But, this value will be replaced by the Vitro/clones/build.xml -# to point to the clones/{clone}/modifications directory based on the following -# -# -# -# -# The UploadImagesServlet.getSourceDirName() method then looks at this parameter -# in the upload.properties file, which file is stuck by the clones/build.xml file -# into the clone's modifications/WEB-INF/classes directory: -UploadImagesServlet.sourceDirName=${deploy.upload.directory} - - diff --git a/config/vitrodeploy.properties.template b/config/vitrodeploy.properties.template new file mode 100644 index 00000000..c6bb81ae --- /dev/null +++ b/config/vitrodeploy.properties.template @@ -0,0 +1,45 @@ +# ----------------------------------------------------------------------------- +# +# Vitro deployment properties +# +# This file exists as a template in the vivoweb distribution. The property +# values are substituted in by the build script. +# +# ----------------------------------------------------------------------------- + +# +# The location where the VIVO application will store uploaded files +# (usually images). You should arrange for these files to be backed up in some +# way. +# +UploadImagesServlet.sourceDirName = ${deploy.upload.directory} + +# +# The location where the VIVO application will create its Lucene search +# index. +# +LuceneSetup.indexDir = ${deploy.LuceneSetup.indexDir} + +# +# This namespace will be used when generating URIs for objects created in the +# editor. Change it to reflect your own domain. For example, Cornell's +# namespace is http://vivo.cornell.edu/individual/ +# +# Note: it is essential that this namespace end with a trailing slash. +# +Vitro.defaultNamespace = ${deploy.Vitro.defaultNamespace} + +# +# SMTP host which the "Contact Us" form can use to send mail. If this is left +# empty, the "Contact Us" form will be disabled. +# +Vitro.smtpHost = + +# +# The basic parameters for a MySQL database connection. Change the end of the +# URL to reflect your database name (if it is not "vitro"). Change the username +# and password to match the authorized user you created in MySQL. +# +VitroConnection.DataSource.url = ${deploy.VitroConnection.DataSource.url} +VitroConnection.DataSource.username = ${deploy.VitroConnection.DataSource.username} +VitroConnection.DataSource.password = ${deploy.VitroConnection.DataSource.password}