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

Release: varatube on sails #501

Merged
merged 86 commits into from
Nov 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
86 commits
Select commit Hold shift + click to select a range
f9629af
Fy varaman optimization (#439)
faizov Aug 29, 2024
9773256
Fy varaman optimization (#439) (#440)
faizov Aug 30, 2024
466ea9c
Varaman: fix handle Key (#441)
faizov Aug 30, 2024
63d67de
Merge branch 'release-varaman' into master
faizov Aug 30, 2024
57fce69
Battleship-zk: fix signless gas calculation (#438)
vraja-nayaka Aug 30, 2024
4eadf50
Zk battleship (#372)
MedovTimur Sep 2, 2024
1245527
Battleship-zk: add gtm-id (#443)
vraja-nayaka Sep 2, 2024
ab75078
Battleship-zk: fix signless (#446)
vraja-nayaka Sep 5, 2024
556f1c9
Update tic-tac-toe to sails (#424)
MedovTimur Sep 9, 2024
9f414c0
Tic-tac-toe: add salis (#437)
vraja-nayaka Sep 9, 2024
0184804
gasless backend
ElessarST Sep 9, 2024
91804dc
delete dockerfile
ElessarST Sep 9, 2024
96c8364
Fix README (#451)
MedovTimur Sep 9, 2024
8590ea6
add controller for gasless
ElessarST Sep 10, 2024
2aeb1e7
Release `ez-transactions` (#445)
vraja-nayaka Sep 10, 2024
f88f560
Merge branch 'refs/heads/master' into gasless-backend
ElessarST Sep 10, 2024
9d9909e
fix review comments
ElessarST Sep 10, 2024
7e4a14d
fix review comments
ElessarST Sep 10, 2024
0d39955
Merge pull request #450 from gear-foundation/gasless-backend
ElessarST Sep 10, 2024
8acdd2c
Minor corrections zk-battleship contract (#447)
MedovTimur Sep 11, 2024
057f8fd
Bump vara-ui version (#454)
vraja-nayaka Sep 12, 2024
f80c9ca
Racing-car-game: migrate to sails.js (#455)
vraja-nayaka Sep 13, 2024
44fda5e
deleted multitoken & concert (#453)
LouiseMedova Sep 18, 2024
a357635
Fix contracts workflow (#457)
MedovTimur Sep 18, 2024
68d5959
Revision(Deleted unnecessary dapps) (#459)
MedovTimur Sep 19, 2024
4f61017
Varaman: migrate to sails.js (#458)
vraja-nayaka Sep 20, 2024
74917cd
Update VaraMan to sails version (#435)
MedovTimur Sep 20, 2024
b022df7
Update GEAR dependencies to latest tag in contracts
github-actions[bot] Sep 25, 2024
6441c45
Update GEAR dependencies to latest tag in contracts
github-actions[bot] Sep 28, 2024
b90c2c4
feat(frontend): templates (#461)
nikitayutanov Sep 30, 2024
eaecb67
refactor(frontend/ui): merge gear and vara ui wallets (#462)
nikitayutanov Oct 1, 2024
e5b38f0
Update deps (#464)
MedovTimur Oct 3, 2024
81e27b0
refactor(frontend/ui): migrate to `@gear-js/wallet-connect` (#465)
nikitayutanov Oct 4, 2024
00df56b
Add compare sails version
sergeyfilyanin Oct 7, 2024
8a721e6
pr for changes
sergeyfilyanin Oct 7, 2024
73683d8
Update contracts-tests.yml
sergeyfilyanin Oct 7, 2024
6af5c46
Update contracts-tests.yml
sergeyfilyanin Oct 7, 2024
7be00dd
update python version
sergeyfilyanin Oct 7, 2024
b78b306
change runner
sergeyfilyanin Oct 7, 2024
fbf7d67
Update contracts-tests.yml
sergeyfilyanin Oct 7, 2024
be53ab1
Update contracts-tests.yml
sergeyfilyanin Oct 7, 2024
ea30eb1
Update update_gear_version.py
sergeyfilyanin Oct 7, 2024
8c642e5
Update contracts-tests.yml
sergeyfilyanin Oct 7, 2024
c73d80a
Update UpdateGearDependency.yml
sergeyfilyanin Oct 7, 2024
2fdafd2
Update UpdateGearDependency.yml
sergeyfilyanin Oct 7, 2024
588bc3f
Update Cargo.toml
sergeyfilyanin Oct 7, 2024
fea4cbf
Update UpdateGearDependency.yml
sergeyfilyanin Oct 7, 2024
7243c3f
Update Cargo.toml
sergeyfilyanin Oct 7, 2024
f2057d1
Update UpdateGearDependency.yml
sergeyfilyanin Oct 8, 2024
709de33
Update contracts-tests.yml
sergeyfilyanin Oct 8, 2024
ebf517b
Update contracts-tests.yml
sergeyfilyanin Oct 8, 2024
3fc606c
Update UpdateGearDependency.yml
sergeyfilyanin Oct 8, 2024
39ed9ae
Update UpdateGearDependency.yml
sergeyfilyanin Oct 8, 2024
442c75d
Update UpdateGearDependency.yml
sergeyfilyanin Oct 8, 2024
300f2cc
Update UpdateGearDependency.yml
sergeyfilyanin Oct 8, 2024
81f1a50
Update UpdateGearDependency.yml
sergeyfilyanin Oct 8, 2024
1facd8c
Update UpdateGearDependency.yml
sergeyfilyanin Oct 8, 2024
e2df248
Update UpdateGearDependency.yml
sergeyfilyanin Oct 8, 2024
e161d56
Update UpdateGearDependency.yml
sergeyfilyanin Oct 8, 2024
b562c17
Update UpdateGearDependency.yml
sergeyfilyanin Oct 8, 2024
824d19f
Update UpdateGearDependency.yml
sergeyfilyanin Oct 8, 2024
888a105
Update UpdateGearDependency.yml
sergeyfilyanin Oct 8, 2024
d5ab665
Update UpdateGearDependency.yml
sergeyfilyanin Oct 8, 2024
0960224
Update GEAR dependencies (#478)
sergeyfilyanin Oct 8, 2024
0cb4621
Update UpdateGearDependency.yml
sergeyfilyanin Oct 8, 2024
2050adf
Update UpdateGearDependency.yml (#488)
MedovTimur Oct 10, 2024
8633098
Deleted unnecessary xtask (#466)
MedovTimur Oct 10, 2024
6281a64
Lm car races sails (#489)
LouiseMedova Oct 11, 2024
5adf0b7
Create STG-tamagotchi-battle-new.yml
sergeyfilyanin Oct 15, 2024
5e34ece
Varatube: add sails
vraja-nayaka Oct 21, 2024
9ea0a92
Adding battle game contract (#491)
MedovTimur Oct 24, 2024
4128388
Updating contract syndote to sails (#493)
MedovTimur Oct 25, 2024
5c968a3
Adding concert contract (#494)
MedovTimur Oct 25, 2024
b5eb3bd
Update VaraTube to sails version (#436)
MedovTimur Oct 25, 2024
0ab20a6
Battle contract: Health fix for Event::RoundAction (#495)
MedovTimur Oct 28, 2024
c87b6d3
Galactic Express: add sails
vraja-nayaka Oct 29, 2024
031c837
fix ranks
vraja-nayaka Oct 31, 2024
e8653e3
Merge pull request #497 from gear-foundation/vt-galactic-express-add-…
vraja-nayaka Oct 31, 2024
a32f55f
Merge pull request #492 from gear-foundation/vt-varatube-add-sails
vraja-nayaka Oct 31, 2024
4c6afa5
Update galactic express to sails (#463)
MedovTimur Oct 31, 2024
e150f31
Web3 Warriors Battle (#490)
vraja-nayaka Nov 1, 2024
506fc06
Minor fix battle contract (#499)
MedovTimur Nov 1, 2024
abf591a
Updating README.md and Renaming (#496)
MedovTimur Nov 1, 2024
13806db
Create Release-warriors-battle.yml
sergeyfilyanin Nov 2, 2024
4e6bd83
Update Release-warriors-battle.yml
sergeyfilyanin Nov 2, 2024
05f8392
Fix warriors battle (#502)
vraja-nayaka Nov 4, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
5 changes: 3 additions & 2 deletions .github/workflows/Release-DeployBattleshipZk.yml
Original file line number Diff line number Diff line change
Expand Up @@ -71,10 +71,11 @@ jobs:
tags: ${{ needs.prepair.outputs.image_name }}
build-args: |
VITE_NODE_ADDRESS=${{ secrets.VITE_NODE_ADDRESS }}
VITE_CONTRACT_ADDRESS=${{ secrets.VITE_CONTRACT_ADDRESS_BATTLE_ZK }}
VITE_DNS_API_URL=${{ secrets.VITE_DNS_API_URL }}
VITE_DNS_NAME=${{ secrets.VITE_DNS_NAME_BATTLE_ZK }}
VITE_SENTRY_DSN=${{ secrets.VITE_SENTRY_DSN_BATTLE }}
VITE_GASLESS_BACKEND_ADDRESS=${{ secrets.VITE_GASLESS_BACKEND_ADDRESS }}
VITE_GTM_ID=${{ secrets.VITE_GTM_ID_BATTLESHIP }}
VITE_GTM_ID=${{ secrets.VITE_GTM_ID_BATTLESHIP_ZK }}
VITE_ZK_PROOF_BACKEND_ADDRESS=${{ secrets.VITE_ZK_PROOF_BACKEND_ADDRESS_BATTLE }}

deploy-to-k8s:
Expand Down
112 changes: 112 additions & 0 deletions .github/workflows/Release-warriors-battle.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,112 @@
name: Release - Deploy New Tamagotchi/Warriors Battle

on:
workflow_dispatch:

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

env:
ENVIRONMENT: prod
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
AWS_REGION: ${{ secrets.AWS_REGION }}
KUBE_CONFIG_DATA: ${{ secrets.KUBE_CONFIG_DATA }}
KUBECTL_VERSION: "v1.22.17"
KUBE_NAMESPACE: gear-dapps
KUBE_DEPLOYMENT_PREFIX: tamagotchi-battle-new
REGISTRY: ghcr.io/${{ github.repository }}

jobs:
prepair:
runs-on: ubuntu-latest
outputs:
image_name: ${{ steps.image.outputs.image_name }}
steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Get branch
id: branch
run: |
branch_name=${GITHUB_REF#refs/heads/}
echo "branch_name=$branch_name" >> $GITHUB_ENV

- name: Get short SHA
id: sha
run: |
sha_short=$(git rev-parse --short HEAD)
echo "sha_short=$sha_short" >> $GITHUB_ENV

- name: Set IMAGE_NAME
id: image
run: |
image_name=${{ env.REGISTRY }}-${{ env.KUBE_DEPLOYMENT_PREFIX }}:${{ env.branch_name }}-${{ env.sha_short }}
echo "image_name=$image_name" >> $GITHUB_OUTPUT

build-and-push-image:
needs: [prepair]
runs-on: ubuntu-latest
environment: prod
permissions:
contents: read
packages: write
steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Log in to the github container registry
uses: docker/login-action@v3
with:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Build and push image
uses: docker/build-push-action@v5
with:
file: frontend/apps/web3-warriors-battle/Dockerfile
push: true
tags: ${{ needs.prepair.outputs.image_name }}
build-args: |
VITE_DNS_API_URL=${{ secrets.VITE_DNS_API_URL_TESTNET }}
VITE_NODE_ADDRESS=${{ secrets.VITE_NODE_ADDRESS_TESTNET }}
VITE_DNS_NAME=${{ secrets.VITE_DNS_NAME_BATTLE_NEW }}
VITE_SENTRY_DSN=${{ secrets.VITE_SENTRY_DSN }}
VITE_GASLESS_BACKEND_ADDRESS=${{ secrets.VITE_GASLESS_BACKEND_ADDRESS }}

deploy-to-k8s:
needs: [prepair, build-and-push-image]
runs-on: ubuntu-latest
environment: prod
steps:
- name: Configure AWS credentials
uses: aws-actions/configure-aws-credentials@v4
with:
aws-access-key-id: ${{ env.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ env.AWS_SECRET_ACCESS_KEY }}
aws-region: ${{ env.AWS_REGION }}

- name: Update deployment image
uses: kodermax/kubectl-aws-eks@main
with:
args: |
set image deployment/${{ env.KUBE_DEPLOYMENT_PREFIX }}-${{ env.ENVIRONMENT }} \
${{ env.KUBE_DEPLOYMENT_PREFIX }}-${{ env.ENVIRONMENT }}=${{ needs.prepair.outputs.image_name }} \
-n ${{ env.KUBE_NAMESPACE }}

- name: Restart deployment
uses: kodermax/kubectl-aws-eks@main
with:
args: |
rollout restart deployment/${{ env.KUBE_DEPLOYMENT_PREFIX }}-${{ env.ENVIRONMENT }} \
-n ${{ env.KUBE_NAMESPACE }}

- name: Check deployment
uses: kodermax/kubectl-aws-eks@main
with:
args: |
rollout status deployment/${{ env.KUBE_DEPLOYMENT_PREFIX }}-${{ env.ENVIRONMENT }} \
--timeout=240s \
-n ${{ env.KUBE_NAMESPACE }}
3 changes: 2 additions & 1 deletion .github/workflows/STG-DeployBattleshipZk.yml
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,8 @@ jobs:
tags: ${{ needs.prepair.outputs.image_name }}
build-args: |
VITE_NODE_ADDRESS=${{ secrets.VITE_NODE_ADDRESS }}
VITE_CONTRACT_ADDRESS=${{ secrets.VITE_CONTRACT_ADDRESS_BATTLE_ZK }}
VITE_DNS_API_URL=${{ secrets.VITE_DNS_API_URL }}
VITE_DNS_NAME=${{ secrets.VITE_DNS_NAME_BATTLE_ZK }}
VITE_SENTRY_DSN=${{ secrets.VITE_SENTRY_DSN_BATTLE }}
VITE_GASLESS_BACKEND_ADDRESS=${{ secrets.VITE_GASLESS_BACKEND_ADDRESS }}
VITE_ZK_PROOF_BACKEND_ADDRESS=${{ secrets.VITE_ZK_PROOF_BACKEND_ADDRESS_BATTLE }}
Expand Down
117 changes: 117 additions & 0 deletions .github/workflows/STG-tamagotchi-battle-new.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,117 @@
name: Staging - Deploy New Tamagotchi Battle

on:
workflow_dispatch:
push:
branches: ["master", "main"]
paths:
- frontend/apps/web3-warriors-battle/**
- frontend/packages/**

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

env:
ENVIRONMENT: stg
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
AWS_REGION: ${{ secrets.AWS_REGION }}
KUBE_CONFIG_DATA: ${{ secrets.KUBE_CONFIG_DATA }}
KUBECTL_VERSION: "v1.22.17"
KUBE_NAMESPACE: gear-dapps
KUBE_DEPLOYMENT_PREFIX: tamagotchi-battle-new
REGISTRY: ghcr.io/${{ github.repository }}

jobs:
prepair:
runs-on: ubuntu-latest
outputs:
image_name: ${{ steps.image.outputs.image_name }}
steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Get branch
id: branch
run: |
branch_name=${GITHUB_REF#refs/heads/}
echo "branch_name=$branch_name" >> $GITHUB_ENV

- name: Get short SHA
id: sha
run: |
sha_short=$(git rev-parse --short HEAD)
echo "sha_short=$sha_short" >> $GITHUB_ENV

- name: Set IMAGE_NAME
id: image
run: |
image_name=${{ env.REGISTRY }}-${{ env.KUBE_DEPLOYMENT_PREFIX }}:${{ env.branch_name }}-${{ env.sha_short }}
echo "image_name=$image_name" >> $GITHUB_OUTPUT

build-and-push-image:
needs: [prepair]
runs-on: ubuntu-latest
environment: stg
permissions:
contents: read
packages: write
steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Log in to the github container registry
uses: docker/login-action@v3
with:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Build and push image
uses: docker/build-push-action@v5
with:
file: frontend/apps/web3-warriors-battle/Dockerfile
push: true
tags: ${{ needs.prepair.outputs.image_name }}
build-args: |
VITE_DNS_API_URL=${{ secrets.VITE_DNS_API_URL }}
VITE_NODE_ADDRESS=${{ secrets.VITE_NODE_ADDRESS }}
VITE_DNS_NAME=${{ secrets.VITE_DNS_NAME_BATTLE_NEW }}
VITE_SENTRY_DSN=${{ secrets.VITE_SENTRY_DSN }}
VITE_GASLESS_BACKEND_ADDRESS=${{ secrets.VITE_GASLESS_BACKEND_ADDRESS }}

deploy-to-k8s:
needs: [prepair, build-and-push-image]
runs-on: ubuntu-latest
environment: stg
steps:
- name: Configure AWS credentials
uses: aws-actions/configure-aws-credentials@v4
with:
aws-access-key-id: ${{ env.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ env.AWS_SECRET_ACCESS_KEY }}
aws-region: ${{ env.AWS_REGION }}

- name: Update deployment image
uses: kodermax/kubectl-aws-eks@main
with:
args: |
set image deployment/${{ env.KUBE_DEPLOYMENT_PREFIX }}-${{ env.ENVIRONMENT }} \
${{ env.KUBE_DEPLOYMENT_PREFIX }}-${{ env.ENVIRONMENT }}=${{ needs.prepair.outputs.image_name }} \
-n ${{ env.KUBE_NAMESPACE }}

- name: Restart deployment
uses: kodermax/kubectl-aws-eks@main
with:
args: |
rollout restart deployment/${{ env.KUBE_DEPLOYMENT_PREFIX }}-${{ env.ENVIRONMENT }} \
-n ${{ env.KUBE_NAMESPACE }}

- name: Check deployment
uses: kodermax/kubectl-aws-eks@main
with:
args: |
rollout status deployment/${{ env.KUBE_DEPLOYMENT_PREFIX }}-${{ env.ENVIRONMENT }} \
--timeout=240s \
-n ${{ env.KUBE_NAMESPACE }}
62 changes: 54 additions & 8 deletions .github/workflows/UpdateGearDependency.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,43 +2,89 @@ name: Update GEAR Dependencies

on:
schedule:
- cron: '0 0 * * *' # Runs every day at midnight
- cron: '0 */2 * * *' # Runs every 30 minutes
workflow_dispatch: # Allows manual triggering of the workflow

defaults:
run:
working-directory: scripts

permissions:
contents: write
actions: write
pull-requests: write

jobs:
update-dependencies:
runs-on: ubuntu-latest

steps:
- name: Checkout repository
uses: actions/checkout@v2
uses: actions/checkout@v4
with:
fetch-depth: 0
token: ${{ secrets.UPDATE_GEAR_TAG_TOKEN }}
token: ${{ secrets.WF_SECRET }}

- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: '3.x'

- name: Install GitPython
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install requests packaging gitpython

- name: Check for new tag and update Cargo.toml
env:
GITHUB_TOKEN: ${{ secrets.UPDATE_GEAR_TAG_TOKEN }}
GITHUB_TOKEN: ${{ secrets.WF_SECRET }}
run: |
python update_gear_version.py
if ! git diff --exit-code; then
echo "Changes detected in the repository after running the update_gear_version.py script."

# Configure git
git config user.name "github-actions[bot]"
git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
git add ../contracts/Cargo.toml
git config user.email "github-actions[bot]@users.noreply.github.com"

# Output changes for logging
echo "The following changes were made:"
git diff

# Create a new branch
branch_name="update-gear-dependencies-$(date +%Y%m%d%H%M%S)"
echo "Creating a new branch: $branch_name"
git checkout -b $branch_name

# Remove and update Cargo.lock file
echo "Removing contracts/Cargo.lock"
rm -f ../contracts/Cargo.lock
echo "Updating contracts/Cargo.lock"
cd ../contracts && cargo generate-lockfile

# Stage and commit changes
echo "Staging changed files."
git add Cargo.toml
git add ../.github/workflows/contracts-tests.yml
git add Cargo.lock

echo "Committing changes with message: 'Update GEAR dependencies to latest tag in contracts'"
git commit -m "Update GEAR dependencies to latest tag in contracts"
git push origin master -f

# Check if there's an open PR with the label 'auto-update-gear'
open_prs=$(gh pr list --label "auto-update-gear" --state open --json number --jq '.[].number')

if [ -n "$open_prs" ]; then
echo "An open pull request with the label 'auto-update-gear' already exists. Exiting."
exit 0
fi

# If no matching PR was found, push the branch and create a new PR
echo "Pushing the new branch: $branch_name"
git push origin $branch_name

echo "Creating a new pull request."
gh pr create --title "Update GEAR dependencies" --body "Automatically created pull request to update GEAR dependencies" --base master --head $branch_name --label "auto-update-gear"
else
echo "No changes were detected after running the update_gear_version.py script."
fi
Loading
Loading