From 58407d4cf4404b1f69b916c50237ac83eca3e281 Mon Sep 17 00:00:00 2001 From: Prathamesh Musale Date: Mon, 24 Jun 2024 16:21:40 +0530 Subject: [PATCH] Add demo records --- .../config/demo-records/demo-record-1.yml | 7 +++++ .../config/demo-records/demo-record-10.yml | 14 ++++++++++ .../config/demo-records/demo-record-11.yml | 12 ++++++++ .../config/demo-records/demo-record-12.yml | 17 +++++++++++ .../config/demo-records/demo-record-2.yml | 7 +++++ .../config/demo-records/demo-record-3.yml | 7 +++++ .../config/demo-records/demo-record-4.yml | 7 +++++ .../config/demo-records/demo-record-5.yml | 7 +++++ .../config/demo-records/demo-record-6.yml | 7 +++++ .../config/demo-records/demo-record-7.yml | 11 ++++++++ .../config/demo-records/demo-record-8.yml | 18 ++++++++++++ .../config/demo-records/demo-record-9.yml | 17 +++++++++++ .../fixturenet-laconicd/records-demo.md | 28 +++++++++++++++---- 13 files changed, 154 insertions(+), 5 deletions(-) create mode 100644 stack-orchestrator/config/demo-records/demo-record-1.yml create mode 100644 stack-orchestrator/config/demo-records/demo-record-10.yml create mode 100644 stack-orchestrator/config/demo-records/demo-record-11.yml create mode 100644 stack-orchestrator/config/demo-records/demo-record-12.yml create mode 100644 stack-orchestrator/config/demo-records/demo-record-2.yml create mode 100644 stack-orchestrator/config/demo-records/demo-record-3.yml create mode 100644 stack-orchestrator/config/demo-records/demo-record-4.yml create mode 100644 stack-orchestrator/config/demo-records/demo-record-5.yml create mode 100644 stack-orchestrator/config/demo-records/demo-record-6.yml create mode 100644 stack-orchestrator/config/demo-records/demo-record-7.yml create mode 100644 stack-orchestrator/config/demo-records/demo-record-8.yml create mode 100644 stack-orchestrator/config/demo-records/demo-record-9.yml diff --git a/stack-orchestrator/config/demo-records/demo-record-1.yml b/stack-orchestrator/config/demo-records/demo-record-1.yml new file mode 100644 index 0000000..47b328c --- /dev/null +++ b/stack-orchestrator/config/demo-records/demo-record-1.yml @@ -0,0 +1,7 @@ +record: + type: WebsiteRegistrationRecord + url: 'https://hello-urbit.laconic.com' + repo_registration_record_cid: QmTZQ8ZJS6mALjEM2wY71msFno6zzxFftVCiZELj9xREPx + build_artifact_cid: '~lostex-rabdur-labtul-moltev/hello-urbit' + tls_cert_cid: QmR1acEmQt7Tjmhp9cFtymie2eFcrHURQKt9kGto1TQTW1 + version: 0.2.4 diff --git a/stack-orchestrator/config/demo-records/demo-record-10.yml b/stack-orchestrator/config/demo-records/demo-record-10.yml new file mode 100644 index 0000000..a467903 --- /dev/null +++ b/stack-orchestrator/config/demo-records/demo-record-10.yml @@ -0,0 +1,14 @@ +record: + type: ApplicationDeploymentRecord + version: 1.2.3 + name: name + description: description + application: application + url: url + dns: dns + request: request + meta: + foo: bar + tags: + - a + - b diff --git a/stack-orchestrator/config/demo-records/demo-record-11.yml b/stack-orchestrator/config/demo-records/demo-record-11.yml new file mode 100644 index 0000000..3afbd64 --- /dev/null +++ b/stack-orchestrator/config/demo-records/demo-record-11.yml @@ -0,0 +1,12 @@ +record: + type: GeneralRecord + version: 1.2.3 + name: name + description: description + category: category + value: value + meta: + foo: bar + tags: + - a + - b diff --git a/stack-orchestrator/config/demo-records/demo-record-12.yml b/stack-orchestrator/config/demo-records/demo-record-12.yml new file mode 100644 index 0000000..4c5f024 --- /dev/null +++ b/stack-orchestrator/config/demo-records/demo-record-12.yml @@ -0,0 +1,17 @@ +record: + type: ApplicationArtifact + version: 1.2.3 + name: name + description: description + application: appidgoeshere + content_type: content_type + os: os + cpu: cpu + uri: + - uri://a + - uri://b + meta: + foo: bar + tags: + - a + - b diff --git a/stack-orchestrator/config/demo-records/demo-record-2.yml b/stack-orchestrator/config/demo-records/demo-record-2.yml new file mode 100644 index 0000000..eae0cf8 --- /dev/null +++ b/stack-orchestrator/config/demo-records/demo-record-2.yml @@ -0,0 +1,7 @@ +record: + type: WebsiteRegistrationRecord + url: 'https://dev-hello-urbit.laconic.com' + repo_registration_record_cid: QmPbKkK7gKojnGAgKAE6bK5qBY8BcYp2YDB1e4b28NxvVv + build_artifact_cid: '~lostex-rabdur-labtul-moltev/hello-urbit-dev' + tls_cert_cid: QmWbCv4k9Q9P6XptHNJN6EupDyKVLSLRV6W6T2sAYkfBxr + version: 0.2.5 diff --git a/stack-orchestrator/config/demo-records/demo-record-3.yml b/stack-orchestrator/config/demo-records/demo-record-3.yml new file mode 100644 index 0000000..3197b24 --- /dev/null +++ b/stack-orchestrator/config/demo-records/demo-record-3.yml @@ -0,0 +1,7 @@ +record: + type: WebsiteRegistrationRecord + url: 'https://app.osmosis.zone' + repo_registration_record_cid: QmSnuWmxptJZdLJpKRarxBMS2Ju2oANVrgbr2xWbie9b2D + build_artifact_cid: '~larryx-woldyr/osmosis:latest' + tls_cert_cid: QmbWqxBEKC3P8tqsKc98xmWNzrzDtRLMiMPL8wBuTGsMnR + version: 1.3.5 diff --git a/stack-orchestrator/config/demo-records/demo-record-4.yml b/stack-orchestrator/config/demo-records/demo-record-4.yml new file mode 100644 index 0000000..f892ac8 --- /dev/null +++ b/stack-orchestrator/config/demo-records/demo-record-4.yml @@ -0,0 +1,7 @@ +record: + type: WebsiteRegistrationRecord + url: 'https://dev.osmosis.zone' + repo_registration_record_cid: QmPbKkK7gKojnGAgKAE6bK5qBY8BcYp2YDB1e4b28NxvVv + build_artifact_cid: '~larryx-woldyr/osmosis:dev' + tls_cert_cid: QmWbCv4k9Q9P6XptHNJN6EupDyKVLSLRV6W6T2sAYkfBxr + version: 1.3.6 diff --git a/stack-orchestrator/config/demo-records/demo-record-5.yml b/stack-orchestrator/config/demo-records/demo-record-5.yml new file mode 100644 index 0000000..d4e21bb --- /dev/null +++ b/stack-orchestrator/config/demo-records/demo-record-5.yml @@ -0,0 +1,7 @@ +record: + type: WebsiteRegistrationRecord + url: 'https://pwa-1-1-3.iglootools.xyz' + repo_registration_record_cid: QmSnuWmxptJZdLJpKRarxBMS2Ju2oANVrgbr2xWbie9b2D + build_artifact_cid: https://ipfs.io/ipfs/QmP8jTG1m9GSDJLCbeWhVSVgEzCPPwXRdCRuJtQ5Tz9Kc9 + tls_cert_cid: QmbWqxBEKC3P8tqsKc98xmWNzrzDtRLMiMPL8wBuTGsMnR + version: 1.1.3 diff --git a/stack-orchestrator/config/demo-records/demo-record-6.yml b/stack-orchestrator/config/demo-records/demo-record-6.yml new file mode 100644 index 0000000..9e1ffae --- /dev/null +++ b/stack-orchestrator/config/demo-records/demo-record-6.yml @@ -0,0 +1,7 @@ +record: + type: WebsiteRegistrationRecord + url: 'https://pwa-1-2-3.iglootools.xyz' + repo_registration_record_cid: QmVjYQ59z3fuKfYUV1aXhDR82JAKxdqB5JMPfUsHkJUkJq + build_artifact_cid: https://ipfs.io/ipfs/QmN2yevgjC92gzGi2BY6Q2yBWmR6JNWQ9yscoPPyy1V2Hv + tls_cert_cid: QmTAnmDMSnzqAN3yyXtFD4KpyATkeze62ZkbmXHjJ8xQW8 + version: 1.2.3 diff --git a/stack-orchestrator/config/demo-records/demo-record-7.yml b/stack-orchestrator/config/demo-records/demo-record-7.yml new file mode 100644 index 0000000..1bf4ad4 --- /dev/null +++ b/stack-orchestrator/config/demo-records/demo-record-7.yml @@ -0,0 +1,11 @@ +record: + type: DnsRecord + version: 0.0.1 + name: "foo" + resource_type: "A" + value: "bar" + meta: + foo: bar + tags: + - a + - b diff --git a/stack-orchestrator/config/demo-records/demo-record-8.yml b/stack-orchestrator/config/demo-records/demo-record-8.yml new file mode 100644 index 0000000..95bd195 --- /dev/null +++ b/stack-orchestrator/config/demo-records/demo-record-8.yml @@ -0,0 +1,18 @@ +record: + type: ApplicationRecord + version: 0.0.1 + name: my-demo-app + description: "Description of my app" + homepage: http://my.demo.app + license: license + author: author + repository: + - "https://my.demo.repo" + repository_ref: "v0.1.0" + app_version: "0.1.0" + app_type: "webapp" + meta: + foo: bar + tags: + - a + - b diff --git a/stack-orchestrator/config/demo-records/demo-record-9.yml b/stack-orchestrator/config/demo-records/demo-record-9.yml new file mode 100644 index 0000000..415e5c7 --- /dev/null +++ b/stack-orchestrator/config/demo-records/demo-record-9.yml @@ -0,0 +1,17 @@ +record: + type: ApplicationDeploymentRequest + version: 1.2.3 + application: application + dns: dns + config: + env: + ENV_VAR_A: A + ENV_VAR_B: B + crn: + - crn://foo.bar + - crn://bar.baz + meta: + foo: bar + tags: + - a + - b diff --git a/stack-orchestrator/stacks/fixturenet-laconicd/records-demo.md b/stack-orchestrator/stacks/fixturenet-laconicd/records-demo.md index a224653..541ac55 100644 --- a/stack-orchestrator/stacks/fixturenet-laconicd/records-demo.md +++ b/stack-orchestrator/stacks/fixturenet-laconicd/records-demo.md @@ -19,18 +19,25 @@ ## Run -* Copy over all records from a dir to the data dir in `laconic-console-deployment` (`laconic-console-deployment/data/laconic-registry-data`): +* Copy over all records from a dir to the data dir in `laconic-console-deployment` (`laconic-console-deployment/data/laconic-registry-data`) and publish the records: ```bash - # Example - cp -r /home/user/laconic-testnet-data/records/repo laconic-console-deployment/data/laconic-registry-data/repo-records + # Example: for demo records + # Copy over the records + cp -r /home/user/fixturenet-laconicd-stack/stack-orchestrator/config/demo-records laconic-console-deployment/data/laconic-registry-data/ - rsync -av --exclude 'repo' /home/user/laconic-testnet-data/records laconic-console-deployment/data/laconic-registry-data/ + # Publish the records from `laconic-registry-data` directory + laconic-so deployment --dir laconic-console-deployment exec cli "yarn ts-node demo/scripts/publish-records.ts --config config.yml --records /laconic-registry-data/records" ``` -* Publish records from the `laconic-registry-data` directory: + OR ```bash + # Example: for testnet records + # Copy over the records + cp -r /home/user/laconic-testnet-data/records/repo laconic-console-deployment/data/laconic-registry-data/repo-records + rsync -av --exclude 'repo' /home/user/laconic-testnet-data/records laconic-console-deployment/data/laconic-registry-data/ + # Publish repository records first laconic-so deployment --dir laconic-console-deployment exec cli "yarn ts-node demo/scripts/publish-records.ts --config config.yml --records /laconic-registry-data/repo-records" @@ -41,6 +48,17 @@ ## Query * All the published records can be viewed on the console at + * explore the console for more information + * click on the link aside a record that opens the GraphQL console + * the query is pre-loaded, run it and inspect the output + +### CLI Examples + +* Query all records: + + ```bash + laconic-so deployment --dir laconic-console-deployment exec cli "laconic registry record list" + ``` * Query for `geth` service deployment(s):