Add transaction types for gas calculation in mod.rs #85
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Run Kari Node | |
on: | |
push: | |
branches: [ "dev" ] | |
tags: "v*" | |
pull_request: | |
branches: [ "dev" ] | |
env: | |
CARGO_TERM_COLOR: always | |
MNEMONIC_LENGTH: 24 # Set fixed mnemonic length | |
NETWORK_TYPE: devnet | |
RPC_PORT: 3031 | |
NETWORK_DOMAIN: devnet.kari.network | |
permissions: | |
contents: write | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
submodules: 'recursive' # Add this to fetch submodules | |
- name: Install Rust toolchain | |
uses: actions-rs/toolchain@v1 | |
with: | |
toolchain: nightly | |
override: true | |
- name: Cache dependencies | |
uses: actions/cache@v2 | |
with: | |
path: | | |
~/.cargo/registry | |
~/.cargo/git | |
target | |
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }} | |
- name: Build Release | |
run: cargo build --release | |
- name: Generate Wallet | |
run: | | |
echo "24" | cargo run --release --bin kari keytool generate | |
- name: Run Kari Node | |
timeout-minutes: 15 # Prevent infinite running | |
continue-on-error: true # Allow workflow to continue even if node exits | |
run: | | |
# Start Kari node with input parameters | |
# 1: Node type | |
# 3031: Port number | |
# devnet.kanari.network: Network address | |
(echo "1" && echo "3031" && echo "devnet.kanari.network") | cargo run --release --bin kari start & | |
# Store process ID | |
KARI_PID=$! | |
# Wait for node to initialize (30 seconds) | |
sleep 30 | |
# Kill the process | |
kill $KARI_PID || true | |