Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feat/network toggle #234

Merged
merged 45 commits into from
Dec 6, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
45 commits
Select commit Hold shift + click to select a range
cfc13c1
Added submodule at web3/contracts/utils/diamonds
mrk-hub Oct 25, 2024
d419ba9
Added test helpers
mrk-hub Oct 25, 2024
900a998
Terminus Tests added
mrk-hub Oct 26, 2024
85f1d98
Terminus.test.ts migrated
mrk-hub Oct 28, 2024
23a367b
feat: balance endpoint
gabrieltemtsen Nov 1, 2024
25f9d48
Updated Makefile with generating bindings for terminus and diamonds c…
mrk-hub Nov 4, 2024
a553360
Added deploy-terminus.md
mrk-hub Nov 4, 2024
cd82129
Updated deploy-temrinus.md
mrk-hub Nov 4, 2024
545307d
Merge remote-tracking branch 'origin/main' into security/terminus
mrk-hub Nov 4, 2024
8e3df63
Updated test_web3.yml to check submodules
mrk-hub Nov 5, 2024
635c784
Update build.yml
mrk-hub Nov 5, 2024
6a52f0e
test_web3.yml
mrk-hub Nov 5, 2024
1d14356
Robots workflow
kompotkot Nov 11, 2024
2f65d93
Merge pull request #179 from G7DAO/robots-txt
kompotkot Nov 11, 2024
ab8c397
Updated IStaker.sol
mrk-hub Nov 19, 2024
9825564
Updated test deployment scipt
mrk-hub Nov 19, 2024
8bcdd0f
Updated terminus commands
zomglings Nov 21, 2024
faa17bb
Merge pull request #167 from G7DAO/security/terminus
zomglings Nov 21, 2024
7701e36
Merge pull request #188 from G7DAO/staker-script-interface
zomglings Nov 21, 2024
40e6f40
Add mainnet brige.
Nov 22, 2024
c21fb65
Added gitmodule to make build
mrk-hub Nov 22, 2024
2cf1f94
Merge pull request #201 from G7DAO/submodule/initialize
mrk-hub Nov 22, 2024
822ba4d
Bump version.
Nov 25, 2024
c76ca64
updated code review: getSigner balance and return address
gabrieltemtsen Nov 25, 2024
a18786c
Delete unused values.
Nov 25, 2024
50ecac2
Pin seer version.
Nov 25, 2024
110f032
Merge pull request #200 from G7DAO/bridge-chains
Andrei-Dolgolev Nov 25, 2024
58b6af7
Unpin seer.
Nov 25, 2024
691e617
Merge pull request #207 from G7DAO/unpin-seer-version
Andrei-Dolgolev Nov 25, 2024
473d485
Merge pull request #164 from gabrieltemtsen/add-faucet-balance-endpoint
karacurt Nov 26, 2024
05c4b20
Fix bridge
karacurt Nov 5, 2024
289bfe6
Fix: bridge CLI ux
karacurt Nov 26, 2024
73c85e8
Merge pull request #212 from G7DAO/fix/bridge-cli
karacurt Nov 26, 2024
213ec04
Manual branch workflow deployment
kompotkot Dec 5, 2024
030cd37
Names for workflows
kompotkot Dec 5, 2024
d97be9d
Merge pull request #228 from G7DAO/manual-branch-deploy
kompotkot Dec 5, 2024
9c386e9
Unified naming of workflows
kompotkot Dec 5, 2024
90498b9
Specific branch in path
kompotkot Dec 5, 2024
d53bc20
Fix branch usage as variables
kompotkot Dec 5, 2024
46a2edd
Build of WB dashboard with env vars
kompotkot Dec 6, 2024
22e0c8e
Reduced number of env vars
kompotkot Dec 6, 2024
248bb3d
added env variables
elclandestin0 Dec 6, 2024
2f6be7f
updated variables
elclandestin0 Dec 6, 2024
f9b5773
Vite env var
kompotkot Dec 6, 2024
3ada1d2
Merge remote-tracking branch 'origin/nb-rpc-uri-dashboard-build' into…
elclandestin0 Dec 6, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 32 additions & 0 deletions .github/workflows/build_prod_wb-dashboard.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: Build prod WB dashboard

on:
pull_request:
branches:
- "main"
- "staging"
paths:
- ".github/workflows/build_prod_wb-dashboard.yml"
- "webapps/world-builder-dashboard/**"

jobs:
build_prod_wb-dashboard:
runs-on: ubuntu-latest

steps:
- name: Checkout repository and main branch
uses: actions/checkout@v2

- name: Set up node.js
uses: actions/setup-node@v3
with:
node-version: "20.14.0"

- name: Build frontend
working-directory: ./webapps/world-builder-dashboard
env:
VITE_NB_JSON_RPC_URI: ${{ secrets.VITE_NB_JSON_RPC_URI }}
VITE_NB_WB_DASHBOARD_ACCESS_ID: ${{ secrets.VITE_NB_WB_DASHBOARD_ACCESS_ID }}
run: |
npm install
npm run build
14 changes: 10 additions & 4 deletions .github/workflows/build.yml → .github/workflows/build_web3.yml
Original file line number Diff line number Diff line change
@@ -1,15 +1,21 @@
name: Build
name: Build Smart Contracts

on:
pull_request:
branches:
- main
paths:
- '.github/workflows/build_web3.yml'
- 'web3/**'

jobs:
build:
build_web3:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v3
- name: Checkout
uses: actions/checkout@v3
with:
submodules: recursive # Ensure submodules are checked out and
- name: Install Node.js
uses: actions/setup-node@v3
with:
Expand All @@ -31,4 +37,4 @@ jobs:
run: go install github.com/G7DAO/seer@latest
- name: Build everything
run: |
make
make
53 changes: 53 additions & 0 deletions .github/workflows/deploy_manual_branch_wb-dashboard.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
name: Manual Deploy branch WB dashboard

on:
workflow_dispatch: # Allow manual trigger
inputs:
branch:
description: "Branch to deploy"
required: true
default: "staging"

jobs:
deploy_manual_branch_wb-dashboard:
runs-on: ubuntu-latest

steps:
- name: Show branch name
run: |
echo "Running manual deployment for ${{ github.event.inputs.branch || github.event.pull_request.head.ref }} branch"

- name: Checkout repository and main branch
uses: actions/checkout@v2
with:
ref: ${{ github.event.inputs.branch || github.event.pull_request.head.ref }}

- name: Set up node.js
uses: actions/setup-node@v3
with:
node-version: "20.14.0"

- name: Install and build staging app
working-directory: ./webapps/world-builder-dashboard
env:
VITE_NB_JSON_RPC_URI: ${{ secrets.VITE_NB_JSON_RPC_URI }}
VITE_NB_WB_DASHBOARD_ACCESS_ID: ${{ secrets.VITE_NB_WB_DASHBOARD_ACCESS_ID }}
VITE_BUILD_TARGET: ${{ github.event.inputs.branch || github.event.pull_request.head.ref }}
run: |
npm install
npm run build

- name: Update robots.txt, block alpha for crawlers
working-directory: ./webapps/world-builder-dashboard/dist
run: |
sed -i "s/Disallow:.*/Disallow: \//" robots.txt

- name: Upload static site to S3 bucket and invalidate CloudFront cache
working-directory: ./webapps/world-builder-dashboard
env:
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
AWS_DEFAULT_REGION: ${{ secrets.AWS_DEFAULT_REGION }}
run: |
aws s3 sync ./dist ${{ secrets.AWS_FRONTEND_BUCKET_WB_DASHBOARD_BRANCH }}/${{ github.event.inputs.branch || github.event.pull_request.head.ref }} --delete
aws cloudfront create-invalidation --distribution-id ${{ secrets.AWS_DISTRIBUTION_ID_WB_DASHBOARD_BRANCH }} --paths '/${{ github.event.inputs.branch || github.event.pull_request.head.ref }}/*'
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@ on:
branches:
- main
paths:
- '.github/workflows/prod_deploy_protocol-api.yml'
- '.github/workflows/deploy_prod_protocol-api.yml'
- "api/**"

jobs:
prod_deploy_protocol-api:
deploy_prod_protocol-api:
runs-on: ubuntu-latest

steps:
Expand Down
42 changes: 42 additions & 0 deletions .github/workflows/deploy_prod_wb-dashboard.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
name: Deploy prod WB dashboard

on:
push:
branches:
- main
paths:
- ".github/workflows/deploy_prod_wb-dashboard.yml"
- "webapps/world-builder-dashboard/**"

jobs:
deploy_prod_wb-dashboard:
runs-on: ubuntu-latest

steps:
- name: Checkout repository and main branch
uses: actions/checkout@v2
with:
ref: main

- name: Set up node.js
uses: actions/setup-node@v3
with:
node-version: "20.14.0"

- name: Install and build production app
working-directory: ./webapps/world-builder-dashboard
env:
VITE_NB_JSON_RPC_URI: ${{ secrets.VITE_NB_JSON_RPC_URI }}
VITE_NB_WB_DASHBOARD_ACCESS_ID: ${{ secrets.VITE_NB_WB_DASHBOARD_ACCESS_ID }}
run: |
npm install
npm run build

- name: Publish to CloudFlare Page
uses: cloudflare/pages-action@v1
with:
apiToken: ${{ secrets.CF_API_TOKEN_PROD }}
accountId: ${{ secrets.CF_ACCOUNT_ID_PROD }}
projectName: ${{ secrets.CF_PROJECT_NAME_WB_DASHBOARD_PROD }}
directory: ./webapps/world-builder-dashboard/dist
gitHubToken: ${{ secrets.GITHUB_TOKEN }}
48 changes: 48 additions & 0 deletions .github/workflows/deploy_staging_wb-dashboard.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
name: Deploy staging WB dashboard

on:
push:
branches:
- staging
paths:
- ".github/workflows/deploy_staging_wb-dashboard.yml"
- "webapps/world-builder-dashboard/**"

jobs:
deploy_staging_wb-dashboard:
runs-on: ubuntu-latest

steps:
- name: Checkout repository and main branch
uses: actions/checkout@v2
with:
ref: staging

- name: Set up node.js
uses: actions/setup-node@v3
with:
node-version: "20.14.0"

- name: Install and build staging app
working-directory: ./webapps/world-builder-dashboard
env:
VITE_NB_JSON_RPC_URI: ${{ secrets.VITE_NB_JSON_RPC_URI }}
VITE_NB_WB_DASHBOARD_ACCESS_ID: ${{ secrets.VITE_NB_WB_DASHBOARD_ACCESS_ID }}
VITE_BUILD_TARGET: staging
run: |
npm install
npm run build

- name: Update robots.txt, block alpha for crawlers
working-directory: ./webapps/world-builder-dashboard/dist
run: |
sed -i "s/Disallow:.*/Disallow: \//" robots.txt

- name: Publish to CloudFlare Page
uses: cloudflare/pages-action@v1
with:
apiToken: ${{ secrets.CF_API_TOKEN_STAGE }}
accountId: ${{ secrets.CF_ACCOUNT_ID_STAGE }}
projectName: ${{ secrets.CF_PROJECT_NAME_WB_DASHBOARD_STAGE }}
directory: ./webapps/world-builder-dashboard/dist
gitHubToken: ${{ secrets.GITHUB_TOKEN }}
26 changes: 0 additions & 26 deletions .github/workflows/prod_build_wb-dashboard.yml

This file was deleted.

37 changes: 0 additions & 37 deletions .github/workflows/prod_deploy_wb-dashboard.yml

This file was deleted.

4 changes: 2 additions & 2 deletions .github/workflows/release-game7.yml
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
name: Prepare release
name: Prepare release game7 app

on:
push:
tags:
- "game7-v*"

jobs:
create_release:
release-game7:
runs-on: ubuntu-20.04
steps:
- uses: actions/create-release@v1
Expand Down
42 changes: 0 additions & 42 deletions .github/workflows/staging_deploy_wb-dashboard.yml

This file was deleted.

4 changes: 3 additions & 1 deletion .github/workflows/test_web3.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Smart Contracts Test
name: Test Smart Contracts

on:
pull_request:
Expand All @@ -14,6 +14,8 @@ jobs:
steps:
- name: Checkout
uses: actions/checkout@v3
with:
submodules: recursive # Ensure submodules are checked out and

- name: Install Foundry
uses: foundry-rs/foundry-toolchain@v1
Expand Down
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
[submodule "web3/lib/forge-std"]
path = web3/lib/forge-std
url = https://github.com/foundry-rs/forge-std
[submodule "web3/contracts/utils/diamonds"]
path = web3/contracts/utils/diamonds
url = https://github.com/mudgen/diamond-3-hardhat
Loading
Loading