Skip to content

Commit ed1b6a3

Browse files
yury-sclaude
andcommitted
test_docker: drop git config step, copy maven cache to pwuser home
CI failure showed two issues with the unified-flag setup: 1. The Java Dockerfile does not install git, so the safe.directory config that the playwright-browsers workflow performs cannot run. The Java suite never invokes git inside the container, so the step is unnecessary. 2. The Dockerfile bakes the local maven cache into /root/.m2 (the build runs as root). When the container is launched as pwuser, that cache is unreadable, so playwright-java SNAPSHOT artifacts would not resolve. Copy it into /home/pwuser/.m2 with chown. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
1 parent 35d030a commit ed1b6a3

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

.github/workflows/test_docker.yml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,8 +54,11 @@ jobs:
5454
run: |
5555
docker cp . "$CONTAINER_ID":/home/pwuser/playwright
5656
docker exec --user root "$CONTAINER_ID" chown -R pwuser /home/pwuser/playwright
57-
docker exec --user root --workdir /home/pwuser/playwright "$CONTAINER_ID" \
58-
git config --global --add safe.directory /home/pwuser/playwright
57+
# Maven cache populated during image build lives in /root/.m2; make it
58+
# accessible to pwuser so the suite doesn't have to redownload everything
59+
# and so the locally-installed playwright-java SNAPSHOT artifacts are visible.
60+
docker exec --user root "$CONTAINER_ID" cp -R /root/.m2 /home/pwuser/.m2
61+
docker exec --user root "$CONTAINER_ID" chown -R pwuser /home/pwuser/.m2
5962
6063
- name: Run test in container
6164
run: |

0 commit comments

Comments
 (0)