-
Notifications
You must be signed in to change notification settings - Fork 1
/
Dockerfile.esy
34 lines (21 loc) · 975 Bytes
/
Dockerfile.esy
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
# start from node image so we can install esy from npm
FROM node:12-alpine as build
LABEL maintainer "Ulrik Strid <ulrik.strid@outlook.com>"
ARG ESY_VERSION=esy@0.6.7
ENV TERM=dumb LD_LIBRARY_PATH=/usr/local/lib:/usr/lib:/lib
RUN mkdir /esy
WORKDIR /esy
ENV NPM_CONFIG_PREFIX=/esy
RUN npm install -g --unsafe-perm $ESY_VERSION
# now that we have esy installed we need a proper runtime
# we should be able to use the esy install script in the future
FROM alpine:3.14 as esy
ENV TERM=dumb LD_LIBRARY_PATH=/usr/local/lib:/usr/lib:/lib
WORKDIR /
COPY --from=build /esy /esy
RUN apk add --no-cache ca-certificates wget bash curl perl-utils git patch \
gcc g++ musl-dev make m4 linux-headers coreutils libstdc++ tar
RUN wget -q -O /etc/apk/keys/sgerrand.rsa.pub https://alpine-pkgs.sgerrand.com/sgerrand.rsa.pub
RUN wget https://github.com/sgerrand/alpine-pkg-glibc/releases/download/2.31-r0/glibc-2.31-r0.apk
RUN apk add glibc-2.31-r0.apk
ENV PATH=/esy/bin:$PATH