Refactor Docker setup to support multi-architecture builds and update base image to Alpine
Signed-off-by: Stephen Simpson <ssimpson89@users.noreply.github.com>
This commit is contained in:
12
Dockerfile
12
Dockerfile
@@ -1,8 +1,14 @@
|
||||
FROM rockylinux/rockylinux:8.4
|
||||
FROM alpine:latest
|
||||
|
||||
RUN curl -s https://packagecloud.io/install/repositories/ookla/speedtest-cli/script.rpm.sh | bash
|
||||
# Set architecture as a build argument with a default value
|
||||
ARG ARCH=x86_64
|
||||
|
||||
RUN yum -y install speedtest
|
||||
RUN apk add --no-cache wget ca-certificates tar
|
||||
|
||||
RUN wget -q https://install.speedtest.net/app/cli/ookla-speedtest-1.2.0-linux-${ARCH}.tgz && \
|
||||
tar -xzf ookla-speedtest-1.2.0-linux-${ARCH}.tgz -C /usr/bin && \
|
||||
rm ookla-speedtest-1.2.0-linux-${ARCH}.tgz && \
|
||||
chmod +x /usr/bin/speedtest
|
||||
|
||||
COPY entrypoint.sh /entrypoint.sh
|
||||
RUN chmod +x /entrypoint.sh
|
||||
|
||||
Reference in New Issue
Block a user