Skip to content

Commit 8f511b4

Browse files
authored
[DOCS] ISMP (#74)
1 parent 94c9337 commit 8f511b4

Some content is hidden

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

59 files changed

+10903
-100
lines changed

.github/workflows/ci.yml

+7-3
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,8 @@ env:
2222
jobs:
2323
check-wasm:
2424
name: Check Wasm Crates
25-
runs-on: self-hosted
25+
runs-on: arc-runner-set
26+
if: github.event.pull_request.draft == false
2627
strategy:
2728
matrix:
2829
crate: [messier-runtime, gargantua-runtime]
@@ -57,7 +58,8 @@ jobs:
5758
5859
check-workspace:
5960
name: Check Workspace
60-
runs-on: self-hosted
61+
runs-on: arc-runner-set
62+
if: github.event.pull_request.draft == false
6163
steps:
6264
- uses: actions/checkout@v3
6365
with:
@@ -93,6 +95,7 @@ jobs:
9395
fmt:
9496
name: Cargo fmt
9597
runs-on: ubuntu-latest
98+
if: github.event.pull_request.draft == false
9699
steps:
97100
- uses: actions/checkout@v3
98101

@@ -106,7 +109,7 @@ jobs:
106109

107110
unit-tests:
108111
name: Unit Tests
109-
runs-on: self-hosted
112+
runs-on: arc-runner-set
110113
if: github.event.pull_request.draft == false
111114
steps:
112115
- name: Checkout sources
@@ -226,6 +229,7 @@ jobs:
226229
check-solidity:
227230
name: Check ismp-solidity
228231
runs-on: ubuntu-latest
232+
if: github.event.pull_request.draft == false
229233
steps:
230234
- uses: actions/checkout@v3
231235
with:

.github/workflows/docker.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ jobs:
3636

3737
- name: Build
3838
run: |
39-
cargo +nightly build --release -p hyperbridge --features sepolia
39+
cargo +nightly build --release -p hyperbridge
4040
mv ./target/release/hyperbridge ./
4141
4242
- name: Install Cargo get

.github/workflows/docs.yml

+65
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
1+
# Simple workflow for deploying static content to GitHub Pages
2+
name: Deploy Documentation
3+
4+
on:
5+
# Runs on pushes targeting the default branch
6+
push:
7+
branches: ['main']
8+
9+
# Allows you to run this workflow manually from the Actions tab
10+
workflow_dispatch:
11+
12+
# Sets the GITHUB_TOKEN permissions to allow deployment to GitHub Pages
13+
permissions:
14+
contents: read
15+
pages: write
16+
id-token: write
17+
18+
# Allow one concurrent deployment
19+
concurrency:
20+
group: 'pages'
21+
cancel-in-progress: true
22+
23+
env:
24+
GA_ID: ${{ secrets.GA_ID }}
25+
26+
jobs:
27+
# Single deploy job since we're just deploying
28+
deploy:
29+
environment:
30+
name: github-pages
31+
url: ${{ steps.deployment.outputs.page_url }}
32+
runs-on: ubuntu-latest
33+
defaults:
34+
run:
35+
working-directory: ./docs
36+
steps:
37+
- name: Checkout
38+
uses: actions/checkout@v4
39+
40+
- name: Set up Node
41+
uses: actions/setup-node@v3
42+
43+
with:
44+
node-version: 18
45+
cache: "npm"
46+
cache-dependency-path: "docs"
47+
48+
- name: Install dependencies
49+
run: npm install
50+
51+
- name: Build
52+
run: npm run build
53+
54+
- name: Setup Pages
55+
uses: actions/configure-pages@v3
56+
57+
- name: Upload artifact
58+
uses: actions/upload-pages-artifact@v2
59+
with:
60+
# Upload dist repository
61+
path: './docs/dist'
62+
63+
- name: Deploy to GitHub Pages
64+
id: deployment
65+
uses: actions/deploy-pages@v2

.gitignore

+3-1
Original file line numberDiff line numberDiff line change
@@ -14,4 +14,6 @@
1414
evm/out/
1515
evm/cache/
1616
evm/broadcast/
17-
evm/integration-tests/target/
17+
evm/integration-tests/target/
18+
19+
.uuid*

README.md

+118-6
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,123 @@
11
# Hyperbridge
2-
Hyperbridge is a hyper-scalable, interoperability coprocessor.
2+
Hyperbridge is a hyper-scalable coprocessor for cryptographically secure, cross-chain interoperability.
3+
4+
## Docker
5+
6+
Hyperbridge is available at the official docker repository [`polytopelabs/hyperbridge`](https://hub.docker.com/r/polytopelabs/hyperbridge)
7+
8+
```bash
9+
docker run polytopelabs/hyperbridge:latest --chain=messier
10+
```
11+
12+
## Prebuilt Binaries
13+
14+
You can install a prebuilt binary for the hyperbridge node with the following bash script
15+
16+
```bash
17+
wget -q --show-progress https://github.com/polytope-labs/hyperbridge/releases/download/${latest-tag}/hyperbridge-x86_64-unknown-linux-gnu.tar.gz
18+
tar -xvzf hyperbridge-x86_64-unknown-linux-gnu.tar.gz
19+
# copy to $PATH
20+
cp hyperbridge-x86_64-unknown-linux-gnu/hyperbridge $HOME/.local/bin/
21+
```
22+
23+
or a 1-liner shell script
24+
25+
```bash
26+
curl --proto '=https' --tlsv1.2 -LsSf https://github.com/polytope-labs/hyperbridge/releases/download/${latest-tag}/hyperbridge-installer.sh | sh
27+
```
28+
29+
## Building from source
30+
31+
You can follow the steps below if you'd prefer to build the hyperbridge node from source:
32+
33+
34+
### Install Dependencies
35+
36+
Building the hyperbridge node requires some dependencies
37+
38+
- git
39+
- clang
40+
- curl
41+
- make
42+
- build-essential
43+
- libssl-dev
44+
- llvm
45+
- libudev-dev
46+
- protobuf-compiler
47+
48+
Debian/Ubuntu
49+
50+
```bash
51+
sudo apt install --assume-yes git clang curl libssl-dev llvm libudev-dev make protobuf-compiler
52+
```
53+
Arch
54+
55+
```bash
56+
pacman -Syu --needed --noconfirm curl git clang make protobuf
57+
```
58+
Fedora
59+
60+
```bash
61+
sudo dnf update
62+
sudo dnf install clang curl git openssl-devel make protobuf-compiler
63+
```
64+
Opensuse
65+
66+
```bash
67+
sudo zypper install clang curl git openssl-devel llvm-devel libudev-devel make protobuf
68+
```
69+
70+
### Install rust compiler
71+
72+
If you don't have an already existing rust installation, you can install it using the one-liner below. Follow the prompts displayed to proceed with a default installation.
73+
74+
```bash
75+
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
76+
```
77+
78+
### Install WebAssembly target
79+
80+
Hyperbridge's blockchain runtime compiles to wasm which allows it's code to be forklessly upgraded. In order to build hyperbridge we need the wasm toolchain installed.
81+
82+
```bash
83+
rustup update nightly
84+
rustup target add wasm32-unknown-unknown --toolchain nightly
85+
```
86+
87+
### Clone the repo
88+
89+
Download a local copy of the repo and checkout the latest release tag
90+
91+
```bash
92+
git clone https://github.com/polytope-labs/hyperbridge.git
93+
cd ./hyperbidge
94+
git checkout ${latest-tag}
95+
```
96+
97+
### Build the node
98+
99+
```bash
100+
cargo build --release -p hyperbridge
101+
```
102+
103+
## Running the node
104+
105+
```bash
106+
hyperbridge --chain=messier --enable-offchain-indexing --base-path=$HOME/.hyperbridge --pruning-archive
107+
```
3108

4109
## Running a local tesnet with zombienet
5-
1. Download the zombienet binary for your os from https://github.com/paritytech/zombienet
6-
2. Run `./zombienet spawn --provider native ./scripts/zombienet/local-testnet.toml`
110+
Download the zombienet binary for your operating system [here](https://github.com/paritytech/zombienet).
111+
112+
```bash
113+
zombienet spawn --provider native ./scripts/zombienet/local-testnet.toml
114+
```
7115

8116
## Running a local testnet with docker
9-
1. Build the hyperbridge docker image by running `docker build -t hyperbridge -f ./scripts/docker/Dockerfile .`
10-
2. Navigate to `scripts/parachain-launch`
11-
3. Run `docker compose up`
117+
Build the and run the hyperbridge docker image locally by running
118+
119+
```bash
120+
docker build -t hyperbridge -f ./scripts/docker/Dockerfile .
121+
cd scripts/parachain-launch
122+
docker compose up
123+
```

0 commit comments

Comments
 (0)