Skip to content

Commit 45316db

Browse files
authored
feat: some basic info on the readme (#741)
* feat: section to start app locally * feat: prerequisites section * fix: don't mention the build * feat: mention pnpm stop-db * fix: use spiritnet on env example
1 parent e0702a9 commit 45316db

File tree

2 files changed

+43
-2
lines changed

2 files changed

+43
-2
lines changed

.env.example

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
PORT=3000
22
URL=http://127.0.0.1:3000
33
DATABASE_URI=postgres://postgres:postgres@localhost:5432/postgres
4-
SUBSCAN_NETWORK=kilt-testnet
4+
SUBSCAN_NETWORK=spiritnet
55
SECRET_SUBSCAN=
6-
BLOCKCHAIN_ENDPOINT=wss://peregrine.kilt.io
6+
BLOCKCHAIN_ENDPOINT=wss://kilt-rpc.dwellir.com
77
DID=
88
SECRET_PAYER_MNEMONIC=
99
SECRET_AUTHENTICATION_MNEMONIC=

README.md

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,44 @@
11
# ctypehub
22

33
The source code of https://ctypehub.galaniprojects.de
4+
5+
### Prerequisites
6+
7+
Make sure you installed these required software before running this project:
8+
9+
- [Node.js](https://nodejs.org/en/download/prebuilt-installer)
10+
- [pnpm](https://pnpm.io/installation#using-corepack)
11+
- [Docker](https://docs.docker.com/engine/install/)
12+
13+
14+
## Start the app locally:
15+
16+
After having [cloned the repository](https://docs.github.com/en/repositories/creating-and-managing-repositories/cloning-a-repository) on your local machine and defining all environment variables according to the `.env.example`, to start the app locally follow this steps.
17+
18+
1. Make sure you have all dependencies installed, running:
19+
20+
```
21+
pnpm install
22+
```
23+
24+
2. Start the database the app will use, running:
25+
26+
```
27+
pnpm start-db
28+
```
29+
_The Docker daemon needs to be running for this to work_
30+
31+
If there is already a postgres container running, with an incompatible database, you can stop it with `pnpm stop-db`.
32+
33+
3. Enter the dev watch mode from astro, running:
34+
35+
```
36+
pnpm dev
37+
```
38+
39+
Now you can see the logs of the backend on the terminal and visit the frontend under the URL specified by the variable `URL` from the `.env`-file.
40+
(By default http://localhost:3000)
41+
42+
The database should start to populate from the configured indexer.
43+
44+

0 commit comments

Comments
 (0)