Skip to content

Commit 3b42743

Browse files
authored
Initial commit
0 parents  commit 3b42743

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

66 files changed

+6974
-0
lines changed

.github/actions/setup/action.yaml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
name: Install deps
2+
description: Install deps
3+
runs:
4+
using: composite
5+
steps:
6+
- name: Install asdf
7+
uses: asdf-vm/actions/setup@05e0d2ed97b598bfce82fd30daf324ae0c4570e6 # v3.0.2
8+
9+
- name: Install asdf tools
10+
shell: bash
11+
run: ./setup.sh

.github/dependabot.yml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
version: 2
2+
updates:
3+
- package-ecosystem: github-actions
4+
directory: /
5+
schedule:
6+
interval: monthly
7+
groups:
8+
actions:
9+
patterns:
10+
- '*'
Lines changed: 197 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,197 @@
1+
name: Hive - Devnet 0
2+
on:
3+
schedule:
4+
- cron: '45 12 * * *'
5+
workflow_dispatch:
6+
# Note: We're limited to 10 inputs
7+
inputs:
8+
client:
9+
type: string
10+
default: '"go-ethereum","reth","nethermind","nimbus-el","besu","erigon"'
11+
description: Comma-separated list of clients to test .e.g go-ethereum, besu, reth, nethermind, erigon, nimbus-el
12+
simulator:
13+
type: string
14+
default: >-
15+
"ethereum/eest/consume-engine",
16+
"ethereum/eest/consume-rlp"
17+
description: >-
18+
Comma-separated list of simulators to test
19+
.e.g ethereum/rpc-compat, ethereum/eest/consume-engine, ethereum/eest/consume-rlp, ethereum/eest/execute-blobs
20+
hive_version:
21+
type: string
22+
default: ethereum/hive@master
23+
description: GitHub repository and tag for hive (repo@tag)
24+
client_source:
25+
type: choice
26+
description: >-
27+
How client images should be sourced.
28+
'git' will use the github repo and tag (See client_repos).
29+
'docker' will use the docker registry and tag (See client_images).
30+
options:
31+
- docker
32+
- git
33+
common_client_tag:
34+
type: string
35+
description: >-
36+
If provided, this tag will be used for all clients, overriding individual tags/branches in client_repos and client_images
37+
default: 'template-devnet-0'
38+
client_repos:
39+
type: string
40+
default: |
41+
{
42+
"geth": "ethereum/go-ethereum@master",
43+
"besu": "hyperledger/besu@main",
44+
"reth": "paradigmxyz/reth@main",
45+
"nethermind": "NethermindEth/nethermind@master",
46+
"erigon": "erigontech/erigon@main",
47+
"nimbusel": "status-im/nimbus-eth1@master"
48+
}
49+
description: 'JSON object containing client versions in format {"client": "repo@tag", ...}'
50+
client_images:
51+
type: string
52+
default: |
53+
{
54+
"geth": "docker.ethquokkaops.io/dh/ethpandaops/geth:template-devnet-0",
55+
"besu": "docker.ethquokkaops.io/dh/ethpandaops/besu:template-devnet-0",
56+
"reth": "docker.ethquokkaops.io/dh/ethpandaops/reth:template-devnet-0",
57+
"nethermind": "docker.ethquokkaops.io/dh/ethpandaops/nethermind:template-devnet-0",
58+
"erigon": "docker.ethquokkaops.io/dh/ethpandaops/erigon:template-devnet-0",
59+
"nimbusel": "docker.ethquokkaops.io/dh/ethpandaops/nimbus-eth1:template-devnet-0"
60+
}
61+
description: 'JSON object containing client docker images in format {"client": "registry:tag", ...}'
62+
63+
env:
64+
# Proxy
65+
GOPROXY: "${{ vars.GOPROXY }}"
66+
# Hive action environment variables
67+
S3_BUCKET: hive-results
68+
S3_PATH: template-devnet-0
69+
S3_PUBLIC_URL: https://hive.ethpandaops.io/#/test/template-devnet-0/
70+
INSTALL_RCLONE_VERSION: v1.68.2
71+
EEST_BUILD_ARG_FIXTURES: https://github.com/ethereum/execution-spec-tests/releases/download/template-devnet-0%40v1.0.0/fixtures_template-devnet-0.tar.gz
72+
EEST_BUILD_ARG_BRANCH: hive
73+
# Flags used for all simulators
74+
GLOBAL_EXTRA_FLAGS: >-
75+
--client.checktimelimit=180s
76+
--sim.parallelism=4
77+
--docker.auth
78+
--docker.buildoutput
79+
# Flags used for the ethereum/eest/consume-engine simulator
80+
EEST_ENGINE_FLAGS: >-
81+
--sim.buildarg fixtures=${EEST_BUILD_ARG_FIXTURES}
82+
--sim.buildarg branch=${EEST_BUILD_ARG_BRANCH}
83+
--sim.loglevel=3
84+
# Flags used for the ethereum/eest/consume-rlp simulator
85+
EEST_RLP_FLAGS: >-
86+
--sim.buildarg fixtures=${EEST_BUILD_ARG_FIXTURES}
87+
--sim.buildarg branch=${EEST_BUILD_ARG_BRANCH}
88+
--sim.loglevel=3
89+
# Flags used for the ethereum/eest/execute simulator
90+
EEST_EXECUTE_FLAGS: >-
91+
--sim.buildarg branch=${EEST_BUILD_ARG_BRANCH}
92+
# Flags used for the ethereum/rpc-compat simulator
93+
RPC_COMPAT_FLAGS: >-
94+
--sim.loglevel=3
95+
96+
jobs:
97+
prepare:
98+
runs-on: ubuntu-latest
99+
outputs:
100+
# Hive version
101+
hive_repo: >-
102+
${{
103+
steps.client_config_schedule.outputs.hive_repo ||
104+
steps.client_config_dispatch.outputs.hive_repo
105+
}}
106+
hive_tag: >-
107+
${{
108+
steps.client_config_schedule.outputs.hive_tag ||
109+
steps.client_config_dispatch.outputs.hive_tag
110+
}}
111+
# client_config contains the YAML client config for Hive
112+
client_config: >-
113+
${{
114+
steps.client_config_schedule.outputs.client_config ||
115+
steps.client_config_dispatch.outputs.client_config
116+
}}
117+
steps:
118+
- uses: ethpandaops/hive-github-action/helpers/client-config@a9ec89442df18ee579d3179b76c47f5f93954307 # v0.4.0
119+
if: github.event_name == 'schedule'
120+
name: 'Client config: schedule'
121+
id: client_config_schedule
122+
with:
123+
common_client_tag: 'template-devnet-0'
124+
client_source: 'docker'
125+
hive_version: 'ethereum/hive@master'
126+
goproxy: ${{ env.GOPROXY }}
127+
128+
- uses: ethpandaops/hive-github-action/helpers/client-config@a9ec89442df18ee579d3179b76c47f5f93954307 # v0.4.0
129+
if: github.event_name == 'workflow_dispatch'
130+
name: 'Client config: workflow_dispatch'
131+
id: client_config_dispatch
132+
with:
133+
client_repos: ${{ inputs.client_repos }}
134+
client_images: ${{ inputs.client_images }}
135+
common_client_tag: ${{ inputs.common_client_tag }}
136+
client_source: ${{ inputs.client_source }}
137+
hive_version: ${{ inputs.hive_version }}
138+
goproxy: ${{ env.GOPROXY }}
139+
test:
140+
timeout-minutes: 540 # 9 hours
141+
needs: prepare
142+
runs-on: >-
143+
${{
144+
matrix.simulator == 'ethereum/rpc-compat' && 'ubuntu-latest' ||
145+
contains(matrix.simulator, 'ethereum/eest/') && 'self-hosted-ghr-size-m-x64' ||
146+
'ubuntu-latest'
147+
}}
148+
concurrency:
149+
group: >-
150+
${{ github.head_ref || inputs }}-${{ matrix.client }}-${{ matrix.simulator }}
151+
strategy:
152+
fail-fast: false
153+
matrix:
154+
client: >-
155+
${{
156+
fromJSON(format('[{0}]', inputs.client || '
157+
"besu",
158+
"erigon",
159+
"go-ethereum",
160+
"nethermind",
161+
"nimbus-el",
162+
"reth"
163+
'))}}
164+
simulator: >-
165+
${{
166+
fromJSON(format('[{0}]', inputs.simulator || '
167+
"ethereum/eest/consume-engine",
168+
"ethereum/eest/consume-rlp"
169+
'))}}
170+
steps:
171+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
172+
- uses: ethpandaops/hive-github-action/helpers/self-hosted-runner-dependencies@a9ec89442df18ee579d3179b76c47f5f93954307 # v0.4.0
173+
if: runner.environment != 'github-hosted'
174+
- uses: ethpandaops/actions/docker-login@a91b7a8dd6a264f5e845ac2aa52d2d6f24e6d01d
175+
with:
176+
username: ethpandaops
177+
password: ${{ secrets.DOCKERHUB_TOKEN }}
178+
- uses: ethpandaops/hive-github-action@a9ec89442df18ee579d3179b76c47f5f93954307 # v0.4.0
179+
with:
180+
hive_repository: ${{ needs.prepare.outputs.hive_repo }}
181+
hive_version: ${{ needs.prepare.outputs.hive_tag }}
182+
client: ${{ matrix.client }}
183+
simulator: ${{ matrix.simulator }}
184+
client_config: ${{ needs.prepare.outputs.client_config }}
185+
extra_flags: >-
186+
${{ env.GLOBAL_EXTRA_FLAGS }}
187+
${{ matrix.simulator == 'ethereum/rpc-compat' && env.RPC_COMPAT_FLAGS || '' }}
188+
${{ matrix.simulator == 'ethereum/eest/consume-engine' && env.EEST_ENGINE_FLAGS || '' }}
189+
${{ matrix.simulator == 'ethereum/eest/consume-rlp' && env.EEST_RLP_FLAGS || '' }}
190+
s3_upload: true
191+
s3_bucket: ${{ env.S3_BUCKET }}
192+
s3_path: ${{ env.S3_PATH }}
193+
s3_public_url: ${{ env.S3_PUBLIC_URL }}
194+
rclone_config: ${{ secrets.HIVE_RCLONE_CONFIG }}
195+
rclone_version: ${{ env.INSTALL_RCLONE_VERSION }}
196+
workflow_artifact_upload: true
197+
website_upload: true
Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
name: Ansible lint
2+
on:
3+
pull_request:
4+
paths:
5+
- 'ansible/**'
6+
- '.tool-versions'
7+
- '.github/actions/**'
8+
- '.github/workflows/lint-ansible.yaml'
9+
push:
10+
branches:
11+
- master
12+
paths:
13+
- 'ansible/**'
14+
- '.tool-versions'
15+
- '.github/actions/**'
16+
- '.github/workflows/lint-ansible.yaml'
17+
18+
jobs:
19+
ansible-lint:
20+
runs-on: ubuntu-latest
21+
steps:
22+
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
23+
- uses: ./.github/actions/setup
24+
- name: Install ansible role/collection dependencies
25+
working-directory: ./ansible
26+
run: ./install_dependencies.sh
27+
- name: Lint
28+
working-directory: ./ansible
29+
run: >
30+
ansible-lint playbook.yaml
31+
--nocolor
32+
--exclude vendor
33+
--exclude '*.sops.yaml'
34+
--profile production
35+
--skip-list 'name[play]'
36+
--skip-list 'meta-no-info'
37+
--skip-list 'yaml[line-length]'
38+
--skip-list 'command-instead-of-shell'

.github/workflows/lint-helm.yaml

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
name: Helm lint
2+
3+
on:
4+
pull_request:
5+
paths:
6+
- 'kubernetes/**'
7+
- '.tool-versions'
8+
- '.github/actions/**'
9+
- '.github/workflows/lint-helm.yaml'
10+
push:
11+
branches:
12+
- master
13+
paths:
14+
- 'kubernetes/**'
15+
- '.tool-versions'
16+
- '.github/actions/**'
17+
- '.github/workflows/lint-helm.yaml'
18+
19+
jobs:
20+
helm-lint:
21+
runs-on: ubuntu-latest
22+
steps:
23+
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
24+
- uses: ./.github/actions/setup
25+
- name: Check if kubernetes/*/* is not empty
26+
id: check-kubernetes-directory
27+
run: |
28+
if [ "$(ls -A kubernetes/*/* 2>/dev/null)" ]; then
29+
echo "Kubernetes directory is not empty."
30+
echo "::set-output name=not_empty::true"
31+
else
32+
echo "Kubernetes directory is empty."
33+
echo "::set-output name=not_empty::false"
34+
fi
35+
36+
- name: Lint
37+
run: |
38+
if ${{ steps.check-kubernetes-directory.outputs.not_empty }}; then
39+
helm lint kubernetes/*/*
40+
else
41+
echo "Skipping Helm lint because kubernetes/*/* is empty."
42+
fi
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
name: Terraform lint
2+
on:
3+
pull_request:
4+
paths:
5+
- 'terraform/**'
6+
- '.tool-versions'
7+
- '.github/actions/**'
8+
- '.github/workflows/lint-terraform.yaml'
9+
push:
10+
branches:
11+
- master
12+
paths:
13+
- 'terraform/**'
14+
- '.tool-versions'
15+
- '.github/actions/**'
16+
- '.github/workflows/lint-terraform.yaml'
17+
18+
jobs:
19+
terraform-lint:
20+
runs-on: ubuntu-latest
21+
steps:
22+
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
23+
- uses: ./.github/actions/setup
24+
- name: Lint
25+
working-directory: ./terraform
26+
run: >
27+
terraform fmt --recursive --check --list=true --diff

0 commit comments

Comments
 (0)