Update readme to publish required records

This commit is contained in:
Shreerang Kale 2025-07-24 10:03:42 +05:30
parent 4823ca37cf
commit 00cfd280c0
2 changed files with 68 additions and 24 deletions

View File

@ -1,6 +1,6 @@
record: record:
type: PricingRecord type: PricingRecord
for: "webapp-deployment" for: ""
amount: "5" amount: ""
currency: "USD" currency: ""
version: 1.0.0 version: 1.0.0

View File

@ -16,38 +16,66 @@
nano config.yml nano config.yml
``` ```
- Update `cost` and `currency` in [pricing.yml](./pricing.yml) file as required:
```bash
nano pricing.yml
```
## Create Bond ## Create Bond
- Create bond: - Create bond:
```bash ```bash
npm run laconic bond create --type alnt --quantity 100000000 npm run laconic -- bond create --type alnt --quantity 100000000
``` ```
- Get bond info: - Get bond info:
```bash ```bash
npm run laconic bond get --id <bond-id> npm run laconic -- bond get --id <bond-id>
``` ```
## Publish Record ## Publish Record for Cost of alnt
- Publish a record - Update `for`, `cost` and `currency` fields in [pricing.yml](./pricing.yml) file:
```bash ```bash
npm run laconic record publish --filename pricing.yml --bond-id <bond-id> --gas 250000 --fees 250000alnt ...
for: "alnt"
amount: "0.000385802"
currency: "USD"
...
```
- Publish the record:
```bash
npm run laconic -- record publish --filename deploy/pricing.yml --bond-id <bond-id> --gas 250000 --fees 250000alnt
``` ```
- Get record info: - Get record info:
```bash ```bash
npm run laconic record get --id <record-id> npm run laconic -- record get --id <record-id>
```
## Publish Record for Cost of Deployment
- Update `for`, `cost` and `currency` fields in [pricing.yml](./pricing.yml) file:
```bash
...
for: "webapp-deployment"
amount: "12960"
currency: "alnt"
...
```
- Publish the record:
```bash
npm run laconic -- record publish --filename deploy/pricing.yml --bond-id <bond-id> --gas 250000 --fees 250000alnt
```
- Get record info:
```bash
npm run laconic -- record get --id <record-id>
``` ```
## Reserve a New Authority (optional) ## Reserve a New Authority (optional)
@ -55,13 +83,13 @@
- Reserve authority: - Reserve authority:
```bash ```bash
npm run laconic authority reserve laconic npm run laconic -- authority reserve laconic
``` ```
- Check authority info: - Check authority info:
```bash ```bash
npm run laconic authority whois laconic npm run laconic -- authority whois laconic
``` ```
- Note down auction ID from authority info as it is required in next steps - Note down auction ID from authority info as it is required in next steps
@ -69,13 +97,13 @@
- Get auction info: - Get auction info:
```bash ```bash
npm run laconic auction get <auction-id> npm run laconic -- auction get <auction-id>
``` ```
- Commit an auction bid: - Commit an auction bid:
```bash ```bash
npm run laconic auction bid commit <auction-id> 25000000 alnt npm run laconic -- auction bid commit <auction-id> 25000000 alnt
Reveal file: ./out/bafyreiay2rccax64yn4ljhvzvm3jkbebvzheyucuma5jlbpzpzd5i5gjuy.json Reveal file: ./out/bafyreiay2rccax64yn4ljhvzvm3jkbebvzheyucuma5jlbpzpzd5i5gjuy.json
``` ```
@ -83,21 +111,37 @@
- Reveal bid: - Reveal bid:
```bash ```bash
npm run laconic auction bid reveal <auction-id> ./out/bafyreiay2rccax64yn4ljhvzvm3jkbebvzheyucuma5jlbpzpzd5i5gjuy.json npm run laconic -- auction bid reveal <auction-id> ./out/bafyreiay2rccax64yn4ljhvzvm3jkbebvzheyucuma5jlbpzpzd5i5gjuy.json
``` ```
## Set Authority Bond ### Set Authority Bond
- Set authority bond after winning auction: - Set authority bond after winning auction:
```bash ```bash
npm run laconic authority bond set laconic <bond-id> npm run laconic -- authority bond set laconic <bond-id>
``` ```
## Set Record Name ## Set Record Name
- Set name: NOTE: To set record name an authority with an authority bond is required
- Set record name for cost of alnt record
```bash ```bash
npm run laconic name set lrn://<authority>/pricing/webapp-deployment <record-id> npm run laconic -- name set lrn://<authority>/pricing/alnt <record-id>
```
- Set record name for cost of deployment record
```bash
npm run laconic -- name set lrn://<authority>/pricing/webapp-deployment <record-id>
```
## Delete Record Name
- Delete record name:
```bash
npm run laconic -- name delete <record-name>
``` ```