diff --git a/.github/workflows/gcloud-logging.yml b/.github/workflows/gcloud-logging.yml index 7f7d313..d30041c 100644 --- a/.github/workflows/gcloud-logging.yml +++ b/.github/workflows/gcloud-logging.yml @@ -58,8 +58,8 @@ jobs: # sleep 10s to give enough time for log message to be centralized in aggregate logging. run: |- sleep 10s - gcloud logging read --verbosity=$GCP_VERBOSITY --limit=1000 --order=desc --project=${{ secrets.GCP_PROJECT }} --quiet - grep "textPayload:.*Github.*$GITHUB_SHA" <<< $(gcloud logging read --order=desc --verbosity=$GCP_VERBOSITY --limit=1000 --project=${{ secrets.GCP_PROJECT }} --quiet) + gcloud logging read --verbosity=$GCP_VERBOSITY --limit=1000 --order=desc --freshness=2m --project=${{ secrets.GCP_PROJECT }} --quiet + grep "textPayload:.*Github.*$GITHUB_SHA" <<< $(gcloud logging read --order=desc --freshness=2m --verbosity=$GCP_VERBOSITY --limit=1000 --project=${{ secrets.GCP_PROJECT }} --quiet) - name: Delete test log run: |-