From e4af7206fd870002f5813aa59a9b21abb2b5fcc4 Mon Sep 17 00:00:00 2001 From: Daniyar Itegulov Date: Tue, 26 Sep 2023 04:02:10 +1000 Subject: [PATCH] feat: add dockerfile (#59) --- Dockerfile | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 Dockerfile diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..711e36b --- /dev/null +++ b/Dockerfile @@ -0,0 +1,13 @@ +FROM debian:bookworm as builder +WORKDIR /usr/src/app +RUN apt-get update && apt-get install --assume-yes curl +RUN curl -LJO https://s3-us-west-1.amazonaws.com/build.nearprotocol.com/nearcore/Linux-x86_64/master/d08187094a82b3bfab3b8b0fa076e71068f39cb7/near-sandbox.tar.gz +RUN tar -xf near-sandbox.tar.gz + +FROM debian:bookworm-slim as runtime +WORKDIR /usr/local/bin +COPY --from=builder /usr/src/app/Linux-x86_64/near-sandbox /usr/local/bin/near-sandbox +RUN apt-get update && apt-get install --assume-yes curl +RUN near-sandbox --home /root/.near init + +ENTRYPOINT [ "near-sandbox", "--home", "/root/.near", "run" ]