Commit eba5f50c authored by Mark Tyneway's avatar Mark Tyneway Committed by Kelvin Fichter

ops: publish `ethereumoptimism/hardhat-node` docker image

Publishing the `hardhat-node` docker image will make using
the `docker-compose` setup much easier for developers
as they will be able to pull all of the docker images needed.
There is an existing `ethereumoptimism/hardhat` image that is
on an older version of `hardhat` that was pushed by the old
Optimism monorepo. This version of hardhat does not support
EIP1559 so it is expected that it will not work with the
existing tech stack.

This PR adds the ability to publish the `hardhat-node` docker
image for both releases and canary releases. A following PR
will be introduced that updates the `docker-compose` files
to specifically reference the new `hardhat-node` image
such that there will not be name collision errors in the future.
parent d42eeaf0
---
'@eth-optimism/hardhat-node': patch
---
Create `ethereumoptimism/hardhat-node` docker image
......@@ -23,6 +23,7 @@ jobs:
contracts: ${{ steps.packages.outputs.contracts }}
gas-oracle: ${{ steps.packages.outputs.gas-oracle }}
replica-healthcheck: ${{ steps.packages.outputs.replica-healthcheck }}
hardhat-node: ${{ needs.canary-publish.outputs.hardhat-node }}
canary-docker-tag: ${{ steps.docker-image-name.outputs.canary-docker-tag }}
proxyd: ${{ steps.packages.outputs.proxyd }}
rpc-proxy : ${{ steps.packages.outputs.rpc-proxy }}
......@@ -144,6 +145,32 @@ jobs:
push: true
tags: ethereumoptimism/gas-oracle:${{ needs.canary-publish.outputs.canary-docker-tag }}
hardhat-node:
name: Publish Hardhat Node ${{ needs.canary-publish.outputs.canary-docker-tag }}
needs: canary-publish
if: needs.canary-publish.outputs.hardhat-node != ''
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
- name: Login to Docker Hub
uses: docker/login-action@v1
with:
username: ${{ secrets.DOCKERHUB_ACCESS_TOKEN_USERNAME }}
password: ${{ secrets.DOCKERHUB_ACCESS_TOKEN_SECRET }}
- name: Build and push
uses: docker/build-push-action@v2
with:
context: ./ops/docker/hardhat
file: ./Dockerfile
push: true
tags: ethereumoptimism/hardhat-node:${{ needs.canary-publish.outputs.canary-docker-tag }}
builder:
name: Prepare the base builder image for the services
needs: canary-publish
......
......@@ -22,6 +22,7 @@ jobs:
replica-healthcheck: ${{ steps.packages.outputs.replica-healthcheck }}
proxyd: ${{ steps.packages.outputs.proxyd }}
rpc-proxy: ${{ steps.packages.outputs.rpc-proxy }}
hardhat-node: ${{ steps.packages.outputs.hardhat-node }}
steps:
- name: Checkout Repo
......@@ -139,6 +140,32 @@ jobs:
push: true
tags: ethereumoptimism/gas-oracle:${{ needs.release.outputs.gas-oracle }},ethereumoptimism/gas-oracle:latest
hardhat-node:
name: Publish Hardhat Node ${{ needs.release.outputs.hardhat-node }}
needs: release
if: needs.release.hardhat-node != ''
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Login to Docker Hub
uses: docker/login-action@v1
with:
username: ${{ secrets.DOCKERHUB_ACCESS_TOKEN_USERNAME }}
password: ${{ secrets.DOCKERHUB_ACCESS_TOKEN_SECRET }}
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
- name: Publish Hardhat Node
uses: docker/build-push-action@v2
with:
context: ./ops/docker/hardhat
file: ./Dockerfile
push: true
tags: ethereumoptimism/hardhat-node:${{ needs.release.outputs.gas-oracle }},ethereumoptimism/hardhat-node:latest
proxyd:
name: Publish proxyd Version ${{ needs.release.outputs.proxyd }}
needs: release
......
......@@ -3,7 +3,6 @@ FROM node:14-alpine
# bring in the config files for installing deps
COPY [ \
"package.json", \
"yarn.lock", \
"/hardhat/" \
]
......
{
"name": "@eth-optimism/hardhat-node",
"version": "1.0.0",
"version": "0.0.1",
"scripts": {
"start": "hardhat node --network hardhat"
},
"license": "MIT",
"dependencies": {
"hardhat": "^2.6.1"
"hardhat": "^2.6.5"
}
}
This source diff could not be displayed because it is too large. You can view the blob instead.
......@@ -13,7 +13,8 @@
"go/batch-submitter",
"go/proxyd",
"ops/docker/rpc-proxy",
"ops/docker/builder"
"ops/docker/builder",
"ops/docker/hardhat"
],
"nohoist": [
"examples/*"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment