Skip to content

Commit 1eca7dd

Browse files
authored
Merge pull request #23 from cloudstruct/feat/update-readme
feat: initial README
2 parents 0014498 + 5bf5474 commit 1eca7dd

File tree

1 file changed

+38
-1
lines changed

1 file changed

+38
-1
lines changed

README.md

Lines changed: 38 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,39 @@
11
# docker-cardano-node
2-
Builds a cardano-node on debian
2+
Builds a Cardano full node from source on Debian. This image attempts to keep
3+
interface compatibility with `inputoutput/cardano-node`, but may diverge
4+
slightly, particularly with any Nix-specific paths.
5+
6+
## Running a node
7+
To run a Cardano full node on mainnet:
8+
```bash
9+
docker run --detach \
10+
--name cardano-node \
11+
-v node-data:/opt/cardano/data \
12+
-v node-ipc:/opt/cardano/ipc \
13+
-p 3001:3001 \
14+
ghcr.io/cloudstruct/cardano-node run
15+
```
16+
The above maps port 3001 on the host to 3001 on the container, suitable
17+
for use as a mainnet relay node.
18+
19+
Node logs can be followed:
20+
```bash
21+
docker logs -f cardano-node
22+
```
23+
## Running the CLI
24+
To run a Cardano CLI command, we use the `node-ipc` volume from our node.
25+
```bash
26+
docker run --rm -ti \
27+
-v node-ipc:/opt/cardano/ipc \
28+
ghcr.io/cloudstruct/cardano-node cli <command>
29+
```
30+
This can be added to a shell alias:
31+
```bash
32+
alias cardano-cli="docker run --rm -ti \
33+
-v node-ipc:/opt/cardano/ipc \
34+
ghcr.io/cloudstruct/cardano-node cli"
35+
```
36+
Now, you can use cardano-cli commands as you would, normally.
37+
```bash
38+
cardano-cli query tip --mainnet
39+
```

0 commit comments

Comments
 (0)