forked from AztecProtocol/aztec-packages
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
27 lines (20 loc) · 924 Bytes
/
Dockerfile
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
# Building requires foundry.
FROM ubuntu:lunar
RUN apt update && apt install curl git jq bash nodejs npm python3.11-full python3-pip -y
# Use virtualenv, do not try to use pipx, it's not working.
# RUN python3 -m venv /root/.venv
# RUN /root/.venv/bin/pip3 install slither-analyzer==0.10.0 slitherin==0.5.0
RUN curl -L https://foundry.paradigm.xyz | bash
# Set env variables for foundry and venv
ENV PATH="${PATH}:/root/.foundry/bin:/root/.venv/bin"
RUN foundryup --version nightly-de33b6af53005037b463318d2628b5cfcaf39916
WORKDIR /usr/src/l1-contracts
COPY . .
#RUN git init
RUN forge clean && forge fmt --check && forge build && forge test --no-match-contract UniswapPortalTest
RUN npm install --global solhint
RUN solhint --config ./.solhint.json --fix "src/**/*.sol"
# RUN git add . && yarn slither && yarn slither-has-diff
RUN forge build
FROM scratch
COPY --from=0 /usr/src/l1-contracts/ /usr/src/l1-contracts/