Skip to content

Commit

Permalink
fix dockerfile hanging on tzdata step (#42)
Browse files Browse the repository at this point in the history
When building the docker container there were a couple new issues breaking things:

There are some debian security files that couldn't be found, and this was solved by this SO answer updating source lists so it looks in the correct place where these files now live
Then it was getting hung up on tzdata when installing packages. This medium article explains that there is some issue with it needing a timezone and it just waits for you to interactively enter it, but we can just specify it upfront.
  • Loading branch information
austensen authored Aug 2, 2023
1 parent 8baa1b8 commit 5a017f8
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,15 @@ FROM node:12.10.0

ARG XPDF_VERSION=4.04

# https://stackoverflow.com/a/76095392/7051239
RUN sed -i -e 's/deb.debian.org/archive.debian.org/g' \
-e 's|security.debian.org|archive.debian.org/|g' \
-e '/stretch-updates/d' /etc/apt/sources.list

# https://grigorkh.medium.com/fix-tzdata-hangs-docker-image-build-cdb52cc3360d
ENV TZ=America/New_York
RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone

# https://github.com/Googlechrome/puppeteer/issues/290#issuecomment-322838700
RUN apt-get update && apt-get install -y \
gconf-service \
Expand Down

0 comments on commit 5a017f8

Please sign in to comment.