wking-io / elm-live

⚡ A flexible dev server for Elm. Live reload included.
https://elm-live.com
MIT License
1.05k stars 61 forks source link

Error thrown when trying to run elm-live through Docker #232

Closed asett0 closed 4 years ago

asett0 commented 4 years ago

Hi,

I'm trying to run elm-live through a docker container but am getting the following error when trying to access my application on localhost.

This is the Dockerfile I'm using

FROM alpine:3.11 AS elm
RUN apk add curl
RUN curl -L -o elm.gz https://github.com/elm/compiler/releases/download/0.19.1/binary-for-linux-64-bit.gz
RUN gunzip elm.gz
RUN chmod +x elm
RUN mv elm /usr/local/bin/

FROM node:14.2.0-alpine3.11 AS dev
RUN npm install -g elm-live@4.0.2
COPY --from=elm /usr/local/bin/elm /usr/local/bin/
COPY frontend/ /frontend/
WORKDIR /frontend/
CMD ["elm-live", "src/Main.elm","--host=0.0.0.0"]

and attached below is an image of the error message I receive image

Thanks in advance for taking the time to read this :)

Cheers.

asett0 commented 4 years ago

Tried switching to a debian:buster-slim and got the following error image

However after switching to just a debian:buster image it seems to work fine :).

Are there any plans for making "official" elm-live images on docker hub? I personally would love to use something like that.

asett0 commented 4 years ago

So turns out this error had nothing to do with the base image.. I just needed to wait for the server to compile the files first and wait for this message.

image

I'm so sorry!