forked from o1-labs/o1js
-
Notifications
You must be signed in to change notification settings - Fork 2
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
mike dupont
committed
Sep 14, 2024
1 parent
7647eb9
commit deeb075
Showing
2 changed files
with
4,470 additions
and
0 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
FROM node:20-slim AS base | ||
ENV PNPM_HOME="/pnpm" | ||
ENV PATH="$PNPM_HOME:$PATH" | ||
RUN corepack enable | ||
COPY . /app | ||
WORKDIR /app | ||
|
||
FROM base AS prod-deps | ||
RUN --mount=type=cache,id=pnpm,target=/pnpm/store pnpm install --prod --frozen-lockfile | ||
|
||
FROM base AS build | ||
RUN --mount=type=cache,id=pnpm,target=/pnpm/store pnpm install --frozen-lockfile | ||
RUN pnpm run build | ||
|
||
FROM base | ||
COPY --from=prod-deps /app/node_modules /app/node_modules | ||
COPY --from=build /app/dist /app/dist | ||
EXPOSE 8000 | ||
CMD [ "pnpm", "start" ] | ||
|
||
|
||
|
||
# # Use an official Ubuntu image as a base | ||
# #FROM ubuntu:latest | ||
# FROM o1labs/mina-local-network:compatible-latest-devnet | ||
|
||
# # Set the working directory to /app | ||
# WORKDIR /app | ||
|
||
# # Install required dependencies | ||
# RUN apt update && apt install -y \ | ||
# git \ | ||
# curl \ | ||
# npm \ | ||
# nodejs | ||
|
||
# # Install Node.js version 18 | ||
# RUN curl -fsSL https://deb.nodesource.com/setup_18.x | bash - | ||
# RUN apt-get install -y nodejs | ||
|
||
# # Clone the repository and checkout the specific branch | ||
# RUN git clone https://github.com/meta-introspector/o1js.git . | ||
# RUN git checkout 7647eb9 | ||
|
||
# # Install npm dependencies | ||
# RUN npm ci | ||
|
||
# # Build o1js | ||
# RUN npm run build | ||
|
||
# # Expose the port for the web server | ||
# EXPOSE 8080 | ||
|
||
# # Run the command to start the web server when the container launches | ||
# CMD ["npm", "run", "start"] |
Oops, something went wrong.