The following pull request was submitted through Github. It can be accessed and reviewed at: https://github.com/lxc/pylxd/pull/222
This e-mail was sent by the LXC bot, direct replies will not reach the author unless they happen to be subscribed to this list. === Description (from pull-request) === Don't sync() when stopping an ephermal container since that throws a NotFound exception.
From 5cf57c31b976c75e99338ebd11ee8c01d9b5d678 Mon Sep 17 00:00:00 2001 From: Omer Akram <om2...@gmail.com> Date: Wed, 8 Mar 2017 20:01:07 +0500 Subject: [PATCH] Fix ephermal container stop --- pylxd/models/container.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/pylxd/models/container.py b/pylxd/models/container.py index 6c59b84..35e86db 100644 --- a/pylxd/models/container.py +++ b/pylxd/models/container.py @@ -158,7 +158,10 @@ def _set_state(self, state, timeout=30, force=True, wait=False): response.json()['operation']) if 'status' in self.__dirty__: del self.__dirty__[self.__dirty__.index('status')] - self.sync() + if self.ephemeral and state == 'stop': + self.client = None + else: + self.sync() def state(self): response = self.api.state.get()
_______________________________________________ lxc-devel mailing list lxc-devel@lists.linuxcontainers.org http://lists.linuxcontainers.org/listinfo/lxc-devel