MCPcopy Create free account
hub / github.com/OWASP/Python-Honeypot / remove_old_images

Function remove_old_images

core/load.py:190–204  ·  view source on GitHub ↗

remove old images based on user configuration Args: configuration: user final configuration Returns: True

(configuration)

Source from the content-addressed store, hash-verified

188
189
190def remove_old_images(configuration):
191 """
192 remove old images based on user configuration
193
194 Args:
195 configuration: user final configuration
196
197 Returns:
198 True
199 """
200 for image in all_existing_images():
201 if image in get_image_name_of_selected_modules(configuration):
202 info(messages["removing_image"].format(image))
203 os.popen("docker rmi {0}".format(image)).read()
204 return True
205
206
207def create_new_images(configuration):

Callers 1

load_honeypot_engineFunction · 0.85

Calls 3

infoFunction · 0.90
all_existing_imagesFunction · 0.85

Tested by

no test coverage detected