Skip to content

Commit b9642a1

Browse files
committed
docs: added deployment
1 parent a8d4723 commit b9642a1

File tree

1 file changed

+18
-1
lines changed

1 file changed

+18
-1
lines changed

README.md

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -183,11 +183,28 @@ To learn more about the algorithm the calculation of the score, check:
183183
- [Documentation](./packages/nimiq-validator-trustscore/README.md).
184184
- [`nimiq-validator-trustscore`](https://www.nimiq.com/developers/learn/validator-trustscore) package.
185185

186-
#### Development
186+
## Development
187187

188188
Once it is cloned and installed the dependencies, you must run:
189189

190190
```bash
191191
pnpm db:generate
192192
pnpm dev # or pnpm dev:local to use the local database
193193
```
194+
195+
## Deployment
196+
197+
The deployment is handled by [`NuxtHub Action`](./.github/workflows/nuxt-hub.yml).
198+
199+
There are 4 different environments:
200+
201+
| Nuxt Hub Env | GitHub Env | Dashboard URL | Trigger |
202+
| ------------ | -------------------- | -------------------------------------------------------------------------- | ----------------------------- |
203+
| `production` | `production-mainnet` | [Validators API Mainnet](https://validators-api-mainnet.pages.dev) | Push to `main` branch |
204+
| `production` | `production-testnet` | [Validators API Testnet](https://validators-api-testnet.pages.dev) | Push to `main` branch |
205+
| `preview` | `preview-mainnet` | [Validators API Mainnet Preview](https://validators-api-preview.pages.dev) | Push any commit to any branch |
206+
| `preview` | `preview-testnet` | [Validators API Testnet Preview](https://validators-api-preview.pages.dev) | Push any commit to any branch |
207+
208+
Each Nuxt Hub environment has its own database, so effectively we have 4 different databases and there 4 tasks in the [`sync.yml`](./.github/workflows/sync.yml) workflow that are responsible for syncing the data from the Nimiq network to the database.
209+
210+
**Write operations to `main` are restricted**, only via PR.

0 commit comments

Comments
 (0)