-
Notifications
You must be signed in to change notification settings - Fork 8
/
MongodbConsoleGrailsPlugin.groovy
35 lines (29 loc) · 1.17 KB
/
MongodbConsoleGrailsPlugin.groovy
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
import com.gmongo.GMongo
import org.grails.plugin.mongodb.console.services.MongoViewerService
class MongodbConsoleGrailsPlugin {
def version = "0.1"
def grailsVersion = "2.0 > *"
def pluginExcludes = [
"web-app/images/gh/*"
]
def loadAfter = ['mongodb']
def title = "MongoDB Console Grails Plugin"
def author = "Manuarii Stein"
def authorEmail = "[email protected]"
def description = 'A web GUI for mongodb as a grails plugin.'
def documentation = "http://grails.org/plugin/mongodb-console"
def license = "APACHE"
def developers = [ [ name: "Damien Vitrac", email: "[email protected]" ]]
def issueManagement = [system: "JIRA", url: "https://github.com/mstein/grails-mongodb-console/issues"]
def scm = [url: "https://github.com/mstein/grails-mongodb-console"]
def doWithSpring = {
// If the official mongodb plugin is installed, it uses the configured GMongo bean, otherwise, create
// a new one
if(!manager.hasGrailsPlugin('mongodb')) {
mongo(GMongo, 'localhost', 27017)
}
mongoViewerService(MongoViewerService) {
mongo = ref('mongo')
}
}
}