Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

adding genesis tools for stakewars into dockerfile #1567

Merged
merged 3 commits into from Oct 26, 2019
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
6 changes: 5 additions & 1 deletion Dockerfile
Expand Up @@ -30,7 +30,11 @@ RUN --mount=type=cache,target=/tmp/target \
--mount=type=cache,target=/usr/local/cargo/git \
--mount=type=cache,target=/usr/local/cargo/registry \
cargo build -p near --release && \
cp /tmp/target/release/near /usr/local/bin/
cargo build -p keypair-generator --release && \
cargo build -p genesis-csv-to-json --release && \
cp /tmp/target/release/near /usr/local/bin/ && \
cp /tmp/target/release/keypair-generator /usr/local/bin && \
cp /tmp/target/release/genesis-csv-to-json /usr/local/bin

EXPOSE 3030 24567

Expand Down
2 changes: 1 addition & 1 deletion Dockerfile.prod
Expand Up @@ -3,7 +3,7 @@ FROM phusion/baseimage:0.11
EXPOSE 3030 24567

COPY scripts/run_docker.sh /usr/local/bin/run.sh
COPY docker-build/near /usr/local/bin/near
COPY docker-build/* /usr/local/bin/

ENTRYPOINT ["/sbin/my_init", "--"]

Expand Down
2 changes: 2 additions & 0 deletions Makefile
Expand Up @@ -2,5 +2,7 @@ docker-nearcore:
DOCKER_BUILDKIT=1 docker build -t nearcore-dev -f Dockerfile .
mkdir -p docker-build
docker run -v ${PWD}/docker-build:/opt/mount --rm --entrypoint cp nearcore-dev /usr/local/bin/near /opt/mount/near
docker run -v ${PWD}/docker-build:/opt/mount --rm --entrypoint cp nearcore-dev /usr/local/bin/genesis-csv-to-json /opt/mount/genesis-csv-to-json
docker run -v ${PWD}/docker-build:/opt/mount --rm --entrypoint cp nearcore-dev /usr/local/bin/keypair-generator /opt/mount/keypair-generator
docker build -t nearcore -f Dockerfile.prod .
sudo rm -rf docker-build