Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
3 changes: 3 additions & 0 deletions .cargo/config.toml
Original file line number Diff line number Diff line change
@@ -1,2 +1,5 @@
[future-incompat-report]
frequency = "never"

[target.aarch64-unknown-linux-gnu]
linker = "aarch64-linux-gnu-gcc"
136 changes: 68 additions & 68 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ zero-prefixed-literal = { level = "allow", priority = 2 } # 00_1000_0
griffin-core = { default-features = false, path = "griffin-core" }
griffin-partner-chains-runtime = { path = "./runtime", default-features = false }
griffin-rpc = { default-features = false, path = "griffin-rpc" }
griffin-wallet = { default-features = false, path = "wallet" }
gpc-wallet = { default-features = false, path = "wallet" }
game = { default-features = false, path = "game" }
clap = { version = "4.5.13" }
derive-new = { version = "0.7.0" }
Expand All @@ -103,6 +103,7 @@ serde_json = { version = "1.0.132", default-features = false, features = [
"alloc",
] }
thiserror = { version = "2.0", default-features = false }
crunchy = { version = "0.2.4", default-features = false }

# substrate dependencies
frame-support = { default-features = false, git = "https://github.com/paritytech/polkadot-sdk.git", tag = "polkadot-stable2506-2" }
Expand Down
10 changes: 6 additions & 4 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,12 @@ COPY griffin-core/ griffin-core/
COPY griffin-rpc/ griffin-rpc/
COPY demo/ demo/
COPY wallet/ wallet/
COPY game/ game/
COPY toolkit/ toolkit/

# Build the node
RUN cargo build --release -p griffin-partner-chains-node
RUN cargo build --release -p griffin-wallet
RUN cargo build --release -p gpc-node
RUN cargo build --release -p gpc-wallet

# Final stage
FROM debian:bullseye-slim
Expand All @@ -45,8 +47,8 @@ curl \
--no-install-recommends && \
rm -rf /var/lib/apt/lists/*

COPY --from=builder /reference-impl/target/release/griffin-partner-chains-node /usr/local/bin
COPY --from=builder /reference-impl/target/release/griffin-wallet /usr/local/bin
COPY --from=builder /reference-impl/target/release/gpc-node /usr/local/bin
COPY --from=builder /reference-impl/target/release/gpc-wallet /usr/local/bin
COPY docker/genesis.json .
COPY docker/examples/ /examples

Expand Down
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,13 +50,13 @@ $ rustup component add rust-src --toolchain stable-x86_64-unknown-linux-gnu
You can build all of the artifacts like the node and the wallet:

```sh
cargo build --release -p griffin-partner-chains-node -p griffin-wallet
cargo build --release -p gpc-node -p gpc-wallet
```

To run use:

```sh
target/release/griffin-partner-chains-node --dev --alice
target/release/gpc-node --dev --alice
```
With this command you can start a local development chain that will use predefined account Alice's keys, which are set in the runtime genesis as the authority keys.

Expand All @@ -65,10 +65,10 @@ With this command you can start a local development chain that will use predefin
You can follow the instructions at [wallet](/wallet/README.md) to interact with the node using the Griffin wallet. Starting from `v0.0.4` the wallet is integrated into the node commands. This means you can use it directly with the node's executable:

```sh
./target/release/griffin-partner-chains-node wallet <wallet-subcommands>
./target/release/gpc-node wallet <wallet-subcommands>
```

> Note: this command only supports the wallet's subcommands. This means options like `--purge-db` are NOT supported. You can manually clean the wallet's database with `rm -r ~/.local/share/griffin-wallet/`. If you have the `griffin-wallet` executable, you can use options and commands like normal.
> Note: this command only supports the wallet's subcommands. This means options like `--purge-db` are NOT supported. You can manually clean the wallet's database with `rm -r ~/.local/share/gpc-wallet/`. If you have the `gpc-wallet` executable, you can use options and commands like normal.

### Build and run with docker

Expand All @@ -92,7 +92,7 @@ The docker utilizes a different `genesis` that sets these two accounts as author
Similarly to the local chain, you can use Griffin wallet to interact with the node using `docker-exec`:

```sh
docker exec gpc-node-1-1 griffin-wallet -e http://localhost:9944 show-all-outputs
docker exec gpc-node-1-1 gpc-wallet -e http://localhost:9944 show-all-outputs
```

Make sure that the endpoint you are connecting to matches the node's being run in the container.
Expand Down
4 changes: 2 additions & 2 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ services:
- "30333:30333"
- "9944:9944"
command: >
griffin-partner-chains-node
gpc-node
--base-path /data/node-1
--chain genesis.json
--alice
Expand All @@ -32,7 +32,7 @@ services:
node-1:
condition: service_healthy
command: >
griffin-partner-chains-node
gpc-node
--base-path /data/node-2
--chain genesis.json
--bob
Expand Down
86 changes: 86 additions & 0 deletions docker/examples/game/1_create_ship.json

Large diffs are not rendered by default.

80 changes: 80 additions & 0 deletions docker/examples/game/2_gather_fuel.json

Large diffs are not rendered by default.

67 changes: 67 additions & 0 deletions docker/examples/game/3_move_ship.json

Large diffs are not rendered by default.

76 changes: 76 additions & 0 deletions docker/examples/game/4_mine_asteria.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docker/examples/hello_world/create_info.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"inputs_info": [
{
"tx_hash": "8544c824cd05d68d25f6e9eed666c113acb7571961a9676a73e5dc8fe06d44ea",
"tx_hash": "8a238075b88aba304618a8795ee1cd2342b181306d371d7233755cc29d1acd36",
"index": 0
}
],
Expand Down
2 changes: 1 addition & 1 deletion docker/examples/hello_world/spend_info.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"inputs_info": [
{
"tx_hash": "06d8b7b4443cd88a4bfee714e04298a66f0a7dec3c64baf14650821c1e9e06e1",
"tx_hash": "5ce04e073452481abf4d237bb9563fa4f4f63c49476a5690b095b5dec7011ee7",
"index": 0,
"redeemer_cbor": "d8799f4d48656c6c6f2c20576f726c6421ff"
}
Expand Down
8 changes: 4 additions & 4 deletions docker/examples/one_shot_mp/tx_info.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"inputs_info": [
{
"tx_hash": "8544c824cd05d68d25f6e9eed666c113acb7571961a9676a73e5dc8fe06d44ea",
"tx_hash": "8a238075b88aba304618a8795ee1cd2342b181306d371d7233755cc29d1acd36",
"index": 0
}
],
Expand All @@ -15,23 +15,23 @@
"assets": [ ["tokenA", 271000000], ["tokenB", 1123581321] ]
},
{
"policy": "23f0316f1a68626b4434ab4dab1ff5224e60bade24f7ed651b7990ca",
"policy": "a76564fb31bd17ebfc8413d364a6141aa745ecc6cc6fdf4aa4e51042",
"assets": [ ["oneShot", 1] ]
}
]
}
],
"mintings_info": [
{
"policy": "23f0316f1a68626b4434ab4dab1ff5224e60bade24f7ed651b7990ca",
"policy": "a76564fb31bd17ebfc8413d364a6141aa745ecc6cc6fdf4aa4e51042",
"assets": [ ["oneShot", 1] ],
"redeemer_cbor": "D87980"
}
],
"scripts_info": [
{
"script_hex": "59026e01010032323232323232323222253330053232323232533300a3370e900018061baa004132533300f001153300c00a161325333010301300213232533300e533300e3370e004900108008a5014a2266e1c0092001323300100100622533301300114a0264a66602066ebcc058c04cdd5180b0010070a511330030030013016001375a601e0022a6601a0162c602200264a66601666e1d2002300d3754002297adef6c60137566022601c6ea8004c8c8cc004004c8cc004004010894ccc04800452f5bded8c0264646464a66602466e45220100002153330123371e91010000210031005133017337606ea4008dd3000998030030019bab3014003375c6024004602c004602800244a666022002298103d87a800013232323253330113372200e0042a66602266e3c01c0084cdd2a40006602c6e980052f5c02980103d87a8000133006006003375660260066eb8c044008c054008c04c004dd7180818069baa004153300b49120657870656374204d696e7428706f6c6963795f696429203d20707572706f736500163756601e60206020602060200046eb0c038004c028dd518068011806180680098041baa001149854cc0192411856616c696461746f722072657475726e65642066616c7365001365649188657870656374205b50616972285f2c207175616e74697479295d203d0a2020202020206d696e740a20202020202020207c3e2076616c75652e66726f6d5f6d696e7465645f76616c75650a20202020202020207c3e2076616c75652e746f6b656e7328706f6c6963795f6964290a20202020202020207c3e20646963742e746f5f70616972732829005734ae7155ceaab9e5573eae815d0aba21",
"script_params_cbor": "9FD8799FD8799F58208544c824cd05d68d25f6e9eed666c113acb7571961a9676a73e5dc8fe06d44eaFF00FFFF"
"script_params_cbor": "9FD8799FD8799F58208A238075B88ABA304618A8795EE1CD2342B181306D371D7233755CC29D1ACD36FF00FFFF"
}
],
"witnesses": [
Expand Down
2 changes: 1 addition & 1 deletion docker/examples/order_book/cancel_info.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"inputs_info": [
{
"tx_hash": "98e7dba69bc843e0d1b547f7159afe0d05d45c469554cd8b837653d380358d5f",
"tx_hash": "86acd70277f1bb6d8a455e0b72a76df14359049ee7b70a1e9a5cb098312af2d8",
"index": 0,
"redeemer_cbor": "d87a81d87980"
}
Expand Down
2 changes: 1 addition & 1 deletion docker/examples/order_book/create_info.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"inputs_info": [
{
"tx_hash": "8544c824cd05d68d25f6e9eed666c113acb7571961a9676a73e5dc8fe06d44ea",
"tx_hash": "8a238075b88aba304618a8795ee1cd2342b181306d371d7233755cc29d1acd36",
"index": 1
}
],
Expand Down
4 changes: 2 additions & 2 deletions docker/examples/order_book/resolve_info.json
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
{
"inputs_info": [
{
"tx_hash": "98e7dba69bc843e0d1b547f7159afe0d05d45c469554cd8b837653d380358d5f",
"tx_hash": "86acd70277f1bb6d8a455e0b72a76df14359049ee7b70a1e9a5cb098312af2d8",
"index": 0,
"redeemer_cbor": "d87a81d87a80"
},
{
"tx_hash": "8544c824cd05d68d25f6e9eed666c113acb7571961a9676a73e5dc8fe06d44ea",
"tx_hash": "8a238075b88aba304618a8795ee1cd2342b181306d371d7233755cc29d1acd36",
"index": 0
}
],
Expand Down
Loading