Skip to content

Commit 00bd84b

Browse files
committed
refactor: remove local dependency on @iexec/dataprotector-environments from subgraph package.json
1 parent 9e2e0c8 commit 00bd84b

File tree

17 files changed

+26
-3882
lines changed

17 files changed

+26
-3882
lines changed

environments/README.md

Lines changed: 0 additions & 48 deletions
This file was deleted.

environments/common/utils.js

Lines changed: 0 additions & 25 deletions
This file was deleted.

environments/environments.json

Lines changed: 0 additions & 38 deletions
This file was deleted.

environments/esm/index.js

Lines changed: 0 additions & 14 deletions
This file was deleted.

environments/package.json

Lines changed: 0 additions & 10 deletions
This file was deleted.

environments/scripts/updateEnvironments.js

Lines changed: 0 additions & 34 deletions
This file was deleted.

environments/types/index.d.ts

Lines changed: 0 additions & 45 deletions
This file was deleted.

packages/sharing-smart-contract/.env.template

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,15 +4,18 @@ DEPLOYER_PRIVATE_KEY=...
44
# wallet used for admin operations
55
ADMIN_PRIVATE_KEY=...
66

7-
# environment to use for configuration (prod/staging). The default is prod.
8-
ENV=...
9-
107
# IExec PoCo contract address override (deploy script only)
118
POCO_ADDRESS=...
129

1310
# DatasetRegistry contract address override (deploy script only)
1411
DATASET_REGISTRY_ADDRESS=...
1512

13+
# DataProtectorSharing contract address override
14+
DATA_PROTECTOR_SHARING_ADDRESS=...
15+
16+
# AddOnlyAppWhitelistRegistry contract address
17+
ADD_ONLY_APP_WHITELIST_REGISTRY_ADDRESS=...
18+
1619
## RPC URL for the network
1720
RPC_URL=
1821

packages/sharing-smart-contract/config/env.cjs

Lines changed: 14 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,6 @@ const envSchema = z.object({
2222
.optional()
2323
.or(z.literal('')),
2424

25-
// environment to use for configuration (prod/staging)
26-
ENV: z.enum(['prod', 'staging'], 'ENV must be either "prod" or "staging"').default('prod'),
27-
2825
// Address of the PoCo contract
2926
POCO_ADDRESS: z
3027
.string()
@@ -38,6 +35,20 @@ const envSchema = z.object({
3835
.regex(addressRegex, 'Invalid Ethereum address format')
3936
.optional()
4037
.or(z.literal('')),
38+
39+
// Address of the DataProtectorSharing contract
40+
DATA_PROTECTOR_SHARING_ADDRESS: z
41+
.string()
42+
.regex(addressRegex, 'Invalid Ethereum address format')
43+
.optional()
44+
.or(z.literal('')),
45+
46+
// Address of the AddOnlyAppWhitelistRegistry contract
47+
ADD_ONLY_APP_WHITELIST_REGISTRY_ADDRESS: z
48+
.string()
49+
.regex(addressRegex, 'Invalid Ethereum address format')
50+
.optional()
51+
.or(z.literal('')),
4152

4253
// URL of the RPC used for network connection
4354
RPC_URL: z.string().url('RPC_URL must be a valid URL').optional().or(z.literal('')),

0 commit comments

Comments
 (0)