parent
57f74b0d46
commit
0369a18c6e
@ -159,7 +159,7 @@ def get_app_versions(app_path):
|
||||
services_cmd = "yq e '.services | keys | .[]' compose*.yml"
|
||||
services = _run_cmd(services_cmd, shell=True).split()
|
||||
|
||||
service_versions = []
|
||||
service_versions = {}
|
||||
for service in services:
|
||||
services_cmd = f"yq e '.services.{service}.image' compose*.yml"
|
||||
images = _run_cmd(services_cmd, shell=True).split()
|
||||
@ -172,15 +172,13 @@ def get_app_versions(app_path):
|
||||
output = _run_cmd(images_cmd, shell=True)
|
||||
|
||||
service_version_info = {
|
||||
service: {
|
||||
"image": image.split(":")[0],
|
||||
"tag": image.split(":")[-1],
|
||||
"digest": output.split(":")[-1][:8],
|
||||
}
|
||||
}
|
||||
|
||||
log.info(f"Parsed {service_version_info}")
|
||||
service_versions.append(service_version_info)
|
||||
service_versions[service] = service_version_info
|
||||
|
||||
versions[tag] = service_versions
|
||||
|
||||
|
Reference in New Issue
Block a user