Skip to content

Commit ccfa59f

Browse files
committed
Update SonarCloud scan action
Also try to run Docker container as the host user
1 parent 8682801 commit ccfa59f

File tree

3 files changed

+8
-6
lines changed

3 files changed

+8
-6
lines changed

.github/workflows/ci.yml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,7 @@ jobs:
2222
- name: Process test reports
2323
run: make process-reports
2424

25-
- name: SonarCloud
26-
uses: sonarsource/sonarcloud-github-action@master
25+
- name: SonarQube Scan
26+
uses: SonarSource/sonarqube-scan-action@v5
2727
env:
28-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
2928
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}

Makefile

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,17 @@
11
.PHONY: all clean docker-build docker-images help lint lint-fix repl shell test test-static test-unit bump bump-dev process-reports
22

3+
HOST_UID ?= `id -u`
4+
HOST_GID ?= `id -g`
35
IMAGE ?= php_8_4
4-
PHP = docker compose run --rm php
6+
PHP = docker compose run --rm -u $(HOST_UID):$(HOST_GID) php
57

68
all: test
79

810
vendor:
911
$(PHP) composer install
1012

1113
clean:
12-
$(PHP) rm -rf vendor composer.lock
14+
$(PHP) rm -rf build vendor .phpunit.result.cache composer.lock
1315

1416
lint: vendor
1517
$(PHP) composer lint

docker-compose.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ services:
33
build: ./docker/image/${IMAGE:-php_8_4}
44
volumes:
55
- .:/app
6-
- ${COMPOSER_HOME:-$HOME/.composer}:/tmp
6+
- ${COMPOSER_HOME:-$HOME/.composer}:/composer
77
networks:
88
- app
99
environment:
@@ -12,6 +12,7 @@ services:
1212
- XDEBUG_TRIGGER
1313
- PHP_IDE_CONFIG
1414
- COMPOSER_ROOT_VERSION=dev-master
15+
- COMPOSER_HOME=/composer
1516

1617
networks:
1718
app:

0 commit comments

Comments
 (0)