@abtnode/constant 1.6.30 → 1.7.1

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 (2) hide show
  1. package/index.js +23 -6
  2. package/package.json +2 -2
package/index.js CHANGED
@@ -56,6 +56,12 @@ const RBAC_CONFIG = {
56
56
  passport: true,
57
57
  ci: true,
58
58
  },
59
+ {
60
+ name: 'blocklet',
61
+ title: 'Blocklet',
62
+ // passport: true, // TODO enable this when we support access key for manage single blocklet
63
+ ci: true, // do not issue this passport to human
64
+ },
59
65
  {
60
66
  name: NODE_SERVICES.AUTH_SERVICE,
61
67
  title: 'Auth Service',
@@ -95,6 +101,10 @@ const RBAC_CONFIG = {
95
101
  name: 'mutate_team',
96
102
  description: 'Manage team data(members/roles/permissions) for Blocklet Server and blocklets',
97
103
  },
104
+ {
105
+ name: 'manage_blocklet',
106
+ description: 'Manage a single blocklet',
107
+ },
98
108
  {
99
109
  name: 'query_blocklet',
100
110
  description: 'View store and installed blocklets, including blocklet runtime configuration, domains and urls',
@@ -160,6 +170,7 @@ const RBAC_CONFIG = {
160
170
  '@abtnode/auth-service': ['query_team', 'mutate_team'],
161
171
  ci: ['query_blocklet', 'mutate_blocklet'],
162
172
  certificate: ['query_certificate', 'mutate_certificate'],
173
+ blocklet: ['query_team', 'mutate_team', 'manage_blocklet'],
163
174
  }),
164
175
  };
165
176
 
@@ -179,6 +190,12 @@ const EVENTS = {
179
190
  USER_UPDATED: 'user.updated',
180
191
  };
181
192
 
193
+ const WHO_CAN_ACCESS = {
194
+ OWNER: 'owner',
195
+ INVITED: 'invited',
196
+ ALL: 'all',
197
+ };
198
+
182
199
  module.exports = Object.freeze({
183
200
  // Blocklet Server
184
201
  NODE_MODES: Object.freeze({
@@ -225,9 +242,8 @@ module.exports = Object.freeze({
225
242
 
226
243
  DEFAULT_DID_REGISTRY: 'https://registry.abtnet.io',
227
244
  DEFAULT_DID_DOMAIN: 'did.abtnet.io',
228
- DEFAULT_GATEWAY_DOMAIN: 'did.gw.abtnet.io',
229
- DEFAULT_IP_DNS_DOMAIN_SUFFIX: 'ip.abtnet.io',
230
245
  DEFAULT_IP_DOMAIN: '*.ip.abtnet.io',
246
+ DEFAULT_IP_DOMAIN_SUFFIX: 'ip.abtnet.io',
231
247
  DEFAULT_WILDCARD_CERT_HOST: 'https://releases.arcblock.io/',
232
248
 
233
249
  DEFAULT_CERTIFICATE_EMAIL: 'certs@arcblock.io',
@@ -275,11 +291,10 @@ module.exports = Object.freeze({
275
291
 
276
292
  // Time and dates
277
293
  DAY_IN_MS,
278
- DAEMON_MAX_MEM_LIMIT_IN_MB: 600,
279
- PROXY_MAX_MEM_LIMIT_IN_MB: 300,
294
+ DAEMON_MAX_MEM_LIMIT_IN_MB: 800,
295
+ PROXY_MAX_MEM_LIMIT_IN_MB: 800,
280
296
  BLOCKLET_MAX_MEM_LIMIT_IN_MB: 300,
281
- CERTIFICATE_EXPIRES_OFFSET: 8 * DAY_IN_MS,
282
- CERTIFICATE_EXPIRES_WARNING_OFFSET: 7 * DAY_IN_MS,
297
+ CERTIFICATE_EXPIRES_OFFSET: 10 * DAY_IN_MS,
283
298
  ROUTING_RULE_TYPES: Object.freeze({
284
299
  NONE: 'none',
285
300
  DAEMON: 'daemon',
@@ -307,4 +322,6 @@ module.exports = Object.freeze({
307
322
 
308
323
  // EVENTS
309
324
  EVENTS,
325
+
326
+ WHO_CAN_ACCESS,
310
327
  });
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "publishConfig": {
4
4
  "access": "public"
5
5
  },
6
- "version": "1.6.30",
6
+ "version": "1.7.1",
7
7
  "description": "ABT Node constants",
8
8
  "main": "index.js",
9
9
  "files": [
@@ -20,5 +20,5 @@
20
20
  "devDependencies": {
21
21
  "jest": "^27.4.5"
22
22
  },
23
- "gitHead": "d8ea64b807f7852186cd4bf544193496fbb31e7c"
23
+ "gitHead": "5d7efb21dd09f90206251fb74601ca37b0ef84bf"
24
24
  }