Changeset 323


Ignore:
Timestamp:
Mar 31, 2010, 8:04:08 PM (13 years ago)
Author:
duh
Message:
  • fixed the issue with deploying the production war on tomcat (searchable / compass trying to write to /dev/null). Deployment now works perfectly without errors...
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/grails-app/conf/Searchable.groovy

    r320 r323  
    3131     *
    3232     * The default is "${user.home}/.grails/projects/${app.name}/searchable-index/${grails.env}"
     33         *
     34         * Checks if user.home points to /dev/null (which happens when deploying on tomcat) and set
     35         * it to /home/tomcat if it is the case. Otherwise just use the user.home
    3336     */
    3437    compassConnection = new File(
    35         "${userHome}/.grails/projects/${appName}/searchable-index/${grailsEnv}"
     38                sprintf("%s/.grails/projects/%s/searchable-index/%s",
     39                        ((user.home == "/dev/null") ? "/home/tomcat" : user.home),
     40                        appName,
     41                        grailsEnv
     42                )
    3643    ).absolutePath
    3744
Note: See TracChangeset for help on using the changeset viewer.