@paakd/config 0.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (140) hide show
  1. package/dist/src/index.js +20 -0
  2. package/gen/go/addresses/Address.pkl.go +10 -0
  3. package/gen/go/addresses/Addresses.pkl.go +43 -0
  4. package/gen/go/addresses/BillingAddress.pkl.go +8 -0
  5. package/gen/go/addresses/Field.pkl.go +43 -0
  6. package/gen/go/addresses/addressgroup/AddressGroup.pkl.go +43 -0
  7. package/gen/go/addresses/fieldtype/FieldType.pkl.go +61 -0
  8. package/gen/go/addresses/init.pkl.go +11 -0
  9. package/gen/go/cloudflare/Cloudflare.pkl.go +37 -0
  10. package/gen/go/cloudflare/R2Bucket.pkl.go +22 -0
  11. package/gen/go/cloudflare/TerraformBackend.pkl.go +16 -0
  12. package/gen/go/cloudflare/Turnstile.pkl.go +8 -0
  13. package/gen/go/cloudflare/init.pkl.go +11 -0
  14. package/gen/go/db/DB.pkl.go +43 -0
  15. package/gen/go/db/DBConnection.pkl.go +12 -0
  16. package/gen/go/db/init.pkl.go +9 -0
  17. package/gen/go/dune/Dune.pkl.go +47 -0
  18. package/gen/go/dune/init.pkl.go +8 -0
  19. package/gen/go/enterprise/Enterprise.pkl.go +118 -0
  20. package/gen/go/enterprise/init.pkl.go +8 -0
  21. package/gen/go/enterprise/taxonomyversion/TaxonomyVersion.pkl.go +37 -0
  22. package/gen/go/redis/Redis.pkl.go +41 -0
  23. package/gen/go/redis/init.pkl.go +8 -0
  24. package/gen/go/shared/Build.pkl.go +46 -0
  25. package/gen/go/shared/Shared.pkl.go +35 -0
  26. package/gen/go/shared/init.pkl.go +9 -0
  27. package/gen/go/worker/Worker.pkl.go +55 -0
  28. package/gen/go/worker/WorkerConnect.pkl.go +6 -0
  29. package/gen/go/worker/init.pkl.go +9 -0
  30. package/gen/js/development/basket_eco_packages_config_addresses.pkl.ts +106 -0
  31. package/gen/js/development/basket_eco_packages_config_checkout.pkl.ts +73 -0
  32. package/gen/js/development/basket_eco_packages_config_cloudflare.pkl.ts +69 -0
  33. package/gen/js/development/basket_eco_packages_config_cms.pkl.ts +119 -0
  34. package/gen/js/development/basket_eco_packages_config_db.pkl.ts +47 -0
  35. package/gen/js/development/basket_eco_packages_config_dune.pkl.ts +36 -0
  36. package/gen/js/development/basket_eco_packages_config_enterprise.pkl.ts +290 -0
  37. package/gen/js/development/basket_eco_packages_config_feature.pkl.ts +58 -0
  38. package/gen/js/development/basket_eco_packages_config_redis.pkl.ts +30 -0
  39. package/gen/js/development/basket_eco_packages_config_renderer_development_cms.pkl.ts +28 -0
  40. package/gen/js/development/basket_eco_packages_config_shared.pkl.ts +73 -0
  41. package/gen/js/development/basket_eco_packages_config_worker.pkl.ts +53 -0
  42. package/gen/js/production/basket_eco_packages_config_addresses.pkl.ts +106 -0
  43. package/gen/js/production/basket_eco_packages_config_checkout.pkl.ts +73 -0
  44. package/gen/js/production/basket_eco_packages_config_cloudflare.pkl.ts +69 -0
  45. package/gen/js/production/basket_eco_packages_config_cms.pkl.ts +119 -0
  46. package/gen/js/production/basket_eco_packages_config_db.pkl.ts +47 -0
  47. package/gen/js/production/basket_eco_packages_config_dune.pkl.ts +36 -0
  48. package/gen/js/production/basket_eco_packages_config_enterprise.pkl.ts +290 -0
  49. package/gen/js/production/basket_eco_packages_config_feature.pkl.ts +58 -0
  50. package/gen/js/production/basket_eco_packages_config_kiosk_host.pkl.ts +72 -0
  51. package/gen/js/production/basket_eco_packages_config_redis.pkl.ts +30 -0
  52. package/gen/js/production/basket_eco_packages_config_renderer_production_cms.pkl.ts +28 -0
  53. package/gen/js/production/basket_eco_packages_config_renderer_production_dune_config.pkl.ts +29 -0
  54. package/gen/js/production/basket_eco_packages_config_renderer_production_workflow_config.pkl.ts +29 -0
  55. package/gen/js/production/basket_eco_packages_config_renderer_staging_dune_config.pkl.ts +29 -0
  56. package/gen/js/production/basket_eco_packages_config_shared.pkl.ts +73 -0
  57. package/gen/js/production/basket_eco_packages_config_worker.pkl.ts +49 -0
  58. package/gen/js/staging/basket_eco_packages_config_addresses.pkl.ts +106 -0
  59. package/gen/js/staging/basket_eco_packages_config_checkout.pkl.ts +77 -0
  60. package/gen/js/staging/basket_eco_packages_config_cloudflare.pkl.ts +74 -0
  61. package/gen/js/staging/basket_eco_packages_config_cms.pkl.ts +119 -0
  62. package/gen/js/staging/basket_eco_packages_config_db.pkl.ts +47 -0
  63. package/gen/js/staging/basket_eco_packages_config_dune.pkl.ts +40 -0
  64. package/gen/js/staging/basket_eco_packages_config_enterprise.pkl.ts +290 -0
  65. package/gen/js/staging/basket_eco_packages_config_feature.pkl.ts +58 -0
  66. package/gen/js/staging/basket_eco_packages_config_redis.pkl.ts +30 -0
  67. package/gen/js/staging/basket_eco_packages_config_renderer_staging_cms.pkl.ts +28 -0
  68. package/gen/js/staging/basket_eco_packages_config_renderer_staging_dune_config.pkl.ts +29 -0
  69. package/gen/js/staging/basket_eco_packages_config_renderer_staging_workflow_config.pkl.ts +29 -0
  70. package/gen/js/staging/basket_eco_packages_config_shared.pkl.ts +69 -0
  71. package/gen/js/staging/basket_eco_packages_config_worker.pkl.ts +53 -0
  72. package/package.json +66 -0
  73. package/src/addresses.ts +90 -0
  74. package/src/authorization/policy.conf +15 -0
  75. package/src/authorization/policy.csv +26 -0
  76. package/src/chk.spec.ts +61 -0
  77. package/src/chk.ts +88 -0
  78. package/src/cms.test.ts +52 -0
  79. package/src/cms.ts +65 -0
  80. package/src/index.ts +4 -0
  81. package/src/pkl/PklProject +21 -0
  82. package/src/pkl/development/Addresses.pkl +2114 -0
  83. package/src/pkl/development/CMS.pkl +37 -0
  84. package/src/pkl/development/Checkout.pkl +32 -0
  85. package/src/pkl/development/Cloudflare.pkl +20 -0
  86. package/src/pkl/development/Db.pkl +14 -0
  87. package/src/pkl/development/Dune.pkl +12 -0
  88. package/src/pkl/development/Enterprise.pkl +158 -0
  89. package/src/pkl/development/Feature.pkl +4 -0
  90. package/src/pkl/development/Redis.pkl +6 -0
  91. package/src/pkl/development/Shared.pkl +16 -0
  92. package/src/pkl/development/Worker.pkl +43 -0
  93. package/src/pkl/development/renderer/CMS.pkl +59 -0
  94. package/src/pkl/production/Addresses.pkl +2114 -0
  95. package/src/pkl/production/CMS.pkl +34 -0
  96. package/src/pkl/production/Checkout.pkl +32 -0
  97. package/src/pkl/production/Cloudflare.pkl +20 -0
  98. package/src/pkl/production/Db.pkl +14 -0
  99. package/src/pkl/production/Dune.pkl +12 -0
  100. package/src/pkl/production/Enterprise.pkl +158 -0
  101. package/src/pkl/production/Feature.pkl +8 -0
  102. package/src/pkl/production/KioskHost.pkl +5 -0
  103. package/src/pkl/production/Redis.pkl +6 -0
  104. package/src/pkl/production/Shared.pkl +15 -0
  105. package/src/pkl/production/Worker.pkl +43 -0
  106. package/src/pkl/production/renderer/CMS.pkl +59 -0
  107. package/src/pkl/production/renderer/Dune.pkl +52 -0
  108. package/src/pkl/production/renderer/Feature.pkl +51 -0
  109. package/src/pkl/production/renderer/Workflow.pkl +51 -0
  110. package/src/pkl/staging/Addresses.pkl +2114 -0
  111. package/src/pkl/staging/CMS.pkl +35 -0
  112. package/src/pkl/staging/Checkout.pkl +32 -0
  113. package/src/pkl/staging/Cloudflare.pkl +20 -0
  114. package/src/pkl/staging/Db.pkl +14 -0
  115. package/src/pkl/staging/Dune.pkl +12 -0
  116. package/src/pkl/staging/Enterprise.pkl +158 -0
  117. package/src/pkl/staging/Feature.pkl +8 -0
  118. package/src/pkl/staging/Redis.pkl +6 -0
  119. package/src/pkl/staging/Shared.pkl +16 -0
  120. package/src/pkl/staging/Worker.pkl +43 -0
  121. package/src/pkl/staging/renderer/CMS.pkl +59 -0
  122. package/src/pkl/staging/renderer/Dune.pkl +52 -0
  123. package/src/pkl/staging/renderer/Feature.pkl +51 -0
  124. package/src/pkl/staging/renderer/Workflow.pkl +51 -0
  125. package/src/pkl/tmpl/AddressesTmpl.pkl +44 -0
  126. package/src/pkl/tmpl/CMSTmpl.pkl +64 -0
  127. package/src/pkl/tmpl/CheckoutTmpl.pkl +34 -0
  128. package/src/pkl/tmpl/CloudflareTmpl.pkl +33 -0
  129. package/src/pkl/tmpl/DbTmpl.pkl +18 -0
  130. package/src/pkl/tmpl/DuneTmpl.pkl +124 -0
  131. package/src/pkl/tmpl/EnterpriseTmpl.pkl +105 -0
  132. package/src/pkl/tmpl/FeatureTmpl.pkl +90 -0
  133. package/src/pkl/tmpl/KioskHostTmpl.pkl +194 -0
  134. package/src/pkl/tmpl/RedisTmpl.pkl +9 -0
  135. package/src/pkl/tmpl/SharedTmpl.pkl +40 -0
  136. package/src/pkl/tmpl/WorkerTmpl.pkl +27 -0
  137. package/src/pkl-reader/main.go +167 -0
  138. package/src/shared.ts +65 -0
  139. package/src/vault.spec.ts +62 -0
  140. package/src/vault.ts +68 -0
@@ -0,0 +1,8 @@
1
+ // Code generated from Pkl module `paakd.com.packages.config.Redis`. DO NOT EDIT.
2
+ package redis
3
+
4
+ import "github.com/apple/pkl-go/pkl"
5
+
6
+ func init() {
7
+ pkl.RegisterStrictMapping("paakd.com.packages.config.Redis", Redis{})
8
+ }
@@ -0,0 +1,46 @@
1
+ // Code generated from Pkl module `paakd.com.packages.config.Shared`. DO NOT EDIT.
2
+ package shared
3
+
4
+ type Build struct {
5
+ EnterpriseEnv string `pkl:"enterpriseEnv"`
6
+
7
+ EnvPath string `pkl:"envPath"`
8
+
9
+ BinUser string `pkl:"binUser"`
10
+
11
+ BinUserGroup string `pkl:"binUserGroup"`
12
+
13
+ BinUserId uint16 `pkl:"binUserId"`
14
+
15
+ CertPath string `pkl:"certPath"`
16
+
17
+ ServiceDomainName string `pkl:"serviceDomainName"`
18
+
19
+ VaultUrl string `pkl:"vaultUrl"`
20
+
21
+ GoEnv string `pkl:"goEnv"`
22
+
23
+ NodeEnv string `pkl:"nodeEnv"`
24
+
25
+ ShopId string `pkl:"shopId"`
26
+
27
+ Tenant string `pkl:"tenant"`
28
+
29
+ EnvFilePath string `pkl:"envFilePath"`
30
+
31
+ ShopBucketName string `pkl:"shopBucketName"`
32
+
33
+ ProductTaxonomyIndexBucket string `pkl:"productTaxonomyIndexBucket"`
34
+
35
+ ApiVersion string `pkl:"apiVersion"`
36
+
37
+ EnvFile string `pkl:"envFile"`
38
+
39
+ Version string `pkl:"version"`
40
+
41
+ StorefrontHost string `pkl:"storefrontHost"`
42
+
43
+ StorefrontPort uint16 `pkl:"storefrontPort"`
44
+
45
+ SecureCookiePassword string `pkl:"secureCookiePassword"`
46
+ }
@@ -0,0 +1,35 @@
1
+ // Code generated from Pkl module `paakd.com.packages.config.Shared`. DO NOT EDIT.
2
+ package shared
3
+
4
+ import (
5
+ "context"
6
+
7
+ "github.com/apple/pkl-go/pkl"
8
+ )
9
+
10
+ type Shared struct {
11
+ Build Build `pkl:"build"`
12
+ }
13
+
14
+ // LoadFromPath loads the pkl module at the given path and evaluates it into a Shared
15
+ func LoadFromPath(ctx context.Context, path string) (ret Shared, err error) {
16
+ evaluator, err := pkl.NewEvaluator(ctx, pkl.PreconfiguredOptions)
17
+ if err != nil {
18
+ return ret, err
19
+ }
20
+ defer func() {
21
+ cerr := evaluator.Close()
22
+ if err == nil {
23
+ err = cerr
24
+ }
25
+ }()
26
+ ret, err = Load(ctx, evaluator, pkl.FileSource(path))
27
+ return ret, err
28
+ }
29
+
30
+ // Load loads the pkl module at the given source and evaluates it with the given evaluator into a Shared
31
+ func Load(ctx context.Context, evaluator pkl.Evaluator, source *pkl.ModuleSource) (Shared, error) {
32
+ var ret Shared
33
+ err := evaluator.EvaluateModule(ctx, source, &ret)
34
+ return ret, err
35
+ }
@@ -0,0 +1,9 @@
1
+ // Code generated from Pkl module `paakd.com.packages.config.Shared`. DO NOT EDIT.
2
+ package shared
3
+
4
+ import "github.com/apple/pkl-go/pkl"
5
+
6
+ func init() {
7
+ pkl.RegisterStrictMapping("paakd.com.packages.config.Shared", Shared{})
8
+ pkl.RegisterStrictMapping("paakd.com.packages.config.Shared#Build", Build{})
9
+ }
@@ -0,0 +1,55 @@
1
+ // Code generated from Pkl module `paakd.com.packages.config.Worker`. DO NOT EDIT.
2
+ package worker
3
+
4
+ import (
5
+ "context"
6
+
7
+ "github.com/apple/pkl-go/pkl"
8
+ )
9
+
10
+ type Worker struct {
11
+ Breeze WorkerConnect `pkl:"breeze"`
12
+
13
+ Orchestrator WorkerConnect `pkl:"orchestrator"`
14
+
15
+ Mesh WorkerConnect `pkl:"mesh"`
16
+
17
+ TfState WorkerConnect `pkl:"tfState"`
18
+
19
+ TfStateShopBackend WorkerConnect `pkl:"tfStateShopBackend"`
20
+
21
+ TfStateServiceBackend WorkerConnect `pkl:"tfStateServiceBackend"`
22
+
23
+ TfStateHostsBackend WorkerConnect `pkl:"tfStateHostsBackend"`
24
+
25
+ OrchestratorAuth string `pkl:"orchestratorAuth"`
26
+
27
+ ShopBackendAuth string `pkl:"shopBackendAuth"`
28
+
29
+ ServiceBackendAuth string `pkl:"serviceBackendAuth"`
30
+
31
+ HostBackendAuth string `pkl:"hostBackendAuth"`
32
+ }
33
+
34
+ // LoadFromPath loads the pkl module at the given path and evaluates it into a Worker
35
+ func LoadFromPath(ctx context.Context, path string) (ret Worker, err error) {
36
+ evaluator, err := pkl.NewEvaluator(ctx, pkl.PreconfiguredOptions)
37
+ if err != nil {
38
+ return ret, err
39
+ }
40
+ defer func() {
41
+ cerr := evaluator.Close()
42
+ if err == nil {
43
+ err = cerr
44
+ }
45
+ }()
46
+ ret, err = Load(ctx, evaluator, pkl.FileSource(path))
47
+ return ret, err
48
+ }
49
+
50
+ // Load loads the pkl module at the given source and evaluates it with the given evaluator into a Worker
51
+ func Load(ctx context.Context, evaluator pkl.Evaluator, source *pkl.ModuleSource) (Worker, error) {
52
+ var ret Worker
53
+ err := evaluator.EvaluateModule(ctx, source, &ret)
54
+ return ret, err
55
+ }
@@ -0,0 +1,6 @@
1
+ // Code generated from Pkl module `paakd.com.packages.config.Worker`. DO NOT EDIT.
2
+ package worker
3
+
4
+ type WorkerConnect struct {
5
+ Endpoint string `pkl:"endpoint"`
6
+ }
@@ -0,0 +1,9 @@
1
+ // Code generated from Pkl module `paakd.com.packages.config.Worker`. DO NOT EDIT.
2
+ package worker
3
+
4
+ import "github.com/apple/pkl-go/pkl"
5
+
6
+ func init() {
7
+ pkl.RegisterStrictMapping("paakd.com.packages.config.Worker", Worker{})
8
+ pkl.RegisterStrictMapping("paakd.com.packages.config.Worker#WorkerConnect", WorkerConnect{})
9
+ }
@@ -0,0 +1,106 @@
1
+ /* This file was generated by `pkl-typescript` from Pkl module `paakd.com.packages.config.Addresses`. */
2
+ /* DO NOT EDIT! */
3
+ /* istanbul ignore file */
4
+ /* eslint-disable */
5
+ import * as pklTypescript from '@pkl-community/pkl-typescript'
6
+
7
+ // Ref: Module root.
8
+ export interface Addresses {
9
+ ca: Address
10
+
11
+ nl: Address
12
+
13
+ de: Address
14
+
15
+ gb: Address
16
+
17
+ us: Address
18
+ }
19
+
20
+ // Ref: Pkl class `paakd.com.packages.config.Addresses.Address`.
21
+ export interface Address {
22
+ minimumAgeLimit: number
23
+
24
+ shippingFields: Array<Field>
25
+
26
+ billingFields: BillingAddress
27
+ }
28
+
29
+ // Ref: Pkl class `paakd.com.packages.config.Addresses.Field`.
30
+ export interface Field {
31
+ name: string
32
+
33
+ type: FieldType
34
+
35
+ label: string
36
+
37
+ errorKey: string | null
38
+
39
+ placeholder: string | null
40
+
41
+ required: boolean
42
+
43
+ options: Map<string, string> | null
44
+
45
+ group: AddressGroup
46
+
47
+ regPattern: string | null
48
+
49
+ regPatternFlags: string | null
50
+
51
+ autoCompleteName: string | null
52
+
53
+ noAutoCorrect: boolean
54
+
55
+ caption: string | null
56
+
57
+ maxLength: number | null
58
+
59
+ isFullWidth: boolean
60
+
61
+ mask: Array<string>
62
+
63
+ minLength: number | null
64
+ }
65
+
66
+ // Ref: Pkl class `paakd.com.packages.config.Addresses.BillingAddress`.
67
+ export interface BillingAddress {
68
+ fields: Array<Field>
69
+
70
+ billableCountries: Array<string>
71
+ }
72
+
73
+ // Ref: Pkl type `paakd.com.packages.config.Addresses.FieldType`.
74
+ type FieldType =
75
+ | 'text'
76
+ | 'select'
77
+ | 'email'
78
+ | 'checkbox'
79
+ | 'radio'
80
+ | 'textarea'
81
+ | 'date'
82
+ | 'tel'
83
+ | 'hidden'
84
+ | 'lookup'
85
+ | 'display'
86
+
87
+ // Ref: Pkl type `paakd.com.packages.config.Addresses.AddressGroup`.
88
+ type AddressGroup = 'address' | 'contact' | 'company' | 'invoice' | 'other'
89
+
90
+ // LoadFromPath loads the pkl module at the given path and evaluates it into a Addresses
91
+ export const loadFromPath = async (path: string): Promise<Addresses> => {
92
+ const evaluator = await pklTypescript.newEvaluator(
93
+ pklTypescript.PreconfiguredOptions
94
+ )
95
+ try {
96
+ const result = await load(evaluator, pklTypescript.FileSource(path))
97
+ return result
98
+ } finally {
99
+ evaluator.close()
100
+ }
101
+ }
102
+
103
+ export const load = (
104
+ evaluator: pklTypescript.Evaluator,
105
+ source: pklTypescript.ModuleSource
106
+ ): Promise<Addresses> => evaluator.evaluateModule(source) as Promise<Addresses>
@@ -0,0 +1,73 @@
1
+ /* This file was generated by `pkl-typescript` from Pkl module `paakd.com.packages.config.Checkout`. */
2
+ /* DO NOT EDIT! */
3
+ /* istanbul ignore file */
4
+ /* eslint-disable */
5
+ import * as pklTypescript from "@pkl-community/pkl-typescript"
6
+
7
+ // Ref: Module root.
8
+ export interface Checkout {
9
+ hostname: string
10
+
11
+ cmsRemoteURL: string
12
+
13
+ enterpriseRemoteURL: string
14
+
15
+ cmsURL: string
16
+
17
+ enterpriseURL: string
18
+
19
+ secureCookiePassword: string
20
+
21
+ forestAPIKey: string
22
+
23
+ saleChannelAccessKey: string
24
+
25
+ salesChannelAPISecret: string
26
+
27
+ storeAccessKey: string
28
+
29
+ storeAPISecret: string
30
+
31
+ isProduction: boolean
32
+
33
+ posthogKey: string
34
+
35
+ posthogDomain: string
36
+
37
+ posthogHost: string
38
+
39
+ assetsPath: string
40
+
41
+ assetsDomain: string
42
+
43
+ turnstileKey: string
44
+
45
+ turnstileSecret: string
46
+
47
+ redis: Redis
48
+ }
49
+
50
+ // Ref: Module root.
51
+ export interface Redis {
52
+ user: string
53
+
54
+ host: string
55
+
56
+ password: string
57
+
58
+ port: number
59
+ }
60
+
61
+ // LoadFromPath loads the pkl module at the given path and evaluates it into a Checkout
62
+ export const loadFromPath = async (path: string): Promise<Checkout> => {
63
+ const evaluator = await pklTypescript.newEvaluator(pklTypescript.PreconfiguredOptions);
64
+ try {
65
+ const result = await load(evaluator, pklTypescript.FileSource(path));
66
+ return result
67
+ } finally {
68
+ evaluator.close()
69
+ }
70
+ };
71
+
72
+ export const load = (evaluator: pklTypescript.Evaluator, source: pklTypescript.ModuleSource): Promise<Checkout> =>
73
+ evaluator.evaluateModule(source) as Promise<Checkout>;
@@ -0,0 +1,69 @@
1
+ /* This file was generated by `pkl-typescript` from Pkl module `paakd.com.packages.config.Cloudflare`. */
2
+ /* DO NOT EDIT! */
3
+ /* istanbul ignore file */
4
+ /* eslint-disable */
5
+ import * as pklTypescript from "@pkl-community/pkl-typescript"
6
+
7
+ // Ref: Module root.
8
+ export interface Cloudflare {
9
+ shopR2: R2Bucket
10
+
11
+ shopTurnstile: Turnstile
12
+ }
13
+
14
+ // Ref: Pkl class `paakd.com.packages.config.Cloudflare.R2Bucket`.
15
+ export interface R2Bucket {
16
+ endpoint: string
17
+
18
+ endpointEU: string
19
+
20
+ apiKey: string
21
+
22
+ apiSecret: string
23
+
24
+ region: string
25
+
26
+ token: string
27
+
28
+ zoneId: string
29
+
30
+ shopBucketName: string
31
+
32
+ taxonomyBucketName: string
33
+ }
34
+
35
+ // Ref: Pkl class `paakd.com.packages.config.Cloudflare.Turnstile`.
36
+ export interface Turnstile {
37
+ siteKey: string
38
+
39
+ secretKey: string
40
+ }
41
+
42
+ // Ref: Pkl class `paakd.com.packages.config.Cloudflare.TerraformBackend`.
43
+ export interface TerraformBackend {
44
+ accessKey: string
45
+
46
+ secretKey: string
47
+
48
+ bucket: string
49
+
50
+ path: string
51
+
52
+ region: string
53
+
54
+ endpoint: string
55
+ }
56
+
57
+ // LoadFromPath loads the pkl module at the given path and evaluates it into a Cloudflare
58
+ export const loadFromPath = async (path: string): Promise<Cloudflare> => {
59
+ const evaluator = await pklTypescript.newEvaluator(pklTypescript.PreconfiguredOptions);
60
+ try {
61
+ const result = await load(evaluator, pklTypescript.FileSource(path));
62
+ return result
63
+ } finally {
64
+ evaluator.close()
65
+ }
66
+ };
67
+
68
+ export const load = (evaluator: pklTypescript.Evaluator, source: pklTypescript.ModuleSource): Promise<Cloudflare> =>
69
+ evaluator.evaluateModule(source) as Promise<Cloudflare>;
@@ -0,0 +1,119 @@
1
+ /* This file was generated by `pkl-typescript` from Pkl module `paakd.com.packages.config.CMS`. */
2
+ /* DO NOT EDIT! */
3
+ /* istanbul ignore file */
4
+ /* eslint-disable */
5
+ import * as pklTypescript from '@pkl-community/pkl-typescript'
6
+
7
+ // Ref: Module root.
8
+ export interface CMS {
9
+ db: DB
10
+
11
+ redis: Redis
12
+
13
+ tenantAssetURL: string
14
+
15
+ nodeEnv: string
16
+
17
+ appKeys: Array<string>
18
+
19
+ apiTokenSalt: string
20
+
21
+ adminJwtSecret: string
22
+
23
+ jwtSecret: string
24
+
25
+ jWTSECRET: string
26
+
27
+ transferTokenSalt: string
28
+
29
+ strapiAdminBackendUrl: string
30
+
31
+ adminStrapiUrl: string
32
+
33
+ sTRAPIADMINBACKENDURL: pklTypescript.Any
34
+
35
+ aDMINSTRAPIURL: pklTypescript.Any
36
+
37
+ cfAccountEndpoint: string
38
+
39
+ cfApiKey: string
40
+
41
+ cfApiSecret: string
42
+
43
+ cfTsSecretKey: string
44
+
45
+ cfBucketRegion: string
46
+
47
+ host: string
48
+
49
+ selfHost: string
50
+
51
+ port: number
52
+
53
+ selfUrl: string
54
+
55
+ cmsURL: string
56
+
57
+ tenantBucketName: string
58
+
59
+ shopId: string
60
+
61
+ restateHost: string
62
+
63
+ restatePort: number
64
+
65
+ output: pklTypescript.Any
66
+ }
67
+
68
+ // Ref: Module root.
69
+ export interface DB {
70
+ conn: DBConnection
71
+
72
+ cms: string
73
+
74
+ dune: string
75
+
76
+ enterprise: string
77
+
78
+ feature: string
79
+ }
80
+
81
+ // Ref: Pkl class `paakd.com.packages.config.DB.DBConnection`.
82
+ export interface DBConnection {
83
+ host: string
84
+
85
+ port: number
86
+
87
+ user: string
88
+
89
+ password: string
90
+ }
91
+
92
+ // Ref: Module root.
93
+ export interface Redis {
94
+ user: string
95
+
96
+ host: string
97
+
98
+ password: string
99
+
100
+ port: number
101
+ }
102
+
103
+ // LoadFromPath loads the pkl module at the given path and evaluates it into a CMS
104
+ export const loadFromPath = async (path: string): Promise<CMS> => {
105
+ const evaluator = await pklTypescript.newEvaluator(
106
+ pklTypescript.PreconfiguredOptions
107
+ )
108
+ try {
109
+ const result = await load(evaluator, pklTypescript.FileSource(path))
110
+ return result
111
+ } finally {
112
+ evaluator.close()
113
+ }
114
+ }
115
+
116
+ export const load = (
117
+ evaluator: pklTypescript.Evaluator,
118
+ source: pklTypescript.ModuleSource
119
+ ): Promise<CMS> => evaluator.evaluateModule(source) as Promise<CMS>
@@ -0,0 +1,47 @@
1
+ /* This file was generated by `pkl-typescript` from Pkl module `paakd.com.packages.config.DB`. */
2
+ /* DO NOT EDIT! */
3
+ /* istanbul ignore file */
4
+ /* eslint-disable */
5
+ import * as pklTypescript from '@pkl-community/pkl-typescript'
6
+
7
+ // Ref: Module root.
8
+ export interface DB {
9
+ conn: DBConnection
10
+
11
+ cms: string
12
+
13
+ dune: string
14
+
15
+ enterprise: string
16
+
17
+ feature: string
18
+ }
19
+
20
+ // Ref: Pkl class `paakd.com.packages.config.DB.DBConnection`.
21
+ export interface DBConnection {
22
+ host: string
23
+
24
+ port: number
25
+
26
+ user: string
27
+
28
+ password: string
29
+ }
30
+
31
+ // LoadFromPath loads the pkl module at the given path and evaluates it into a DB
32
+ export const loadFromPath = async (path: string): Promise<DB> => {
33
+ const evaluator = await pklTypescript.newEvaluator(
34
+ pklTypescript.PreconfiguredOptions
35
+ )
36
+ try {
37
+ const result = await load(evaluator, pklTypescript.FileSource(path))
38
+ return result
39
+ } finally {
40
+ evaluator.close()
41
+ }
42
+ }
43
+
44
+ export const load = (
45
+ evaluator: pklTypescript.Evaluator,
46
+ source: pklTypescript.ModuleSource
47
+ ): Promise<DB> => evaluator.evaluateModule(source) as Promise<DB>
@@ -0,0 +1,36 @@
1
+ /* This file was generated by `pkl-typescript` from Pkl module `paakd.com.packages.config.Dune`. */
2
+ /* DO NOT EDIT! */
3
+ /* istanbul ignore file */
4
+ /* eslint-disable */
5
+ import * as pklTypescript from "@pkl-community/pkl-typescript"
6
+
7
+ // Ref: Module root.
8
+ export interface Dune {
9
+ duneHost: string
10
+
11
+ dunePort: number
12
+
13
+ serverAPIKey: string
14
+
15
+ dataStore: string
16
+
17
+ cacheStore: string
18
+
19
+ configFile: pklTypescript.Any
20
+
21
+ output: pklTypescript.Any
22
+ }
23
+
24
+ // LoadFromPath loads the pkl module at the given path and evaluates it into a Dune
25
+ export const loadFromPath = async (path: string): Promise<Dune> => {
26
+ const evaluator = await pklTypescript.newEvaluator(pklTypescript.PreconfiguredOptions);
27
+ try {
28
+ const result = await load(evaluator, pklTypescript.FileSource(path));
29
+ return result
30
+ } finally {
31
+ evaluator.close()
32
+ }
33
+ };
34
+
35
+ export const load = (evaluator: pklTypescript.Evaluator, source: pklTypescript.ModuleSource): Promise<Dune> =>
36
+ evaluator.evaluateModule(source) as Promise<Dune>;