Skip to content

Commit

Permalink
t
Browse files Browse the repository at this point in the history
  • Loading branch information
pna-nca committed Aug 2, 2024
1 parent 98f084c commit cef0bd5
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions dojo/tools/trivy_operator/parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -62,11 +62,10 @@ def handle_resource(self, data, test):
container_name = labels.get("trivy-operator.container.name", "")

endpoints = []
resource_endpoint = Endpoint(
endpoints.append(Endpoint(
host=resource_namespace,
path=f"{resource_kind}/{resource_name}/{container_name}"
)
endpoints += resource_endpoint
))

if report.get("registry"):
if report.get("artifact"):
Expand All @@ -79,11 +78,10 @@ def handle_resource(self, data, test):
# endpoint broken, although, this is a desired value. Thus,
# we abuse 'path' field for that.
artifact_name = repository.split("/")[-1]
artifact_endpoint = Endpoint(
endpoints.append(Endpoint(
host=f"{artifact_name}",
path=f"{registry}/{repository}:{tag}"
)
endpoints += artifact_endpoint
))

service = ""

Expand Down

0 comments on commit cef0bd5

Please sign in to comment.