Skip to content

Commit

Permalink
cli: add dump-bin-put
Browse files Browse the repository at this point in the history
This command is used for keep container with blocks for
blockfetcher updated.

Close #3578

Signed-off-by: Ekaterina Pavlova <ekt@morphbits.io>
README: add archival notice (#520)

People are likely to find this repo and we better have some directions for them.

Signed-off-by: Roman Khimov <roman@nspcc.ru>
Signed-off-by: Ekaterina Pavlova <ekt@morphbits.io>
  • Loading branch information
AliceInHunterland committed Sep 27, 2024
1 parent e1d5ac8 commit f20aa41
Show file tree
Hide file tree
Showing 4 changed files with 463 additions and 1 deletion.
60 changes: 60 additions & 0 deletions .github/workflows/update_blockfetcher_db.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
name: Build neo-go Binary and Run Dump Put Job

on:
schedule:
- cron: "0 */3 * * *"
workflow_dispatch:

jobs:
build_and_run:
name: Build and Run neo-go db dump-bin-put
runs-on: ubuntu-22.04
strategy:
matrix:
network:
- { name: "MainNet", cid: "EPGuD26wYgQJbmDdVBoYoNZiMKHwFMJT3A5WqPjdUHxH", rpc: "https://rpc10.n3.nspcc.ru:10331" }
- { name: "TestNet", cid: "testnet-cid", rpc: "https://rpc.t5.n3.nspcc.ru:20331" }
fail-fast: false

steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: '1.23'

- name: Install dependencies
run: sudo apt-get install -y build-essential

- name: Build CLI
run: |
git clone https://github.com/nspcc-dev/neo-go.git
cd neo-go
make build
cp ./bin/neo-go ../bin/neo-go # Copy the binary to a bin directory for later use
- name: Create wallet JSON file
run: |
echo "${{ secrets.WALLET_JSON_CONTENT }}" > ./wallet.json
- name: Create wallet-config.yml
run: |
echo "Path: \"$PWD/wallet.json\"" > ./wallet-config.yml
echo "Password: \"$WALLET_PASSWORD\"" >> ./wallet-config.yml
- name: Run neo-go db dump-bin-put for ${{ matrix.network.name }}
run: |
echo "Running neo-go db dump-bin-put on network: ${{ matrix.network.name }} with CID: ${{ matrix.network.cid }} and RPC: ${{ matrix.network.rpc }}"
./bin/neo-go db dump-bin-put \
--cid ${{ matrix.network.cid }} \
--wallet-config ./wallet-config.yml \
--block-attribute "block" \
--index-attribute "index" \
--rpc-endpoint ${{ matrix.network.rpc }} \
-rn st1.t5.fs.neo.org:8080
env:
WALLET_PASSWORD: ${{ secrets.WALLET_PASSWORD }}
Loading

0 comments on commit f20aa41

Please sign in to comment.