Skip to content

Commit bc061f8

Browse files
authored
1 parent 93ae19d commit bc061f8

File tree

2 files changed

+18
-1
lines changed

2 files changed

+18
-1
lines changed

.github/docker/simple-server.compose.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ services:
2525

2626

2727
server:
28+
container_name: simple-server
2829
image: simpledotorg/server
2930
#command: bash -c "rm -f tmp/pids/server.pid ; bundle install ; bundle exec rake db:setup ; bundle exec rails s -p 3000 -b '0.0.0.0'"
3031
command: bash -c "bash ./run_docker_server.sh"

.github/workflows/ci_checks.yml

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,9 @@ jobs:
9090
uses: actions/checkout@v4
9191

9292
- name: Start Simple Docker server
93-
run: .github/scripts/deploy_docker_server.sh
93+
run: |
94+
.github/scripts/deploy_docker_server.sh
95+
echo "CONTAINER_ID=$(docker container ls -q -f name=simple-server)" >> $GITHUB_ENV
9496
9597
- name: Cache AVD
9698
uses: actions/cache@v4
@@ -157,6 +159,20 @@ jobs:
157159
name: failed-test-artifacts
158160
path: app/build/outputs/test-artifacts
159161

162+
- name: Extract Docker logs
163+
if: always()
164+
run: |
165+
docker cp ${{ env.CONTAINER_ID }}:/home/app/log ./docker_logs
166+
zip -r docker_logs.zip docker_logs/
167+
168+
169+
- name: Upload Docker logs
170+
if: always()
171+
uses: actions/upload-artifact@v4
172+
with:
173+
name: docker-logs
174+
path: docker_logs.zip
175+
160176
- name: Stop Simple Docker server
161177
run: |
162178
docker compose -f ".github/docker/simple-server.compose.yml" down

0 commit comments

Comments
 (0)