Skip to content

Commit 8c9f90f

Browse files
authored
Merge pull request #306 from louga31/patch-1
Fix docker build on ARM
2 parents b54373e + 903ef34 commit 8c9f90f

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

deploy/docker/Dockerfile

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ CMD [ "sh" , "/lowcoder/api-service/entrypoint.sh" ]
6666
##
6767
FROM ubuntu:jammy as build-node-service
6868

69-
RUN apt update && DEBIAN_FRONTEND=noninteractive apt-get install --no-install-recommends -y curl ca-certificates
69+
RUN apt update && DEBIAN_FRONTEND=noninteractive apt-get install --no-install-recommends -y curl ca-certificates build-essential
7070

7171
# Download nodejs and install yarn
7272
RUN curl -sL https://deb.nodesource.com/setup_19.x | bash - \
@@ -174,8 +174,12 @@ RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install --no-instal
174174
&& curl -fsSL https://www.mongodb.org/static/pgp/server-4.4.asc | gpg --dearmor -o /usr/share/keyrings/mongodb-archive-keyring.gpg \
175175
&& echo "deb [signed-by=/usr/share/keyrings/mongodb-archive-keyring.gpg arch=amd64,arm64] http://repo.mongodb.org/apt/ubuntu focal/mongodb-org/4.4 multiverse" | tee /etc/apt/sources.list.d/mongodb-org-4.4.list \
176176
&& curl -sL https://deb.nodesource.com/setup_19.x | bash - \
177-
&& curl -sL http://archive.ubuntu.com/ubuntu/pool/main/o/openssl/libssl1.1_1.1.1f-1ubuntu2_amd64.deb --output libssl1.1_1.1.1f-1ubuntu2_amd64.deb \
178-
&& dpkg -i libssl1.1_1.1.1f-1ubuntu2_amd64.deb \
177+
&& if [ "$(dpkg --print-architecture)" = "amd64" ] || [ "$(dpkg --print-architecture)" = "i386" ]; then \
178+
curl -sL http://archive.ubuntu.com/ubuntu/pool/main/o/openssl/libssl1.1_1.1.1f-1ubuntu2_$(dpkg --print-architecture).deb --output libssl1.1_1.1.1f-1ubuntu2_$(dpkg --print-architecture).deb; \
179+
else \
180+
curl -sL http://ports.ubuntu.com/pool/main/o/openssl/libssl1.1_1.1.1f-1ubuntu2_$(dpkg --print-architecture).deb --output libssl1.1_1.1.1f-1ubuntu2_$(dpkg --print-architecture).deb; \
181+
fi \
182+
&& dpkg -i libssl1.1_1.1.1f-1ubuntu2_$(dpkg --print-architecture).deb \
179183
&& apt-get update && DEBIAN_FRONTEND=noninteractive apt-get -y install --no-install-recommends -y \
180184
mongodb-org \
181185
redis \

0 commit comments

Comments
 (0)