-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
37 lines (33 loc) · 1.3 KB
/
Dockerfile
File metadata and controls
37 lines (33 loc) · 1.3 KB
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
35
36
37
FROM buildpack-deps:bookworm-curl
ARG LEAN_VERSION
ARG BLV_VERSION
ENV ELAN_HOME=/usr/local/elan \
PATH=/usr/local/elan/bin:$PATH \
N_WORKERS=1
SHELL ["/bin/bash", "-euxo", "pipefail", "-c"]
# Install
# 1. Lean toolchain
# 2. Redis
# 3. repl
# 4. blv
RUN curl https://raw.githubusercontent.com/leanprover/elan/master/elan-init.sh -sSf | sh -s -- -y --no-modify-path --default-toolchain leanprover/lean4:${LEAN_VERSION}; \
chmod -R a+w $ELAN_HOME; \
elan --version; \
lean --version; \
leanc --version; \
lake --version; \
apt update -y; \
apt install -y git lsb-release gcc redis python3 python3-pip; \
git clone --depth 1 --branch ${LEAN_VERSION} https://github.com/offendo/repl.git; \
git clone --depth 1 https://github.com/offendo/blv.git; \
(cd repl && lake update && lake build && lake exe cache get); \
(cd blv && pip install --break-system-packages -r requirements.lock);
# RUN (cd / && \
# lake new project math && \
# cd project && \
# curl https://raw.githubusercontent.com/leanprover-community/mathlib4/${LEAN_VERSION}/lean-toolchain -o lean-toolchain && \
# sed -i "s/name = \"mathlib\"/name = \"mathlib\"\nversion = \"git#${LEAN_VERSION}\"/g" lakefile.toml && \
# lake exe cache get && \
# lake build \
# );
WORKDIR /blv