Skip to content

Commit

Permalink
Attempt to fix container search bats issue with a delay
Browse files Browse the repository at this point in the history
  • Loading branch information
ianballou committed Oct 14, 2024
1 parent 4019844 commit a63d040
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions bats/fb-katello-container.bats
Original file line number Diff line number Diff line change
Expand Up @@ -21,5 +21,9 @@ load fixtures/content
CONTAINER_PULL_LABEL=$(echo "${ORGANIZATION_LABEL}-${PRODUCT_LABEL}-${CONTAINER_REPOSITORY_LABEL}"| tr '[:upper:]' '[:lower:]')
CONTAINER_PUSH_LABEL=$(echo "${ORGANIZATION_LABEL}/${PRODUCT_LABEL}/${CONTAINER_REPOSITORY_LABEL}-bats-$(date -u '+%s')"| tr '[:upper:]' '[:lower:]')
podman push "${HOSTNAME}/${CONTAINER_PULL_LABEL}" "${HOSTNAME}/${CONTAINER_PUSH_LABEL}"
# Sleep for 5 seconds due to an intermittent issue where pushed content
# is not immediately searchable via podman search.
# See https://github.com/theforeman/forklift/pull/1864 for more information.
sleep 5
podman search "${HOSTNAME}/" | grep -q "${CONTAINER_PUSH_LABEL}"
}

0 comments on commit a63d040

Please sign in to comment.