From a7166208b7cdd988590bd1e3b1c1f1453d29d1e1 Mon Sep 17 00:00:00 2001 From: Mathieu Bultel Date: Tue, 7 Nov 2017 16:51:11 +0100 Subject: [PATCH] Do not failed update if no container registry is set When the init minor update step is run without any container registry file, the cli should not raise an exception. We should accept to run it, even if the container won't be update. It could be usefull for only run package update on the env. Change-Id: I73d86d1ec61b9bb6d5f4a5ea8a9bc545ac963420 Closes-Bug: #1730687 --- tripleoclient/v1/overcloud_update.py | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/tripleoclient/v1/overcloud_update.py b/tripleoclient/v1/overcloud_update.py index 09c39db1b..b9202b9d9 100644 --- a/tripleoclient/v1/overcloud_update.py +++ b/tripleoclient/v1/overcloud_update.py @@ -101,9 +101,13 @@ class UpdateOvercloud(command.Command): with open(os.path.abspath(container_registry)) as content: registry = yaml.load(content.read()) else: - raise exceptions.InvalidConfiguration( - "You need to provide a container registry file in order " - "to update your current containers deployed.") + self.log.warning( + "You have not provided a container registry file. Note " + "that none of the containers on your environement will be " + "updated. If you want to update your container you have " + "to re-run this command and provide the registry file " + "with: --container-registry-file option.") + registry = None # Execute minor update package_update.update(clients, container=stack_name, container_registry=registry,