Skip to content

Commit 9a01b43

Browse files
committed
chore: install docker compose package
Installing via the package rather than manually downloading the binary from GitHub is a simpler approach. Using the package manager will also ensure the package is updated properly.
1 parent a01d355 commit 9a01b43

File tree

2 files changed

+5
-9
lines changed

2 files changed

+5
-9
lines changed

Dockerfile

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -170,9 +170,6 @@ FROM $BASEIMAGE AS final
170170

171171
LABEL maintainer="team@appwrite.io"
172172

173-
ENV DOCKER_CONFIG=${DOCKER_CONFIG:-$HOME/.docker}
174-
ENV DOCKER_COMPOSE_VERSION="v5.0.0"
175-
176173
RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone
177174

178175
RUN set -ex \
@@ -210,19 +207,14 @@ RUN \
210207
libmaxminddb-dev \
211208
certbot \
212209
docker-cli \
210+
docker-cli-compose \
213211
libgomp \
214212
git \
215213
zip \
216214
&& docker-php-ext-install sockets pdo_mysql pdo_pgsql intl \
217215
&& apk del .deps \
218216
&& rm -rf /var/cache/apk/*
219217

220-
RUN \
221-
mkdir -p $DOCKER_CONFIG/cli-plugins \
222-
&& ARCH=$(uname -m) && if [ $ARCH == "armv7l" ]; then ARCH="armv7"; fi \
223-
&& curl -SL https://github.com/docker/compose/releases/download/$DOCKER_COMPOSE_VERSION/docker-compose-linux-$ARCH -o $DOCKER_CONFIG/cli-plugins/docker-compose \
224-
&& chmod +x $DOCKER_CONFIG/cli-plugins/docker-compose
225-
226218
WORKDIR /usr/src/code
227219

228220
COPY --from=swoole /usr/local/lib/php/extensions/no-debug-non-zts-20230831/swoole.so /usr/local/lib/php/extensions/no-debug-non-zts-20230831/

tests.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,10 @@ commandTests:
1717
command: "docker"
1818
args: ["--version"]
1919
expectedOutput: ["Docker version 28.*"]
20+
- name: 'Docker Compose command'
21+
command: "docker"
22+
args: ["compose", "version"]
23+
expectedOutput: ["Docker Compose version v.*"]
2024
- name: 'PHP modules'
2125
command: "php"
2226
args: ["-m"]

0 commit comments

Comments
 (0)