mirror of
https://github.com/Alfresco/alfresco-content-app.git
synced 2026-09-09 18:02:54 +00:00
[ACS-10960] fix workflow (run-e2e-with-env) localhost (#4989)
* [ACS-10960] fix workflow localhost * [ACS-10960] remove pr run part * [ACS-10960] url check * [ACS-10960] remove pull request run for this workflow
This commit is contained in:
@@ -17,13 +17,27 @@ runs:
|
||||
using: "composite"
|
||||
steps:
|
||||
|
||||
- name: Set PLAYWRIGHT_E2E_HOST
|
||||
if: inputs.url != ''
|
||||
shell: bash
|
||||
run: |
|
||||
# Construct the full URL with /aca path (without #/ as tests add that)
|
||||
if [[ "${{ inputs.url }}" != *"/aca"* ]]; then
|
||||
echo "PLAYWRIGHT_E2E_HOST=${{ inputs.url }}/aca" >> $GITHUB_ENV
|
||||
else
|
||||
echo "PLAYWRIGHT_E2E_HOST=${{ inputs.url }}" >> $GITHUB_ENV
|
||||
fi
|
||||
|
||||
- name: Setup and run with options
|
||||
shell: bash
|
||||
env:
|
||||
OPTIONS: ${{ inputs.options }}
|
||||
PLAYWRIGHT_BROWSER: ${{ env.PLAYWRIGHT_BROWSER || 'chromium' }}
|
||||
run: |
|
||||
npm start > /dev/null &\
|
||||
# Only start local server if using localhost
|
||||
if [[ "${PLAYWRIGHT_E2E_HOST}" == "http://localhost"* ]]; then
|
||||
npm start > /dev/null &
|
||||
fi
|
||||
|
||||
printf "Waiting for the application to be ready..."
|
||||
while ! curl -sf ${PLAYWRIGHT_E2E_HOST} > /dev/null; do
|
||||
|
||||
@@ -20,7 +20,7 @@ env:
|
||||
HR_USER_PASSWORD: ${{ secrets.HR_USER_PASSWORD }}
|
||||
SCREENSHOT_USERNAME: ${{ secrets.SCREENSHOT_USERNAME }}
|
||||
SCREENSHOT_PASSWORD: ${{ secrets.SCREENSHOT_PASSWORD}}
|
||||
PLAYWRIGHT_E2E_HOST: ${{ inputs.url || secrets.PIPELINE_ENV_URL }}/aca/#/
|
||||
PLAYWRIGHT_E2E_HOST: ${{ inputs.url || secrets.PLAYWRIGHT_E2E_HOST }}
|
||||
GH_BUILD_NUMBER: ${{ github.run_id }}
|
||||
REPORT_PORTAL_URL: ${{ secrets.REPORT_PORTAL_URL }}
|
||||
REPORT_PORTAL_TOKEN: ${{ secrets.REPORT_PORTAL_TOKEN }}
|
||||
|
||||
Reference in New Issue
Block a user