-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #317 from multiversx/add-docker-image-for-sc-calls…
…-executor Added docker image for sc calls executor
- Loading branch information
Showing
6 changed files
with
78 additions
and
2 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 |
---|---|---|
|
@@ -21,6 +21,8 @@ | |
/esdata | ||
.env | ||
*.log | ||
# prevent accidental commit of key files | ||
*.pem | ||
|
||
mytestnet/** | ||
|
||
|
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 |
---|---|---|
@@ -0,0 +1,17 @@ | ||
version: "3.9" | ||
|
||
services: | ||
sc-calls-executor: | ||
build: | ||
context: .. | ||
dockerfile: scCallsExecutor.Dockerfile | ||
restart: unless-stopped | ||
volumes: | ||
- "../keys:/multiversx/keys" | ||
# change the `network-address`, `sc-proxy-address` and `private-key-file` accordingly | ||
entrypoint: "./scCallsExecutor \ | ||
-log-level *:DEBUG \ | ||
-log-save \ | ||
-network-address https://devnet-gateway.multiversx.com \ | ||
-sc-proxy-address erd1qqqqqqqqqqqqqpgq5l0743nyv45vdptmfh3jydkqtyzjqpgsrcjq8yuzxk \ | ||
-private-key-file ./keys/walletKey.pem" |
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,26 @@ | ||
FROM golang:1.20.7-bookworm AS builder | ||
LABEL description="This Docker image builds the SC calls executor binary." | ||
|
||
WORKDIR /multiversx | ||
COPY . . | ||
|
||
RUN go mod tidy | ||
|
||
WORKDIR /multiversx/cmd/scCallsExecutor | ||
|
||
RUN APPVERSION=$(git describe --tags --long --always | tail -c 11) && echo "package main\n\nfunc init() {\n\tappVersion = \"${APPVERSION}\"\n}" > local.go | ||
RUN go mod tidy | ||
RUN go build | ||
|
||
FROM ubuntu:22.04 AS runner | ||
LABEL description="This Docker image runs SC calls executor binary." | ||
|
||
RUN apt-get update \ | ||
&& apt-get -y install git \ | ||
&& apt-get clean | ||
|
||
COPY --from=builder /multiversx/cmd/scCallsExecutor /multiversx | ||
|
||
WORKDIR /multiversx | ||
|
||
ENTRYPOINT ["./scCallsExecutor"] |