Skip to content
This repository has been archived by the owner on Mar 23, 2023. It is now read-only.

Commit

Permalink
Add infra/CI and update README
Browse files Browse the repository at this point in the history
  • Loading branch information
jparyani authored and frostRed committed Aug 16, 2021
1 parent b28f338 commit 292221c
Show file tree
Hide file tree
Showing 11 changed files with 4,302 additions and 281 deletions.
64 changes: 64 additions & 0 deletions .github/workflows/go.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
name: Go

on:
push:
pull_request:
branches: [ master ]

jobs:

build:
name: Build
runs-on: ubuntu-latest
steps:

- name: Set up Go 1.x
uses: actions/setup-go@v2
with:
go-version: ^1.13
id: go

- name: Check out code into the Go module directory
uses: actions/checkout@v2

- name: Test
run: go test ./core ./miner/... ./internal/ethapi/... ./les/...

- name: Build
run: make geth

e2e:
name: End to End
runs-on: ubuntu-latest
steps:

- name: Set up Go 1.x
uses: actions/setup-go@v2
with:
go-version: ^1.13
id: go

- name: Use Node.js 12.x
uses: actions/setup-node@v1
with:
node-version: 12.x

- name: Check out code into the Go module directory
uses: actions/checkout@v2

- name: Build
run: make geth

- name: Check out the e2e code repo
uses: actions/checkout@v2
with:
repository: flashbots/mev-geth-demo
path: e2e

- run: cd e2e && yarn install
- run: |
cd e2e
GETH=`pwd`/../build/bin/geth ./run.sh &
sleep 15
yarn run demo-simple
yarn run demo-contract
400 changes: 119 additions & 281 deletions README.md

Large diffs are not rendered by default.

359 changes: 359 additions & 0 deletions README.original.md

Large diffs are not rendered by default.

23 changes: 23 additions & 0 deletions infra/Dockerfile.node
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# Build Geth in a stock Go builder container
FROM golang:1.15-alpine as builder

RUN apk add --no-cache make gcc musl-dev linux-headers git

ADD . /go-ethereum
RUN cd /go-ethereum && make geth

# Pull Geth into a second stage deploy alpine container
FROM alpine:latest

ENV PYTHONUNBUFFERED=1
RUN apk add --update --no-cache groff less python3 curl jq ca-certificates && ln -sf python3 /usr/bin/python
RUN python3 -m ensurepip
RUN pip3 install --no-cache --upgrade pip setuptools awscli

COPY --from=builder /go-ethereum/build/bin/geth /usr/local/bin/

COPY ./infra/start-mev-geth-node.sh /root/start-mev-geth-node.sh
RUN chmod 755 /root/start-mev-geth-node.sh

EXPOSE 8545 8546 30303 30303/udp
ENTRYPOINT ["/root/start-mev-geth-node.sh"]
23 changes: 23 additions & 0 deletions infra/Dockerfile.updater
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# Build Geth in a stock Go builder container
FROM golang:1.15-alpine as builder

RUN apk add --no-cache make gcc musl-dev linux-headers git

ADD . /go-ethereum
RUN cd /go-ethereum && make geth

# Pull Geth into a second stage deploy alpine container
FROM alpine:latest

ENV PYTHONUNBUFFERED=1
RUN apk add --update --no-cache groff less python3 curl jq ca-certificates && ln -sf python3 /usr/bin/python
RUN python3 -m ensurepip
RUN pip3 install --no-cache --upgrade pip setuptools awscli

COPY --from=builder /go-ethereum/build/bin/geth /usr/local/bin/

COPY ./infra/start-mev-geth-updater.sh /root/start-mev-geth-updater.sh
RUN chmod 755 /root/start-mev-geth-updater.sh

EXPOSE 8545 8546 30303 30303/udp
ENTRYPOINT ["/root/start-mev-geth-updater.sh"]
Loading

0 comments on commit 292221c

Please sign in to comment.