diff --git a/surveil/api/handlers/status/live_host_handler.py b/surveil/api/handlers/status/live_host_handler.py index 3de6cfd..17107d7 100644 --- a/surveil/api/handlers/status/live_host_handler.py +++ b/surveil/api/handlers/status/live_host_handler.py @@ -26,7 +26,7 @@ class HostHandler(handler.Handler): def get(self, host_name): """Return a host.""" - mongo_s = self.request.mongo_connection.shinken_live.hosts.find_one( + mongo_s = self.request.mongo_connection.alignak_live.hosts.find_one( {"host_name": host_name} ) @@ -46,10 +46,10 @@ class HostHandler(handler.Handler): if fields != {}: mongo_dicts = (self.request.mongo_connection. - shinken_live.hosts.find(query, fields)) + alignak_live.hosts.find(query, fields)) else: mongo_dicts = (self.request.mongo_connection. - shinken_live.hosts.find(query)) + alignak_live.hosts.find(query)) host_dicts = [ _host_dict_from_mongo_item(s) for s in mongo_dicts @@ -112,4 +112,4 @@ def _host_dict_from_mongo_item(mongo_item): if value is not None: mongo_item[field[1]] = field[2](value) - return mongo_item \ No newline at end of file + return mongo_item diff --git a/surveil/api/handlers/status/live_service_handler.py b/surveil/api/handlers/status/live_service_handler.py index e8efe9d..51641ba 100644 --- a/surveil/api/handlers/status/live_service_handler.py +++ b/surveil/api/handlers/status/live_service_handler.py @@ -26,7 +26,7 @@ class ServiceHandler(handler.Handler): def get(self, host_name, service_description): """Return a specific service.""" - mongo_s = self.request.mongo_connection.shinken_live.services.find_one( + mongo_s = self.request.mongo_connection.alignak_live.services.find_one( {"host_name": host_name, "service_description": service_description}, ) @@ -46,10 +46,10 @@ class ServiceHandler(handler.Handler): if fields != {}: mongo_dicts = (self.request.mongo_connection. - shinken_live.services.find(query, fields)) + alignak_live.services.find(query, fields)) else: mongo_dicts = (self.request.mongo_connection. - shinken_live.services.find(query)) + alignak_live.services.find(query)) service_dicts = [ _service_dict_from_mongo_item(s) for s in mongo_dicts diff --git a/surveil/tests/api/controllers/v2/status/test_hosts.py b/surveil/tests/api/controllers/v2/status/test_hosts.py index 7c4112d..522f6ba 100644 --- a/surveil/tests/api/controllers/v2/status/test_hosts.py +++ b/surveil/tests/api/controllers/v2/status/test_hosts.py @@ -72,7 +72,7 @@ class TestStatusHosts(functionalTest.FunctionalTest): "services": [], }, ] - self.mongoconnection.shinken_live.hosts.insert( + self.mongoconnection.alignak_live.hosts.insert( copy.deepcopy(self.host) ) @@ -99,7 +99,7 @@ class TestStatusHosts(functionalTest.FunctionalTest): }, ] - self.mongoconnection.shinken_live.services.insert( + self.mongoconnection.alignak_live.services.insert( copy.deepcopy(self.services) ) diff --git a/surveil/tests/api/controllers/v2/status/test_services.py b/surveil/tests/api/controllers/v2/status/test_services.py index be5d190..aac02c1 100644 --- a/surveil/tests/api/controllers/v2/status/test_services.py +++ b/surveil/tests/api/controllers/v2/status/test_services.py @@ -46,7 +46,7 @@ class TestStatusServices(functionalTest.FunctionalTest): "problem_has_been_acknowledged": False, }, ] - self.mongoconnection.shinken_live.services.insert( + self.mongoconnection.alignak_live.services.insert( copy.deepcopy(self.services) ) diff --git a/tools/docker/alignak_container/Dockerfile b/tools/docker/alignak_container/Dockerfile index 0f8f9d4..3f2c727 100644 --- a/tools/docker/alignak_container/Dockerfile +++ b/tools/docker/alignak_container/Dockerfile @@ -56,7 +56,7 @@ RUN cd /tmp && \ # mod-mongo-live-config RUN cd /tmp && \ - wget -O mod-mongo-live-config.tar.gz https://github.com/savoirfairelinux/mod-mongo-live-config/archive/0.3.0.tar.gz && \ + wget -O mod-mongo-live-config.tar.gz https://github.com/savoirfairelinux/mod-mongo-live-config/archive/0.3.2.tar.gz && \ tar -zxvf mod-mongo-live-config.tar.gz && \ mv /tmp/mod-mongo-live-config-*/mod_mongo_live_config /var/lib/alignak/modules/mod_mongo_live_config && \ rm -rfv /tmp/mod-mongo-live-config*