Skip to content

Commit

Permalink
Use a fast Alpine package mirror
Browse files Browse the repository at this point in the history
Without forcing a specific Alpine package mirror, it seems to use
the very slow default one.  This means building the docker image
can take 2+ hours (as happened yesterday).

With this change in place, building the docker image takes around
5-6 minutes.
  • Loading branch information
justinclift committed Oct 21, 2023
1 parent a86cc99 commit f467849
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,11 @@ RUN addgroup -S rabbitmq && \
adduser -S -D -h /var/lib/rabbitmq -s /sbin/nologin -g "Linux User,,," -G rabbitmq rabbitmq && \
chown -Rh rabbitmq: /opt/rabbitmq /var/log/rabbitmq

# Use a fast Australian mirror for the Alpine package repositories
# Without doing this, building the image can take 2+ hours. :(
RUN echo "https://mirror.aarnet.edu.au/pub/alpine/v3.18/main" > /etc/apk/repositories && \
echo "https://mirror.aarnet.edu.au/pub/alpine/v3.18/community" >> /etc/apk/repositories

# Install Git, Go, Memcached, Minio, and PostgreSQL
RUN apk update && \
apk upgrade && \
Expand Down

0 comments on commit f467849

Please sign in to comment.