Skip to content

Commit

Permalink
added docker compose file and dockerfile
Browse files Browse the repository at this point in the history
  • Loading branch information
bizk committed Sep 13, 2023
1 parent 8bed88b commit 562db5b
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 8 deletions.
24 changes: 24 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
FROM golang:1.20-alpine AS build-env

# Install minimum necessary dependencies
ENV PACKAGES curl make
RUN apk add --no-cache $PACKAGES

# Set working directory for the build
WORKDIR /go/src/github.com/cosmos/rosetta

# optimization: if go.sum didn't change, docker will use cached image
COPY go.mod go.sum ./

RUN go mod download

# Add source files
COPY . .

RUN make build

EXPOSE 8080

# Run simd by default
CMD ["./rosetta"]
STOPSIGNAL SIGTERM
9 changes: 1 addition & 8 deletions tests/compose.yaml → tests/docker-compose.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -40,16 +40,9 @@ services:
ports:
- 8080:8080

faucet:
image: tendermintdev/rosetta-cli:v0.6.7
working_dir: /rosetta
command: ["python3", "./config/faucet.py"]
expose:
- 8080

test_rosetta:
image: tendermintdev/rosetta-cli:v0.6.7
volumes:
- ./config:/rosetta/config:z
- ./config:/rosetta:z
command: ["./config/run_tests.sh"]
working_dir: /rosetta

0 comments on commit 562db5b

Please sign in to comment.