@steedos/service-package-registry 2.7.8-beta.1 → 2.7.8-beta.21
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.
package/LICENSE.txt
CHANGED
|
@@ -1,22 +1,21 @@
|
|
|
1
|
-
|
|
1
|
+
# Open Source License
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
Steedos is licensed under a modified version of the Apache License 2.0, with the following additional conditions:
|
|
4
4
|
|
|
5
|
-
|
|
6
|
-
please resort to the header of that file.
|
|
5
|
+
1. Steedos may be utilized commercially, including as a backend service for other applications or as an application development platform for enterprises. Should the conditions below be met, a commercial license must be obtained from the producer:
|
|
7
6
|
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
2. source code that is neither (1) is licensed under MIT, see https://opensource.org/licenses/MIT
|
|
7
|
+
a. Multi-tenant service: Unless explicitly authorized by Steedos in writing, you may not use the Steedos source code to operate a multi-tenant environment.
|
|
8
|
+
- Tenant Definition: Within the context of Steedos, one tenant corresponds to one space. The space provides a separated area for each tenant's data and configurations.
|
|
11
9
|
|
|
12
|
-
|
|
10
|
+
b. LOGO and copyright information: In the process of using Steedos's frontend, you may not remove or modify the LOGO or copyright information in the Steedos console or applications. This restriction is inapplicable to uses of Steedos that do not involve its frontend.
|
|
13
11
|
|
|
14
|
-
|
|
15
|
-
* are in folders named "ee" or start with "ee_", or in subfolders of such folders.
|
|
16
|
-
* contain the strings "ee_" in its filename name.
|
|
17
|
-
The files can be found by running the command `find . -iname ee -or -iname "*_ee*" -or -iname "*ee_*"`
|
|
12
|
+
2. As a contributor, you should agree that:
|
|
18
13
|
|
|
19
|
-
|
|
14
|
+
a. The producer can adjust the open-source agreement to be more strict or relaxed as deemed necessary.
|
|
15
|
+
b. Your contributed code may be used for commercial purposes, including but not limited to its cloud business operations.
|
|
20
16
|
|
|
21
|
-
|
|
22
|
-
|
|
17
|
+
Apart from the specific conditions mentioned above, all other rights and restrictions follow the Apache License 2.0. Detailed information about the Apache License 2.0 can be found at http://www.apache.org/licenses/LICENSE-2.0.
|
|
18
|
+
|
|
19
|
+
The interactive design of this product is protected by appearance patent.
|
|
20
|
+
|
|
21
|
+
© 2025 Steedos, Inc.
|
|
@@ -364,8 +364,8 @@ const enablePackage = async (packageName)=>{
|
|
|
364
364
|
return packageInfo;
|
|
365
365
|
}
|
|
366
366
|
const installPackage = async (broker, options)=>{
|
|
367
|
-
let {module, version, label, description, enable} = options;
|
|
368
|
-
const packagePath = await registry.installModule(module, version);
|
|
367
|
+
let {module, version, label, description, enable, registry: registryUrl} = options;
|
|
368
|
+
const packagePath = await registry.installModule(module, version, '', registryUrl);
|
|
369
369
|
if(enable){
|
|
370
370
|
await loadPackage(module, packagePath);
|
|
371
371
|
}else{
|
|
@@ -121,7 +121,7 @@ async function installModule(module, version, url, registry_url) {
|
|
|
121
121
|
// if( check !== false){
|
|
122
122
|
// return check;
|
|
123
123
|
// }
|
|
124
|
-
|
|
124
|
+
console.log('install package: ', module, version, url, registry_url)
|
|
125
125
|
module = module || "";
|
|
126
126
|
activePromise = activePromise.then(async function() {
|
|
127
127
|
//TODO: ensure module is 'safe'
|
|
@@ -194,10 +194,11 @@ async function installModule(module, version, url, registry_url) {
|
|
|
194
194
|
var installDir = settings.userDir || ".";
|
|
195
195
|
var args = ['install','--no-audit','--no-update-notifier','--no-fund','--save','--save-prefix=~','--production',installName];
|
|
196
196
|
var yarnArgs = ['add', '-E', installName, '--json']; //yarnCommand , '--json' --registry
|
|
197
|
-
if (
|
|
197
|
+
if (registry_url) {
|
|
198
198
|
yarnArgs.push('--registry')
|
|
199
199
|
yarnArgs.push(registry_url)
|
|
200
200
|
}
|
|
201
|
+
console.log('command run:', yarnCommand, yarnArgs.join(' '))
|
|
201
202
|
return exec.run(yarnCommand,yarnArgs,{
|
|
202
203
|
cwd: installDir
|
|
203
204
|
}, true).then(result => {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@steedos/service-package-registry",
|
|
3
|
-
"version": "2.7.8-beta.
|
|
3
|
+
"version": "2.7.8-beta.21",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "package.service.js",
|
|
6
6
|
"scripts": {
|
|
@@ -9,11 +9,11 @@
|
|
|
9
9
|
"author": "",
|
|
10
10
|
"license": "ISC",
|
|
11
11
|
"dependencies": {
|
|
12
|
-
"@steedos/auth": "2.7.8-beta.
|
|
13
|
-
"@steedos/core": "2.7.8-beta.
|
|
14
|
-
"@steedos/metadata-core": "2.7.8-beta.
|
|
15
|
-
"@steedos/objectql": "2.7.8-beta.
|
|
16
|
-
"@steedos/service-package-loader": "2.7.8-beta.
|
|
12
|
+
"@steedos/auth": "2.7.8-beta.21",
|
|
13
|
+
"@steedos/core": "2.7.8-beta.21",
|
|
14
|
+
"@steedos/metadata-core": "2.7.8-beta.21",
|
|
15
|
+
"@steedos/objectql": "2.7.8-beta.21",
|
|
16
|
+
"@steedos/service-package-loader": "2.7.8-beta.21",
|
|
17
17
|
"clone": "^2.1.2",
|
|
18
18
|
"fs-extra": "8.1.0",
|
|
19
19
|
"i18next": "20.3.2",
|
|
@@ -32,5 +32,5 @@
|
|
|
32
32
|
"publishConfig": {
|
|
33
33
|
"access": "public"
|
|
34
34
|
},
|
|
35
|
-
"gitHead": "
|
|
35
|
+
"gitHead": "bde64f8e1f880f54583600a8bb0a6018f36061b7"
|
|
36
36
|
}
|
|
@@ -268,8 +268,8 @@ module.exports = {
|
|
|
268
268
|
*/
|
|
269
269
|
methods: {
|
|
270
270
|
installPackage: {
|
|
271
|
-
async handler(module, version, label, description, enable, broker) {
|
|
272
|
-
return await loader.installPackage(broker, {module, version, label, description, enable})
|
|
271
|
+
async handler(module, version, label, description, enable, broker, registry) {
|
|
272
|
+
return await loader.installPackage(broker, {module, version, label, description, enable, registry})
|
|
273
273
|
}
|
|
274
274
|
},
|
|
275
275
|
getPackageVersions: {
|
|
@@ -395,6 +395,7 @@ module.exports = {
|
|
|
395
395
|
const settings = this.settings;
|
|
396
396
|
const packages = settings.STEEDOS_INITIAL_PACKAGES;
|
|
397
397
|
if(_.isString(packages) && packages){
|
|
398
|
+
console.log('install initial packages: ', packages);
|
|
398
399
|
for (const packageName of packages.split(',')) {
|
|
399
400
|
try {
|
|
400
401
|
const parsed = npa(packageName);
|
|
@@ -419,19 +420,30 @@ module.exports = {
|
|
|
419
420
|
case "directory":
|
|
420
421
|
case "remote":
|
|
421
422
|
case "file":
|
|
423
|
+
installProps.name = parsed.rawSpec;
|
|
424
|
+
break;
|
|
422
425
|
case "git":
|
|
423
426
|
installProps.url = parsed.rawSpec;
|
|
424
427
|
break;
|
|
425
428
|
case "alias":
|
|
426
429
|
throw new Error(`not support ${parsed.type}`);
|
|
427
430
|
}
|
|
428
|
-
if(
|
|
429
|
-
|
|
430
|
-
|
|
431
|
+
if(parsed.type === 'file' || parsed.type === 'directory'){
|
|
432
|
+
const pInfos = await this.yarnAddPackage(packageName)
|
|
433
|
+
for(const pInfo of pInfos){
|
|
434
|
+
await this.broker.call('@steedos/service-project.enablePackage', {module: pInfo.name})
|
|
435
|
+
}
|
|
436
|
+
|
|
431
437
|
}else{
|
|
432
|
-
|
|
433
|
-
|
|
438
|
+
if(installProps.url){
|
|
439
|
+
//module, version, url, auth, enable, registry_url, broker
|
|
440
|
+
await this.installPackageFromUrl(installProps.url, installProps.version, installProps.url, null, true, null, this.broker);
|
|
441
|
+
}else{
|
|
442
|
+
//module, version, label, description, enable, broker
|
|
443
|
+
await this.installPackage(installProps.name, installProps.version, null, null, true, this.broker, process.env.NPM_REGISTRY_URL);
|
|
444
|
+
}
|
|
434
445
|
}
|
|
446
|
+
|
|
435
447
|
} catch (error) {
|
|
436
448
|
this.broker.logger.error(`initialPackages: ${packageName}. ${error.message}`);
|
|
437
449
|
}
|
|
@@ -547,6 +559,7 @@ module.exports = {
|
|
|
547
559
|
})
|
|
548
560
|
})
|
|
549
561
|
}
|
|
562
|
+
return packages;
|
|
550
563
|
}
|
|
551
564
|
}
|
|
552
565
|
},
|