blog/utils/builder.Dockerfile

26 lines
788 B
Text
Raw Normal View History

2023-10-11 19:45:33 +00:00
FROM git.mzhang.io/michael/agda:2.6.4-x86_64
2023-10-11 22:19:05 +00:00
FROM node:18-alpine AS node
RUN apk add --update git
RUN npm install -g pnpm
FROM node AS astro-build
WORKDIR /tmp
RUN git clone https://git.mzhang.io/michael/astro --depth 1
WORKDIR /tmp/astro
RUN pnpm install
RUN pnpm run build
RUN rm -rf node_modules
FROM node
2023-10-11 19:45:33 +00:00
COPY --from=0 /usr/bin/agda /usr/bin/agda
2023-10-11 21:16:32 +00:00
COPY --from=0 /agda/.stack-work/install/x86_64-linux-musl/099dc152e5f5edaf6e084b385953a851d037c26c20471a6eefaa57c4704a9540/9.4.7/share/x86_64-linux-ghc-9.4.7/Agda-2.6.4/lib /agda/.stack-work/install/x86_64-linux-musl/099dc152e5f5edaf6e084b385953a851d037c26c20471a6eefaa57c4704a9540/9.4.7/share/x86_64-linux-ghc-9.4.7/Agda-2.6.4/lib
2023-10-11 22:19:05 +00:00
COPY --from=astro-build /tmp/astro /tmp/astro
WORKDIR /tmp/astro
RUN pnpm link --global
WORKDIR /