Check if Docker image exists locally
(self, image_name: str)
| 57 | return False |
| 58 | |
| 59 | def check_image_exists(self, image_name: str) -> bool: |
| 60 | """Check if Docker image exists locally""" |
| 61 | try: |
| 62 | result = RunningProcess.run( |
| 63 | ["docker", "images", "-q", image_name], |
| 64 | check=False, |
| 65 | timeout=10, |
| 66 | capture_output=True, |
| 67 | text=True, |
| 68 | ) |
| 69 | return bool(result.stdout.strip()) |
| 70 | except (RuntimeError, FileNotFoundError): |
| 71 | return False |
| 72 | |
| 73 | def pull_image(self) -> None: |
| 74 | """Pull Docker image from registry""" |
no test coverage detected