From 6b9fcdb019330fb14537986bfb3d800f7bf916eb Mon Sep 17 00:00:00 2001 From: DavidWein94 Date: Mon, 3 Sep 2018 21:05:34 +0200 Subject: [PATCH] fix(images): only shows active images now (#68) --- .../VirtualMachineHandler.py | 2 +- test/keys/server.pem | 50 ------------------- 2 files changed, 1 insertion(+), 51 deletions(-) delete mode 100644 test/keys/server.pem diff --git a/gen-py/VirtualMachineService/VirtualMachineHandler.py b/gen-py/VirtualMachineService/VirtualMachineHandler.py index 8c2620e5..bbacf0ed 100644 --- a/gen-py/VirtualMachineService/VirtualMachineHandler.py +++ b/gen-py/VirtualMachineService/VirtualMachineHandler.py @@ -128,7 +128,7 @@ def get_Images(self): self.logger.info("Get Images") images = list() try: - for img in filter(lambda x: 'tags' in x and len(x['tags']) > 0, self.conn.list_images()): + for img in filter(lambda x: 'tags' in x and len(x['tags']) > 0 and x['status'] == 'active', self.conn.list_images()): metadata = img['metadata'] description = metadata.get('description') diff --git a/test/keys/server.pem b/test/keys/server.pem deleted file mode 100644 index 2ed184ee..00000000 --- a/test/keys/server.pem +++ /dev/null @@ -1,50 +0,0 @@ ------BEGIN CERTIFICATE----- -MIIDjTCCAnWgAwIBAgIJANZFDWlUezpUMA0GCSqGSIb3DQEBCwUAMF0xCzAJBgNV -BAYTAkFVMRMwEQYDVQQIDApTb21lLVN0YXRlMSEwHwYDVQQKDBhJbnRlcm5ldCBX -aWRnaXRzIFB0eSBMdGQxFjAUBgNVBAMMDXBvcnRhbC1jbGllbnQwHhcNMTgwNDA5 -MTUxMTI1WhcNMjYwNjI2MTUxMTI1WjBdMQswCQYDVQQGEwJBVTETMBEGA1UECAwK -U29tZS1TdGF0ZTEhMB8GA1UECgwYSW50ZXJuZXQgV2lkZ2l0cyBQdHkgTHRkMRYw -FAYDVQQDDA1wb3J0YWwtY2xpZW50MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIB -CgKCAQEA2qfTZNfiaBqTHf/anS+n8MyWGJLQd0xqy+yjsdhZV1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