serverconfig: only add importer when index available

Change-Id: I1142afd0bfa1cf581641b4cd4dac1c9e76e6671a
This commit is contained in:
Andrew Gerrand 2014-07-05 08:25:28 +10:00
parent a4cb591707
commit 594328e21c
2 changed files with 5 additions and 7 deletions

View File

@ -435,9 +435,11 @@ func genLowLevelPrefixes(params *configPrefixesParams, ownerName string) (m json
"handler": "status",
}
importerArgs := map[string]interface{}{}
m["/importer/"] = map[string]interface{}{
"handler": "importer",
"handlerArgs": importerArgs,
if haveIndex {
m["/importer/"] = map[string]interface{}{
"handler": "importer",
"handlerArgs": importerArgs,
}
}
if params.shareHandlerPath != "" {

View File

@ -23,10 +23,6 @@
"path": "/tmp/blobs/cache"
}
},
"/importer/": {
"handler": "importer",
"handlerArgs": {}
},
"/setup/": {
"handler": "setup"
},