Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix path #24

Merged
merged 1 commit into from
Aug 20, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 5 additions & 4 deletions action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,10 @@ runs:
export PLATFORMSH_CLI_TOKEN=${{ inputs.PLATFORMSH_KEY }};

curl -fsSL https://raw.githubusercontent.com/platformsh/cli/main/installer.sh | bash
export PATH="/home/runner/.local/bin:{$PATH}"

if [[ "${{ inputs.ALLOW_CANCEL_CRON }}" == 1 ]]; then \
~/.platformsh/bin/platform activity:cancel --type=environment.cron; \
platform activity:cancel --type=environment.cron; \
fi

DETECTION_TRIES=0
Expand All @@ -86,7 +87,7 @@ runs:

while [ $TRIES -le $MAX_TRIES ]; do \
TRIES=$((TRIES+1)); \
ACTS=$(~/.platformsh/bin/platform activities --format=plain --columns=id,state --incomplete --no-header --no-interaction --type=${{ inputs.ACTIVITY_TYPES }} 2>&1 || true); \
ACTS=$(platform activities --format=plain --columns=id,state --incomplete --no-header --no-interaction --type=${{ inputs.ACTIVITY_TYPES }} 2>&1 || true); \

echo "$ACTS"; \
echo "----------------------"; \
Expand All @@ -100,7 +101,7 @@ runs:

echo ""

STATUS=$(~/.platformsh/bin/platform env:info status 2>&1 || true)
STATUS=$(platform env:info status 2>&1 || true)

if [[ "$STATUS" =~ "inactive" ]]; then \
echo "PlatformSH reports that the environment is not active. This might be because you have run out of available environment slots. Try to run 'platform env:activate -e ${{ inputs.ENVIRONMENT_NAME }} -p ${{ inputs.PLATFORMSH_ID }}'"; \
Expand All @@ -110,7 +111,7 @@ runs:
exit 2; \
fi

URL=$(~/.platformsh/bin/platform env:url -1 --pipe)
URL=$(platform env:url -1 --pipe)

CURL_HTTP_STATUS=$(curl -L -s -o /dev/null -w "%{http_code}" $URL)

Expand Down
Loading