-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
6 changed files
with
35 additions
and
41 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,15 @@ | ||
ARG NODE_VERSION=20 | ||
|
||
FROM node:${NODE_VERSION} | ||
|
||
FROM node:${NODE_VERSION} AS base | ||
WORKDIR /hardhat-zkit | ||
|
||
COPY . . | ||
|
||
RUN npm install | ||
FROM base AS install | ||
RUN mkdir -p /temp/dev | ||
COPY package.json package-lock.json /temp/dev/ | ||
RUN cd /temp/dev && npm ci | ||
|
||
ARG RUN_TESTS=true | ||
FROM base AS dev | ||
COPY --from=install /temp/dev/node_modules node_modules | ||
COPY . . | ||
|
||
RUN if [ "$RUN_TESTS" = "true" ]; then npm run test-local; fi | ||
ENTRYPOINT ["npm", "run"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,4 @@ | ||
#!/usr/bin/env bash | ||
|
||
docker build --build-arg RUN_TESTS=false -t hardhat-zkit --progress=plain --no-cache . | ||
docker run --rm -v $(pwd)/coverage:/hardhat-zkit/coverage hardhat-zkit npm run coverage-local | ||
docker rmi hardhat-zkit --force | ||
docker build -t hardhat-zkit --progress=plain . | ||
docker run --rm -v $(pwd)/coverage:/hardhat-zkit/coverage hardhat-zkit coverage-local |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
#!/usr/bin/env bash | ||
|
||
docker build -t hardhat-zkit --progress=plain --no-cache . | ||
docker rmi hardhat-zkit --force | ||
docker build -t hardhat-zkit --progress=plain . | ||
docker run --rm hardhat-zkit test-local |