This commit is contained in:
@@ -16,21 +16,25 @@ jobs:
|
|||||||
- name: Check out the pushed revision
|
- name: Check out the pushed revision
|
||||||
uses: https://github.com/actions/checkout@v4
|
uses: https://github.com/actions/checkout@v4
|
||||||
|
|
||||||
- name: Install dependencies
|
# Host-mode action workspaces are ephemeral runner internals. Copy the checked-out SHA
|
||||||
run: npm ci
|
# to a normal writable path so Node tests and Docker Compose see the same source tree.
|
||||||
|
- name: Prepare isolated build directory
|
||||||
- name: Verify checked-out source
|
|
||||||
run: |
|
run: |
|
||||||
pwd
|
export CI_WORKDIR="/tmp/roast-command-center-${GITHUB_RUN_ID}"
|
||||||
test -f public/landing.html
|
rm -rf "$CI_WORKDIR"
|
||||||
test -f public/login.html
|
mkdir -p "$CI_WORKDIR"
|
||||||
test -f test/auth.test.js
|
cp -a ./. "$CI_WORKDIR/"
|
||||||
|
echo "CI_WORKDIR=$CI_WORKDIR" >> "$GITHUB_ENV"
|
||||||
|
|
||||||
|
- name: Install dependencies
|
||||||
|
run: cd "$CI_WORKDIR" && npm ci
|
||||||
|
|
||||||
- name: Test
|
- name: Test
|
||||||
run: npm test
|
run: cd "$CI_WORKDIR" && npm test
|
||||||
|
|
||||||
- name: Deploy to Unraid Docker
|
- name: Deploy to Unraid Docker
|
||||||
run: |
|
run: |
|
||||||
|
cd "$CI_WORKDIR"
|
||||||
docker compose \
|
docker compose \
|
||||||
--project-name roast_command_center \
|
--project-name roast_command_center \
|
||||||
--env-file /run/roast-production.env \
|
--env-file /run/roast-production.env \
|
||||||
@@ -39,6 +43,7 @@ jobs:
|
|||||||
|
|
||||||
- name: Verify the running container
|
- name: Verify the running container
|
||||||
run: |
|
run: |
|
||||||
|
cd "$CI_WORKDIR"
|
||||||
docker compose \
|
docker compose \
|
||||||
--project-name roast_command_center \
|
--project-name roast_command_center \
|
||||||
--env-file /run/roast-production.env \
|
--env-file /run/roast-production.env \
|
||||||
|
|||||||
Reference in New Issue
Block a user