Skip to content

Commit 2ad9653

Browse files
committed
added qlty-cli to docker container
1 parent f26ab58 commit 2ad9653

File tree

3 files changed

+28
-19
lines changed

3 files changed

+28
-19
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
/vendor/
22
/.idea/
3+
/.qlty/
34
build/
45
composer.lock
56
.phpunit.result.cache

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -97,6 +97,10 @@ to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
9797

9898
## unstable - 2025-06-14
9999

100+
### Added
101+
102+
- Added qlty cli tool to docker container
103+
100104
### Changed
101105

102106
- Changed from codeclimate to qlty.sh

app.Dockerfile

Lines changed: 23 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,27 @@
11
FROM php:8.2-cli
2+
23
RUN apt-get update \
3-
&& apt-get install -y unzip curl libzip-dev zlib1g-dev libpng-dev libjpeg-dev \
4-
libfreetype6-dev git mariadb-client libmagickwand-dev openssh-client \
5-
make --no-install-recommends
6-
#ext-installs without dependencies
7-
RUN docker-php-ext-install pdo_mysql zip \
8-
&& docker-php-ext-install exif \
9-
&& docker-php-ext-install intl
10-
#PECL installs
11-
RUN pecl install xdebug
12-
#Enabling exts/installing exts with configurations
13-
RUN docker-php-ext-enable xdebug
14-
RUN docker-php-ext-install gd
15-
#Get composer
4+
&& apt-get install -y unzip curl libzip-dev zlib1g-dev libpng-dev libjpeg-dev \
5+
libfreetype6-dev git mariadb-client libmagickwand-dev openssh-client bash \
6+
make --no-install-recommends \
7+
&& rm -rf /var/lib/apt/lists/*
8+
9+
RUN docker-php-ext-install pdo_mysql zip exif intl gd \
10+
&& pecl install xdebug \
11+
&& docker-php-ext-enable xdebug
12+
1613
RUN curl -sS https://getcomposer.org/installer \
17-
| php -- --install-dir=/usr/local/bin --filename=composer
18-
# add user
19-
RUN adduser --disabled-password --gecos "" appuser
20-
RUN chown -R appuser:appuser /var/www/html
14+
| php -- --install-dir=/usr/local/bin --filename=composer
15+
16+
RUN adduser --uid 1000 --disabled-password --gecos "" --shell /bin/bash appuser
17+
18+
# Install qlty as root
19+
RUN curl https://qlty.sh | bash \
20+
&& cp /root/.qlty/bin/qlty /usr/local/bin/qlty
21+
22+
USER appuser
23+
WORKDIR /var/www/html
24+
25+
RUN git config --global --add safe.directory /var/www/html
2126

22-
# change to secured user
23-
USER appuser
27+
CMD ["sleep", "infinity"]

0 commit comments

Comments
 (0)