mirror of
https://github.com/DSpace/dspace-angular.git
synced 2025-10-07 01:54:15 +00:00
12
.github/workflows/build.yml
vendored
12
.github/workflows/build.yml
vendored
@@ -15,17 +15,19 @@ jobs:
|
||||
env:
|
||||
# The ci step will test the dspace-angular code against DSpace REST.
|
||||
# Direct that step to utilize a DSpace REST service that has been started in docker.
|
||||
DSPACE_REST_HOST: localhost
|
||||
DSPACE_REST_HOST: 127.0.0.1
|
||||
DSPACE_REST_PORT: 8080
|
||||
DSPACE_REST_NAMESPACE: '/server'
|
||||
DSPACE_REST_SSL: false
|
||||
# Spin up UI on 127.0.0.1 to avoid host resolution issues in e2e tests with Node 18+
|
||||
DSPACE_UI_HOST: 127.0.0.1
|
||||
# When Chrome version is specified, we pin to a specific version of Chrome
|
||||
# Comment this out to use the latest release
|
||||
#CHROME_VERSION: "90.0.4430.212-1"
|
||||
strategy:
|
||||
# Create a matrix of Node versions to test against (in parallel)
|
||||
matrix:
|
||||
node-version: [14.x, 16.x]
|
||||
node-version: [16.x, 18.x]
|
||||
# Do NOT exit immediately if one matrix job fails
|
||||
fail-fast: false
|
||||
# These are the actual CI steps to perform per job
|
||||
@@ -112,7 +114,7 @@ jobs:
|
||||
start: yarn run serve:ssr
|
||||
# Wait for backend & frontend to be available
|
||||
# NOTE: We use the 'sites' REST endpoint to also ensure the database is ready
|
||||
wait-on: http://localhost:8080/server/api/core/sites, http://localhost:4000
|
||||
wait-on: http://127.0.0.1:8080/server/api/core/sites, http://127.0.0.1:4000
|
||||
# Wait for 2 mins max for everything to respond
|
||||
wait-on-timeout: 120
|
||||
|
||||
@@ -147,7 +149,7 @@ jobs:
|
||||
run: |
|
||||
nohup yarn run serve:ssr &
|
||||
printf 'Waiting for app to start'
|
||||
until curl --output /dev/null --silent --head --fail http://localhost:4000/home; do
|
||||
until curl --output /dev/null --silent --head --fail http://127.0.0.1:4000/home; do
|
||||
printf '.'
|
||||
sleep 2
|
||||
done
|
||||
@@ -158,7 +160,7 @@ jobs:
|
||||
# This step also prints entire HTML of homepage for easier debugging if grep fails.
|
||||
- name: Verify SSR (server-side rendering)
|
||||
run: |
|
||||
result=$(wget -O- -q http://localhost:4000/home)
|
||||
result=$(wget -O- -q http://127.0.0.1:4000/home)
|
||||
echo "$result"
|
||||
echo "$result" | grep -oE "<meta name=\"title\" [^>]*>" | grep DSpace
|
||||
|
||||
|
Reference in New Issue
Block a user