abusesa: Added template for abusesa search Config.js

This commit is contained in:
Ossi Salmi 2013-06-14 11:25:05 +03:00
parent 6ce660a48a
commit ce80b2d874
2 changed files with 17 additions and 0 deletions

View file

@ -100,6 +100,10 @@ class abusesa::search {
}
}
if !$abusesa_search_solrurl {
fail("Must define \$abusesa_search_solrurl")
}
file { "/usr/local/src/abusesa-search.tar.gz":
ensure => present,
mode => "0644",
@ -184,6 +188,15 @@ class abusesa::search {
default => "/usr/share/abusesa-search/htdocs",
}
file { "${htdocs}/js/Config.js":
ensure => present,
mode => "0644",
owner => "root",
group => "root",
content => template("abusesa/Config.js.erb"),
require => Python::Setup::Install["/usr/local/src/abusesa-search"],
}
define configwebhost($htdocs) {
file { "/srv/www/https/${name}/search":
ensure => link,

View file

@ -0,0 +1,4 @@
var config = {
solrUrl: "<%= @abusesa_search_solrurl %>",
servlet: "admin/luke"
};