@@ -29,18 +29,6 @@ inputs:
2929runs :
3030 using : composite
3131 steps :
32- - run : >
33- echo "GH_ACTION_ROOT=$(
34- ls -d $(
35- ls -d ./../../_actions/* |
36- grep -i localstack |
37- tail -n1
38- )/setup-localstack/* |
39- grep -v completed |
40- tail -n1
41- )" >> $GITHUB_ENV
42- shell: bash
43-
4432 - name : Initial PR comment
4533 if : inputs.github-token
4634 uses : jenseng/dynamic-uses@5175289a9a87978dcfcb9cf512b821d23b2a53eb # v1
@@ -68,19 +56,14 @@ runs:
6856 echo "name=$previewName" >> $GITHUB_OUTPUT
6957
7058 - name : Create preview environment
71- # Source shared retry function
72- # GH_ACTION_ROOT is set in the main action.yml and points to the root of the action
73- # This ensures the script is found regardless of where the action is run from.
74- env :
75- SHARED_SCRIPTS_PATH : ${{ env.GH_ACTION_ROOT }}/.github/actions/shared-scripts
7659 shell : bash
7760 id : create-instance
7861 run : |
7962 AUTH_HEADER="ls-api-key: ${LOCALSTACK_AUTH_TOKEN:-${LOCALSTACK_API_KEY:-${{ inputs.localstack-auth-token }}}}"
8063 CONTENT_TYPE_HEADER="content-type: application/json"
8164 API_URL_BASE="https://api.localstack.cloud/v1/compute/instances"
8265
83- source "$SHARED_SCRIPTS_PATH /retry-function.sh"
66+ source ${{ github.action_path }} /retry-function.sh
8467 fetch_instances() {
8568 local list_response
8669 list_response=$(curl --fail-with-body -s -X GET \
@@ -159,15 +142,12 @@ runs:
159142 shell : bash
160143 env :
161144 previewName : ${{ steps.preview-name.outputs.name }}
162- # Source shared retry function
163- # GH_ACTION_ROOT is set in the main action.yml and points to the root of the action
164- SHARED_SCRIPTS_PATH : ${{ env.GH_ACTION_ROOT }}/.github/actions/shared-scripts
165145 run : |
166146 AUTH_HEADER="ls-api-key: ${LOCALSTACK_AUTH_TOKEN:-${LOCALSTACK_API_KEY:-${{ inputs.localstack-auth-token }}}}"
167147 CONTENT_TYPE_HEADER="content-type: application/json"
168148 API_URL_BASE="https://api.localstack.cloud/v1/compute/instances"
169149
170- source "$SHARED_SCRIPTS_PATH /retry-function.sh"
150+ source ${{ github.action_path }} /retry-function.sh
171151 fetch_logs() {
172152 local log_response
173153 log_response=$(curl --fail-with-body -s -X GET \
0 commit comments