@ni-kismet/sl-webapp-nipkg 0.2.2 → 0.3.0
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/README.md +212 -5
- package/dist/cli.js +218 -0
- package/dist/cli.js.map +1 -1
- package/dist/cli.test.js +305 -1
- package/dist/cli.test.js.map +1 -1
- package/dist/credentialStore.d.ts +18 -0
- package/dist/credentialStore.d.ts.map +1 -0
- package/dist/credentialStore.js +68 -0
- package/dist/credentialStore.js.map +1 -0
- package/dist/credentialStore.test.d.ts +2 -0
- package/dist/credentialStore.test.d.ts.map +1 -0
- package/dist/credentialStore.test.js +86 -0
- package/dist/credentialStore.test.js.map +1 -0
- package/dist/deployer.d.ts +47 -0
- package/dist/deployer.d.ts.map +1 -0
- package/dist/deployer.js +305 -0
- package/dist/deployer.js.map +1 -0
- package/dist/deployer.test.d.ts +2 -0
- package/dist/deployer.test.d.ts.map +1 -0
- package/dist/deployer.test.js +144 -0
- package/dist/deployer.test.js.map +1 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2 -0
- package/dist/index.js.map +1 -1
- package/dist/slApiClient.d.ts +56 -0
- package/dist/slApiClient.d.ts.map +1 -0
- package/dist/slApiClient.js +118 -0
- package/dist/slApiClient.js.map +1 -0
- package/dist/types.d.ts +130 -0
- package/dist/types.d.ts.map +1 -1
- package/package.json +10 -7
|
@@ -0,0 +1,118 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Thin HTTP client for the SystemLink WebApps API.
|
|
3
|
+
* Centralises auth, timeout/abort, and error-response handling.
|
|
4
|
+
*/
|
|
5
|
+
export class SlApiClient {
|
|
6
|
+
host;
|
|
7
|
+
apiKey;
|
|
8
|
+
timeout;
|
|
9
|
+
constructor(host, apiKey, timeout) {
|
|
10
|
+
this.host = host;
|
|
11
|
+
this.apiKey = apiKey;
|
|
12
|
+
this.timeout = timeout;
|
|
13
|
+
let parsed;
|
|
14
|
+
try {
|
|
15
|
+
parsed = new URL(host);
|
|
16
|
+
}
|
|
17
|
+
catch {
|
|
18
|
+
throw new Error(`Host must be a valid https:// URL. Got: ${host}`);
|
|
19
|
+
}
|
|
20
|
+
if (parsed.protocol !== 'https:') {
|
|
21
|
+
throw new Error(`Host must be a valid https:// URL. Got: ${host}`);
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
async createWebApp(body) {
|
|
25
|
+
const response = await this.fetchWithTimeout(`${this.host}/niapp/v1/webapps`, {
|
|
26
|
+
method: 'POST',
|
|
27
|
+
headers: this.jsonHeaders(),
|
|
28
|
+
body: JSON.stringify(body)
|
|
29
|
+
});
|
|
30
|
+
if (!response.ok) {
|
|
31
|
+
throw new Error(`Create WebApp failed (${response.status}): ${await response.text()}`);
|
|
32
|
+
}
|
|
33
|
+
const result = (await response.json());
|
|
34
|
+
if (!result.id) {
|
|
35
|
+
throw new Error('No WebApp ID returned from create request');
|
|
36
|
+
}
|
|
37
|
+
return result;
|
|
38
|
+
}
|
|
39
|
+
async getWebApp(appId) {
|
|
40
|
+
const response = await this.fetchWithTimeout(`${this.host}/niapp/v1/webapps/${appId}`, {
|
|
41
|
+
method: 'GET',
|
|
42
|
+
headers: this.authHeaders()
|
|
43
|
+
});
|
|
44
|
+
if (!response.ok) {
|
|
45
|
+
throw new Error(`Get WebApp failed (${response.status}): ${await response.text()}`);
|
|
46
|
+
}
|
|
47
|
+
return (await response.json());
|
|
48
|
+
}
|
|
49
|
+
async updateWebApp(appId, body) {
|
|
50
|
+
const response = await this.fetchWithTimeout(`${this.host}/niapp/v1/webapps/${appId}`, {
|
|
51
|
+
method: 'PUT',
|
|
52
|
+
headers: this.jsonHeaders(),
|
|
53
|
+
body: JSON.stringify(body)
|
|
54
|
+
});
|
|
55
|
+
if (!response.ok) {
|
|
56
|
+
throw new Error(`Update WebApp metadata failed (${response.status}): ${await response.text()}`);
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
async uploadContent(appId, stream, size) {
|
|
60
|
+
const headers = this.authHeaders();
|
|
61
|
+
headers.set('Content-Type', 'application/octet-stream');
|
|
62
|
+
headers.set('Content-Length', String(size));
|
|
63
|
+
const response = await this.fetchWithTimeout(`${this.host}/niapp/v1/webapps/${appId}/content`, {
|
|
64
|
+
method: 'PUT',
|
|
65
|
+
headers,
|
|
66
|
+
body: stream,
|
|
67
|
+
duplex: 'half'
|
|
68
|
+
});
|
|
69
|
+
if (!response.ok) {
|
|
70
|
+
throw new Error(`Upload content failed (${response.status}): ${await response.text()}`);
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
/**
|
|
74
|
+
* Verify that the host and API key are valid by making a cheap read-only request.
|
|
75
|
+
* Returns `{ ok: true }` on success, `{ ok: false, status: 401 }` on auth failure.
|
|
76
|
+
* Does NOT throw on HTTP error responses — only throws on network/transport errors.
|
|
77
|
+
*/
|
|
78
|
+
async verifyAuth() {
|
|
79
|
+
const response = await this.fetchWithTimeout(`${this.host}/niapp/v1/webapps?take=0&includeTotalCount=false`, { method: 'GET', headers: this.authHeaders() });
|
|
80
|
+
return { ok: response.ok, status: response.status };
|
|
81
|
+
}
|
|
82
|
+
async deleteWebApp(appId) {
|
|
83
|
+
const response = await this.fetchWithTimeout(`${this.host}/niapp/v1/webapps/${appId}`, {
|
|
84
|
+
method: 'DELETE',
|
|
85
|
+
headers: this.authHeaders()
|
|
86
|
+
});
|
|
87
|
+
if (!response.ok) {
|
|
88
|
+
throw new Error(`Delete WebApp failed (${response.status}): ${await response.text()}`);
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
authHeaders() {
|
|
92
|
+
const headers = new Headers();
|
|
93
|
+
headers.set('x-ni-api-key', this.apiKey);
|
|
94
|
+
return headers;
|
|
95
|
+
}
|
|
96
|
+
jsonHeaders() {
|
|
97
|
+
const headers = this.authHeaders();
|
|
98
|
+
headers.set('Content-Type', 'application/json');
|
|
99
|
+
return headers;
|
|
100
|
+
}
|
|
101
|
+
async fetchWithTimeout(url, init) {
|
|
102
|
+
const controller = new AbortController();
|
|
103
|
+
const timeoutId = setTimeout(() => controller.abort(), this.timeout);
|
|
104
|
+
try {
|
|
105
|
+
return await fetch(url, { ...init, signal: controller.signal });
|
|
106
|
+
}
|
|
107
|
+
catch (error) {
|
|
108
|
+
if (error.name === 'AbortError') {
|
|
109
|
+
throw new Error(`Request timed out after ${this.timeout}ms`);
|
|
110
|
+
}
|
|
111
|
+
throw error;
|
|
112
|
+
}
|
|
113
|
+
finally {
|
|
114
|
+
clearTimeout(timeoutId);
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
//# sourceMappingURL=slApiClient.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"slApiClient.js","sourceRoot":"","sources":["../src/slApiClient.ts"],"names":[],"mappings":"AAyBA;;;GAGG;AACH,MAAM,OAAO,WAAW;IAEC;IACA;IACA;IAHrB,YACqB,IAAY,EACZ,MAAc,EACd,OAAe;QAFf,SAAI,GAAJ,IAAI,CAAQ;QACZ,WAAM,GAAN,MAAM,CAAQ;QACd,YAAO,GAAP,OAAO,CAAQ;QAEhC,IAAI,MAAW,CAAC;QAChB,IAAI,CAAC;YACD,MAAM,GAAG,IAAI,GAAG,CAAC,IAAI,CAAC,CAAC;QAC3B,CAAC;QAAC,MAAM,CAAC;YACL,MAAM,IAAI,KAAK,CAAC,2CAA2C,IAAI,EAAE,CAAC,CAAC;QACvE,CAAC;QACD,IAAI,MAAM,CAAC,QAAQ,KAAK,QAAQ,EAAE,CAAC;YAC/B,MAAM,IAAI,KAAK,CAAC,2CAA2C,IAAI,EAAE,CAAC,CAAC;QACvE,CAAC;IACL,CAAC;IAEM,KAAK,CAAC,YAAY,CAAC,IAAyB;QAC/C,MAAM,QAAQ,GAAG,MAAM,IAAI,CAAC,gBAAgB,CAAC,GAAG,IAAI,CAAC,IAAI,mBAAmB,EAAE;YAC1E,MAAM,EAAE,MAAM;YACd,OAAO,EAAE,I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CAAC;YACD,MAAM,KAAK,CAAC;QAChB,CAAC;gBAAS,CAAC;YACP,YAAY,CAAC,SAAS,CAAC,CAAC;QAC5B,CAAC;IACL,CAAC;CACJ"}
|
package/dist/types.d.ts
CHANGED
|
@@ -62,6 +62,48 @@ export interface NipkgConfig {
|
|
|
62
62
|
* @remarks Useful for CI/CD to append build IDs (e.g., '12345' becomes 'package_1.0.0_12345_all.nipkg').
|
|
63
63
|
*/
|
|
64
64
|
buildSuffix?: string;
|
|
65
|
+
/**
|
|
66
|
+
* Deployment configuration for SystemLink WebApp.
|
|
67
|
+
* @remarks Optional deployment settings for published packages.
|
|
68
|
+
*/
|
|
69
|
+
deployment?: DeploymentConfig;
|
|
70
|
+
}
|
|
71
|
+
export interface DeploymentConfig {
|
|
72
|
+
/**
|
|
73
|
+
* SystemLink host URL (e.g., 'https://systemlink.example.com').
|
|
74
|
+
* @remarks Can be overridden via --host CLI flag or SYSTEMLINK_HOST environment variable.
|
|
75
|
+
*/
|
|
76
|
+
host?: string;
|
|
77
|
+
/**
|
|
78
|
+
* WebApp name for creation.
|
|
79
|
+
* @remarks Can be overridden via --name CLI flag.
|
|
80
|
+
*/
|
|
81
|
+
name?: string;
|
|
82
|
+
/**
|
|
83
|
+
* Workspace UUID for new WebApp creation.
|
|
84
|
+
* @remarks Can be overridden via --workspace-id CLI flag.
|
|
85
|
+
*/
|
|
86
|
+
workspaceId?: string;
|
|
87
|
+
/**
|
|
88
|
+
* Policy IDs array for WebApp creation.
|
|
89
|
+
* @remarks Can be overridden via --policy-ids CLI flag (comma-separated string).
|
|
90
|
+
*/
|
|
91
|
+
policyIds?: string[];
|
|
92
|
+
/**
|
|
93
|
+
* Custom properties for WebApp.
|
|
94
|
+
* @remarks Optional key/value metadata for the WebApp. A `version` field is auto-injected from
|
|
95
|
+
* `--version` or `package.json` if not already present. Description can also be included here.
|
|
96
|
+
* @example { "version": "1.0.0", "description": "My App" }
|
|
97
|
+
*/
|
|
98
|
+
properties?: {
|
|
99
|
+
[key: string]: string;
|
|
100
|
+
};
|
|
101
|
+
/**
|
|
102
|
+
* Request timeout in milliseconds.
|
|
103
|
+
* @remarks Timeout for API requests to SystemLink.
|
|
104
|
+
* @defaultValue 30000
|
|
105
|
+
*/
|
|
106
|
+
timeout?: number;
|
|
65
107
|
}
|
|
66
108
|
export interface BuildOptions {
|
|
67
109
|
/**
|
|
@@ -116,4 +158,92 @@ export interface BuildOptions {
|
|
|
116
158
|
*/
|
|
117
159
|
outputDir?: string;
|
|
118
160
|
}
|
|
161
|
+
export interface DeployOptions {
|
|
162
|
+
/**
|
|
163
|
+
* SystemLink host URL.
|
|
164
|
+
* @remarks CLI override for config deployment.host.
|
|
165
|
+
*/
|
|
166
|
+
host?: string;
|
|
167
|
+
/**
|
|
168
|
+
* SystemLink API key.
|
|
169
|
+
* @remarks Use the SYSTEMLINK_API_KEY environment variable when possible. This option is provided
|
|
170
|
+
* for cases where passing via the --api-key CLI flag is necessary.
|
|
171
|
+
*/
|
|
172
|
+
apiKey?: string;
|
|
173
|
+
/**
|
|
174
|
+
* Path to a `.nipkg` file or a directory to search for `.nipkg` files.
|
|
175
|
+
* @remarks When pointing to a file, it is used directly. When pointing to a directory,
|
|
176
|
+
* the newest `.nipkg` file is auto-selected if only one exists or if `latest` is `true`;
|
|
177
|
+
* otherwise an interactive prompt is shown to choose among the available files.
|
|
178
|
+
* Falls back to `config.outputDir` (then `dist/nipkg`) when omitted.
|
|
179
|
+
*/
|
|
180
|
+
nipkg?: string;
|
|
181
|
+
/**
|
|
182
|
+
* Auto-select latest nipkg without prompting.
|
|
183
|
+
* @remarks When false and multiple files are found, an interactive prompt is shown. Set to true in CI/CD environments.
|
|
184
|
+
*/
|
|
185
|
+
latest?: boolean;
|
|
186
|
+
/**
|
|
187
|
+
* Run build before deploying.
|
|
188
|
+
* @remarks Can be a boolean (true = use config command) or string (custom command).
|
|
189
|
+
*/
|
|
190
|
+
build?: boolean | string;
|
|
191
|
+
/**
|
|
192
|
+
* WebApp name for creation.
|
|
193
|
+
* @remarks CLI override for config deployment.name. Falls back to displayName if not provided.
|
|
194
|
+
*/
|
|
195
|
+
name?: string;
|
|
196
|
+
/**
|
|
197
|
+
* Package version.
|
|
198
|
+
* @remarks Auto-injected into properties.version if not already set. Falls back to package.json.
|
|
199
|
+
*/
|
|
200
|
+
version?: string;
|
|
201
|
+
/**
|
|
202
|
+
* Workspace UUID for WebApp creation.
|
|
203
|
+
* @remarks CLI override for config deployment.workspaceId.
|
|
204
|
+
*/
|
|
205
|
+
workspaceId?: string;
|
|
206
|
+
/**
|
|
207
|
+
* Policy IDs for WebApp creation (comma-separated string or array).
|
|
208
|
+
* @remarks CLI override for config deployment.policyIds.
|
|
209
|
+
*/
|
|
210
|
+
policyIds?: string | string[];
|
|
211
|
+
/**
|
|
212
|
+
* Custom properties for WebApp.
|
|
213
|
+
* @remarks CLI override for config deployment.properties.
|
|
214
|
+
*/
|
|
215
|
+
properties?: {
|
|
216
|
+
[key: string]: unknown;
|
|
217
|
+
};
|
|
218
|
+
/**
|
|
219
|
+
* Update existing WebApp instead of creating new one.
|
|
220
|
+
* @remarks If true, requires appId.
|
|
221
|
+
*/
|
|
222
|
+
update?: boolean;
|
|
223
|
+
/**
|
|
224
|
+
* WebApp ID for update operation.
|
|
225
|
+
* @remarks Required if update is true.
|
|
226
|
+
*/
|
|
227
|
+
appId?: string;
|
|
228
|
+
/**
|
|
229
|
+
* Verbose output.
|
|
230
|
+
* @remarks Enable detailed logging.
|
|
231
|
+
*/
|
|
232
|
+
verbose?: boolean;
|
|
233
|
+
/**
|
|
234
|
+
* Request timeout in milliseconds.
|
|
235
|
+
* @remarks Timeout for API requests.
|
|
236
|
+
*/
|
|
237
|
+
timeout?: number;
|
|
238
|
+
/**
|
|
239
|
+
* Suffix appended to nipkg filename when --build is used.
|
|
240
|
+
* @remarks Forwarded to builder (e.g., CI build ID).
|
|
241
|
+
*/
|
|
242
|
+
buildSuffix?: string;
|
|
243
|
+
/**
|
|
244
|
+
* Skip cleanup of existing nipkg files when --build is used.
|
|
245
|
+
* @remarks Forwarded to builder.
|
|
246
|
+
*/
|
|
247
|
+
skipCleanup?: boolean;
|
|
248
|
+
}
|
|
119
249
|
//# sourceMappingURL=types.d.ts.map
|
package/dist/types.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,WAAW;IACxB;;;OAGG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC;IAEd;;;;OAIG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB;;;OAGG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB;;;;OAIG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IAEpB;;;OAGG;IACH,YAAY,CAAC,EAAE,MAAM,CAAC;IAEtB;;;OAGG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB;;;OAGG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;IAElB;;;;OAIG;IACH,YAAY,CAAC,EAAE,MAAM,CAAC;IAEtB;;;OAGG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB;;;OAGG;IACH,OAAO,CAAC,EAAE,MAAM,EAAE,CAAC;IAEnB;;;OAGG;IACH,WAAW,CAAC,EAAE,OAAO,CAAC;IAEtB;;;OAGG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,WAAW;IACxB;;;OAGG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC;IAEd;;;;OAIG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB;;;OAGG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB;;;;OAIG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IAEpB;;;OAGG;IACH,YAAY,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H,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB;;;OAGG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IAEpB;;;OAGG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;CACtB;AAED,MAAM,WAAW,aAAa;IAC1B;;;OAGG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC;IAEd;;;;OAIG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAEhB;;;;;;OAMG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IAEf;;;OAGG;IACH,MAAM,CAAC,EAAE,OAAO,CAAC;IAEjB;;;OAGG;IACH,KAAK,CAAC,EAAE,OAAO,GAAG,MAAM,CAAC;IAEzB;;;OAGG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC;IAEd;;;OAGG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB;;;OAGG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB;;;OAGG;IACH,SAAS,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC;IAE9B;;;OAGG;IACH,UAAU,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAA;KAAE,CAAC;IAExC;;;OAGG;IACH,MAAM,CAAC,EAAE,OAAO,CAAC;IAEjB;;;OAGG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IAEf;;;OAGG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;IAElB;;;OAGG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB;;;OAGG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB;;;OAGG;IACH,WAAW,CAAC,EAAE,OAAO,CAAC;CACzB"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ni-kismet/sl-webapp-nipkg",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.3.0",
|
|
4
4
|
"description": "Build tool for packaging web applications into SystemLink WebApp .nipkg format. Supports Node.js, Python, .NET Blazor, and static sites.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"exports": {
|
|
@@ -57,6 +57,9 @@
|
|
|
57
57
|
"name": "National Instruments"
|
|
58
58
|
},
|
|
59
59
|
"license": "MIT",
|
|
60
|
+
"engines": {
|
|
61
|
+
"node": ">=20.0.0"
|
|
62
|
+
},
|
|
60
63
|
"bugs": {
|
|
61
64
|
"url": "https://github.com/ni/sl-webapp-nipkg/issues"
|
|
62
65
|
},
|
|
@@ -65,20 +68,20 @@
|
|
|
65
68
|
"chalk": "^5.6.2",
|
|
66
69
|
"commander": "^14.0.3",
|
|
67
70
|
"deboa": "^1.2.0",
|
|
68
|
-
"fs-extra": "^11.3.
|
|
71
|
+
"fs-extra": "^11.3.4"
|
|
69
72
|
},
|
|
70
73
|
"devDependencies": {
|
|
71
74
|
"@ni/eslint-config-javascript": "^5.1.4",
|
|
72
75
|
"@ni/eslint-config-typescript": "^5.0.5",
|
|
73
76
|
"@types/fs-extra": "^11.0.4",
|
|
74
|
-
"@types/node": "^25.3.
|
|
75
|
-
"@vitest/coverage-v8": "^
|
|
76
|
-
"@vitest/ui": "^
|
|
77
|
+
"@types/node": "^25.3.5",
|
|
78
|
+
"@vitest/coverage-v8": "^4.0.18",
|
|
79
|
+
"@vitest/ui": "^4.0.18",
|
|
77
80
|
"beachball": "^2.63.0",
|
|
78
81
|
"eslint": "^9.39.3",
|
|
79
82
|
"eslint-plugin-n": "^17.24.0",
|
|
80
|
-
"eslint-plugin-tsdoc": "^0.5.
|
|
83
|
+
"eslint-plugin-tsdoc": "^0.5.2",
|
|
81
84
|
"typescript": "^5.9.3",
|
|
82
|
-
"vitest": "^
|
|
85
|
+
"vitest": "^4.0.18"
|
|
83
86
|
}
|
|
84
87
|
}
|