Skip to content

Commit

Permalink
feat(ci): add dev environment
Browse files Browse the repository at this point in the history
  • Loading branch information
Zygimantass committed Feb 26, 2024
1 parent 7af4906 commit 3a08839
Show file tree
Hide file tree
Showing 7 changed files with 26 additions and 4 deletions.
3 changes: 2 additions & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@ jobs:
build:
strategy:
matrix:
image: [{file: "slinky.e2e.Dockerfile", name: "slinky-simapp"}, {file: "slinky.e2e.oracle.Dockerfile", name: "slinky-sidecar"}, {file: "slinky.local.Dockerfile", name: "slinky-testapp"}]
image: [{file: "slinky.e2e.Dockerfile", name: "slinky-simapp"}, {file: "slinky.sidecar.Dockerfile", name: "slinky-sidecar"}, {file: "slinky.local.Dockerfile", name: "slinky-testapp"},
{file: "slinky.sidecar.e2e.Dockerfile", name: "slinky-e2e-sidecar"}]
runs-on: ubuntu-latest
env:
registry_url: 494494944992.dkr.ecr.us-east-2.amazonaws.com/skip-mev/${{ matrix.image.name }}
Expand Down
Empty file added .github/workflows/deploy.yml
Empty file.
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -32,4 +32,4 @@ run.go

# ide
.idea/*
.vscode/*
.vscode/*
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ install:
docker-build:
@echo "Building E2E Docker image..."
@DOCKER_BUILDKIT=1 $(DOCKER) build -t skip-mev/slinky-e2e -f contrib/images/slinky.e2e.Dockerfile .
@DOCKER_BUILDKIT=1 $(DOCKER) build -t skip-mev/slinky-e2e-oracle -f contrib/images/slinky.e2e.oracle.Dockerfile .
@DOCKER_BUILDKIT=1 $(DOCKER) build -t skip-mev/slinky-e2e-oracle -f contrib/images/slinky.sidecar.Dockerfile .

.PHONY: docker-build

Expand Down
File renamed without changes.
21 changes: 21 additions & 0 deletions contrib/images/slinky.sidecar.e2e.Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
FROM golang:1.22-bullseye AS builder

WORKDIR /src/slinky
COPY go.mod .

RUN go mod download

COPY . .

RUN make build
RUN go generate ./config

FROM ubuntu:rolling
EXPOSE 8080
EXPOSE 8001

COPY --from=builder /src/slinky/build/* /usr/local/bin/
RUN apt-get update && apt-get install ca-certificates -y

WORKDIR /usr/local/bin/
ENTRYPOINT ["oracle", "--oracle-config-path", "/oracle/oracle.json", "--market-config-path", "/oracle/market.json", "--host", "0.0.0.0", "--port", "8080"]
2 changes: 1 addition & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ services:
oracle:
build:
context: .
dockerfile: contrib/images/slinky.e2e.oracle.Dockerfile
dockerfile: contrib/images/slinky.sidecar.Dockerfile
volumes:
- ./config/local/oracle.json:/oracle/oracle.json
- ./config/local/market.json:/oracle/market.json
Expand Down

0 comments on commit 3a08839

Please sign in to comment.