Skip to content

Commit f37df54

Browse files
committed
fix: update COMPOSER_HOME path and set user for Docker commands in build check workflow
1 parent d50fc34 commit f37df54

File tree

1 file changed

+8
-4
lines changed

1 file changed

+8
-4
lines changed

.github/workflows/docker-build-check.yaml

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -56,8 +56,9 @@ jobs:
5656
docker run --rm \
5757
-v ${{ github.workspace }}:/var/www/html \
5858
-w /var/www/html \
59-
-e COMPOSER_HOME=/tmp/composer \
59+
-e COMPOSER_HOME=/var/www/.composer \
6060
-e GITHUB_TOKEN=${{ secrets.GITHUB_TOKEN }} \
61+
--user www-data \
6162
satisfy-test:${{ github.sha }} \
6263
composer install --no-interaction --prefer-dist
6364
@@ -66,8 +67,9 @@ jobs:
6667
docker run --rm \
6768
-v ${{ github.workspace }}:/var/www/html \
6869
-w /var/www/html \
69-
-e COMPOSER_HOME=/tmp/composer \
70+
-e COMPOSER_HOME=/var/www/.composer \
7071
-e GITHUB_TOKEN=${{ secrets.GITHUB_TOKEN }} \
72+
--user www-data \
7173
satisfy-test:${{ github.sha }} \
7274
composer diagnose
7375
@@ -76,8 +78,9 @@ jobs:
7678
docker run --rm \
7779
-v ${{ github.workspace }}:/var/www/html \
7880
-w /var/www/html \
79-
-e COMPOSER_HOME=/tmp/composer \
81+
-e COMPOSER_HOME=/var/www/.composer \
8082
-e GITHUB_TOKEN=${{ secrets.GITHUB_TOKEN }} \
83+
--user www-data \
8184
satisfy-test:${{ github.sha }} \
8285
composer check-platform-reqs
8386
@@ -87,8 +90,9 @@ jobs:
8790
docker run --rm \
8891
-v ${{ github.workspace }}:/var/www/html \
8992
-w /var/www/html \
90-
-e COMPOSER_HOME=/tmp/composer \
93+
-e COMPOSER_HOME=/var/www/.composer \
9194
-e GITHUB_TOKEN=${{ secrets.GITHUB_TOKEN }} \
9295
-e APP_ENV=test \
96+
--user www-data \
9397
satisfy-test:${{ github.sha }} \
9498
bin/phpunit

0 commit comments

Comments
 (0)