From 37512cfaa602ae3eb18e449c31003e77020eff00 Mon Sep 17 00:00:00 2001 From: Juergen Kunz Date: Sat, 25 Apr 2026 13:57:59 +0000 Subject: [PATCH] refactor(cloudly): consume external interfaces package --- package.json | 1 + pnpm-lock.yaml | 40 ++ ts/00demo/demo.data.images.ts | 6 +- ts/manager.auth/classes.authmanager.ts | 2 +- .../classes.deploymentmanager.ts | 11 +- ts/manager.node/classes.nodemanager.ts | 2 +- ts/manager.task/predefinedtasks.ts | 4 +- ts_apiclient/classes.cloudlyapiclient.ts | 12 +- ts_apiclient/classes.externalregistry.ts | 1 + ts_interfaces/00_commitinfo_data.ts | 8 - ts_interfaces/data/baremetal.ts | 73 ---- ts_interfaces/data/cloudlyconfig.ts | 14 - ts_interfaces/data/cluster.ts | 41 -- ts_interfaces/data/clusternode.ts | 71 ---- ts_interfaces/data/config.ts | 1 - ts_interfaces/data/deployment.ts | 63 --- ts_interfaces/data/dns.ts | 100 ----- ts_interfaces/data/docker.ts | 15 - ts_interfaces/data/domain.ts | 124 ------ ts_interfaces/data/event.ts | 11 - ts_interfaces/data/externalregistry.ts | 110 ----- ts_interfaces/data/image.ts | 20 - ts_interfaces/data/index.ts | 21 - ts_interfaces/data/secretbundle.ts | 61 --- ts_interfaces/data/secretgroup.ts | 54 --- ts_interfaces/data/server.ts | 36 -- ts_interfaces/data/service.ts | 77 ---- ts_interfaces/data/settings.ts | 56 --- ts_interfaces/data/status.ts | 20 - ts_interfaces/data/taskexecution.ts | 84 ---- ts_interfaces/data/traffic.ts | 5 - ts_interfaces/data/user.ts | 30 -- ts_interfaces/data/version.ts | 11 - ts_interfaces/index.ts | 9 - ts_interfaces/platformservice/00readme.md | 1 - ts_interfaces/platformservice/aibridge.ts | 23 -- ts_interfaces/platformservice/index.ts | 13 - ts_interfaces/platformservice/letter.ts | 34 -- ts_interfaces/platformservice/mta.ts | 70 ---- .../platformservice/pushnotification.ts | 16 - ts_interfaces/platformservice/sms.ts | 33 -- ts_interfaces/plugins.ts | 20 - ts_interfaces/readme.md | 391 ------------------ ts_interfaces/requests/admin.ts | 16 - ts_interfaces/requests/baremetal.ts | 22 - ts_interfaces/requests/certificate.ts | 18 - ts_interfaces/requests/cluster.ts | 83 ---- ts_interfaces/requests/config.ts | 48 --- ts_interfaces/requests/deployment.ts | 141 ------- ts_interfaces/requests/dns.ts | 93 ----- ts_interfaces/requests/domain.ts | 99 ----- ts_interfaces/requests/externalregistry.ts | 89 ---- ts_interfaces/requests/identity.ts | 23 -- ts_interfaces/requests/image.ts | 95 ----- ts_interfaces/requests/index.ts | 55 --- ts_interfaces/requests/inform.ts | 12 - ts_interfaces/requests/log.ts | 13 - ts_interfaces/requests/network.ts | 9 - ts_interfaces/requests/node.ts | 33 -- ts_interfaces/requests/routing.ts | 12 - ts_interfaces/requests/secretbundle.ts | 103 ----- ts_interfaces/requests/secretgroup.ts | 74 ---- ts_interfaces/requests/server.ts | 47 --- ts_interfaces/requests/service.ts | 95 ----- ts_interfaces/requests/settings.ts | 59 --- ts_interfaces/requests/status.ts | 12 - ts_interfaces/requests/task.ts | 95 ----- ts_interfaces/requests/version.ts | 8 - ts_interfaces/tspublish.json | 13 - ts_web/elements/views/backups/index.ts | 3 +- ts_web/elements/views/clusters/index.ts | 3 +- ts_web/elements/views/dbs/index.ts | 3 +- ts_web/elements/views/domains/index.ts | 2 +- ts_web/elements/views/logs/index.ts | 3 +- ts_web/elements/views/mails/index.ts | 3 +- ts_web/elements/views/s3/index.ts | 3 +- ts_web/elements/views/services/index.ts | 2 +- tsconfig.json | 5 +- 78 files changed, 75 insertions(+), 3114 deletions(-) delete mode 100644 ts_interfaces/00_commitinfo_data.ts delete mode 100644 ts_interfaces/data/baremetal.ts delete mode 100644 ts_interfaces/data/cloudlyconfig.ts delete mode 100644 ts_interfaces/data/cluster.ts delete mode 100644 ts_interfaces/data/clusternode.ts delete mode 100644 ts_interfaces/data/config.ts delete mode 100644 ts_interfaces/data/deployment.ts delete mode 100644 ts_interfaces/data/dns.ts delete mode 100644 ts_interfaces/data/docker.ts delete mode 100644 ts_interfaces/data/domain.ts delete mode 100644 ts_interfaces/data/event.ts delete mode 100644 ts_interfaces/data/externalregistry.ts delete mode 100644 ts_interfaces/data/image.ts delete mode 100644 ts_interfaces/data/index.ts delete mode 100644 ts_interfaces/data/secretbundle.ts delete mode 100644 ts_interfaces/data/secretgroup.ts delete mode 100644 ts_interfaces/data/server.ts delete mode 100644 ts_interfaces/data/service.ts delete mode 100644 ts_interfaces/data/settings.ts delete mode 100644 ts_interfaces/data/status.ts delete mode 100644 ts_interfaces/data/taskexecution.ts delete mode 100644 ts_interfaces/data/traffic.ts delete mode 100644 ts_interfaces/data/user.ts delete mode 100644 ts_interfaces/data/version.ts delete mode 100644 ts_interfaces/index.ts delete mode 100644 ts_interfaces/platformservice/00readme.md delete mode 100644 ts_interfaces/platformservice/aibridge.ts delete mode 100644 ts_interfaces/platformservice/index.ts delete mode 100644 ts_interfaces/platformservice/letter.ts delete mode 100644 ts_interfaces/platformservice/mta.ts delete mode 100644 ts_interfaces/platformservice/pushnotification.ts delete mode 100644 ts_interfaces/platformservice/sms.ts delete mode 100644 ts_interfaces/plugins.ts delete mode 100644 ts_interfaces/readme.md delete mode 100644 ts_interfaces/requests/admin.ts delete mode 100644 ts_interfaces/requests/baremetal.ts delete mode 100644 ts_interfaces/requests/certificate.ts delete mode 100644 ts_interfaces/requests/cluster.ts delete mode 100644 ts_interfaces/requests/config.ts delete mode 100644 ts_interfaces/requests/deployment.ts delete mode 100644 ts_interfaces/requests/dns.ts delete mode 100644 ts_interfaces/requests/domain.ts delete mode 100644 ts_interfaces/requests/externalregistry.ts delete mode 100644 ts_interfaces/requests/identity.ts delete mode 100644 ts_interfaces/requests/image.ts delete mode 100644 ts_interfaces/requests/index.ts delete mode 100644 ts_interfaces/requests/inform.ts delete mode 100644 ts_interfaces/requests/log.ts delete mode 100644 ts_interfaces/requests/network.ts delete mode 100644 ts_interfaces/requests/node.ts delete mode 100644 ts_interfaces/requests/routing.ts delete mode 100644 ts_interfaces/requests/secretbundle.ts delete mode 100644 ts_interfaces/requests/secretgroup.ts delete mode 100644 ts_interfaces/requests/server.ts delete mode 100644 ts_interfaces/requests/service.ts delete mode 100644 ts_interfaces/requests/settings.ts delete mode 100644 ts_interfaces/requests/status.ts delete mode 100644 ts_interfaces/requests/task.ts delete mode 100644 ts_interfaces/requests/version.ts delete mode 100644 ts_interfaces/tspublish.json diff --git a/package.json b/package.json index 43eb232..5cb975f 100644 --- a/package.json +++ b/package.json @@ -73,6 +73,7 @@ "@push.rocks/smartunique": "^3.0.9", "@push.rocks/taskbuffer": "^3.4.0", "@push.rocks/webjwt": "^1.0.9", + "@serve.zone/interfaces": "^5.4.3", "@tsclass/tsclass": "^9.2.0" }, "files": [ diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 91fa4dc..461368d 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -134,6 +134,9 @@ importers: '@push.rocks/webjwt': specifier: ^1.0.9 version: 1.0.9 + '@serve.zone/interfaces': + specifier: ^5.4.3 + version: 5.4.3 '@tsclass/tsclass': specifier: ^9.2.0 version: 9.2.0 @@ -884,78 +887,92 @@ packages: resolution: {integrity: sha512-RXwd0CgG+uPRX5YYrkzKyalt2OJYRiJQ8ED/fi1tq9WQW2jsQIn0tqrlR5l5dr/rjqq6AHAxURhj2DVjyQWSOA==} cpu: [arm64] os: [linux] + libc: [glibc] '@img/sharp-libvips-linux-arm@1.2.0': resolution: {integrity: sha512-mWd2uWvDtL/nvIzThLq3fr2nnGfyr/XMXlq8ZJ9WMR6PXijHlC3ksp0IpuhK6bougvQrchUAfzRLnbsen0Cqvw==} cpu: [arm] os: [linux] + libc: [glibc] '@img/sharp-libvips-linux-ppc64@1.2.0': resolution: {integrity: sha512-Xod/7KaDDHkYu2phxxfeEPXfVXFKx70EAFZ0qyUdOjCcxbjqyJOEUpDe6RIyaunGxT34Anf9ue/wuWOqBW2WcQ==} cpu: [ppc64] os: [linux] + libc: [glibc] '@img/sharp-libvips-linux-s390x@1.2.0': resolution: {integrity: sha512-eMKfzDxLGT8mnmPJTNMcjfO33fLiTDsrMlUVcp6b96ETbnJmd4uvZxVJSKPQfS+odwfVaGifhsB07J1LynFehw==} cpu: [s390x] os: [linux] + libc: [glibc] '@img/sharp-libvips-linux-x64@1.2.0': resolution: {integrity: sha512-ZW3FPWIc7K1sH9E3nxIGB3y3dZkpJlMnkk7z5tu1nSkBoCgw2nSRTFHI5pB/3CQaJM0pdzMF3paf9ckKMSE9Tg==} cpu: [x64] os: [linux] + libc: [glibc] '@img/sharp-libvips-linuxmusl-arm64@1.2.0': resolution: {integrity: sha512-UG+LqQJbf5VJ8NWJ5Z3tdIe/HXjuIdo4JeVNADXBFuG7z9zjoegpzzGIyV5zQKi4zaJjnAd2+g2nna8TZvuW9Q==} cpu: [arm64] os: [linux] + libc: [musl] '@img/sharp-libvips-linuxmusl-x64@1.2.0': resolution: {integrity: sha512-SRYOLR7CXPgNze8akZwjoGBoN1ThNZoqpOgfnOxmWsklTGVfJiGJoC/Lod7aNMGA1jSsKWM1+HRX43OP6p9+6Q==} cpu: [x64] os: [linux] + libc: [musl] '@img/sharp-linux-arm64@0.34.3': resolution: {integrity: sha512-QdrKe3EvQrqwkDrtuTIjI0bu6YEJHTgEeqdzI3uWJOH6G1O8Nl1iEeVYRGdj1h5I21CqxSvQp1Yv7xeU3ZewbA==} engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} cpu: [arm64] os: [linux] + libc: [glibc] '@img/sharp-linux-arm@0.34.3': resolution: {integrity: sha512-oBK9l+h6KBN0i3dC8rYntLiVfW8D8wH+NPNT3O/WBHeW0OQWCjfWksLUaPidsrDKpJgXp3G3/hkmhptAW0I3+A==} engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} cpu: [arm] os: [linux] + libc: [glibc] '@img/sharp-linux-ppc64@0.34.3': resolution: {integrity: sha512-GLtbLQMCNC5nxuImPR2+RgrviwKwVql28FWZIW1zWruy6zLgA5/x2ZXk3mxj58X/tszVF69KK0Is83V8YgWhLA==} engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} cpu: [ppc64] os: [linux] + libc: [glibc] '@img/sharp-linux-s390x@0.34.3': resolution: {integrity: sha512-3gahT+A6c4cdc2edhsLHmIOXMb17ltffJlxR0aC2VPZfwKoTGZec6u5GrFgdR7ciJSsHT27BD3TIuGcuRT0KmQ==} engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} cpu: [s390x] os: [linux] + libc: [glibc] '@img/sharp-linux-x64@0.34.3': resolution: {integrity: sha512-8kYso8d806ypnSq3/Ly0QEw90V5ZoHh10yH0HnrzOCr6DKAPI6QVHvwleqMkVQ0m+fc7EH8ah0BB0QPuWY6zJQ==} engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} cpu: [x64] os: [linux] + libc: [glibc] '@img/sharp-linuxmusl-arm64@0.34.3': resolution: {integrity: sha512-vAjbHDlr4izEiXM1OTggpCcPg9tn4YriK5vAjowJsHwdBIdx0fYRsURkxLG2RLm9gyBq66gwtWI8Gx0/ov+JKQ==} engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} cpu: [arm64] os: [linux] + libc: [musl] '@img/sharp-linuxmusl-x64@0.34.3': resolution: {integrity: sha512-gCWUn9547K5bwvOn9l5XGAEjVTTRji4aPTqLzGXHvIr6bIDZKNTA34seMPgM0WmSf+RYBH411VavCejp3PkOeQ==} engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} cpu: [x64] os: [linux] + libc: [musl] '@img/sharp-wasm32@0.34.3': resolution: {integrity: sha512-+CyRcpagHMGteySaWos8IbnXcHgfDn7pO2fiC2slJxvNq9gDipYBN42/RagzctVRKgxATmfqOSulgZv5e1RdMg==} @@ -1229,30 +1246,35 @@ packages: engines: {node: '>= 10'} cpu: [arm64] os: [linux] + libc: [glibc] '@napi-rs/canvas-linux-arm64-musl@0.1.79': resolution: {integrity: sha512-KsrsR3+6uXv70W/1/kY0yRK4/bbdJgA1Vuxw4KyfSc6mjl1DMoYXDAjpBT/5w7AXy6cGG44jm3upvvt/y/dPfg==} engines: {node: '>= 10'} cpu: [arm64] os: [linux] + libc: [musl] '@napi-rs/canvas-linux-riscv64-gnu@0.1.79': resolution: {integrity: sha512-EXaENnSJD6au6z4aKN2PpU9eVNWUsRI2cApm8gCa0WSRMaiYXZsFkXQmhB+Vz2pXahOS8BN2Zd8S1IeML/LCtg==} engines: {node: '>= 10'} cpu: [riscv64] os: [linux] + libc: [glibc] '@napi-rs/canvas-linux-x64-gnu@0.1.79': resolution: {integrity: sha512-3xZhHlE9e3cd9D7Comy6/TTSs/8PUGXEXymIwYQrA1QxHojAlAOFlVai4rffzXd0bHylZu+/wD76LodvYqF1Yw==} engines: {node: '>= 10'} cpu: [x64] os: [linux] + libc: [glibc] '@napi-rs/canvas-linux-x64-musl@0.1.79': resolution: {integrity: sha512-4yv550uCjIEoTFgrpxYZK67nFlDMCQa3LAheM2QrO+B8w1p5w04usIQSCHqHe6aPWlbLQCIqfVcew6/7Q4KuHg==} engines: {node: '>= 10'} cpu: [x64] os: [linux] + libc: [musl] '@napi-rs/canvas-win32-x64-msvc@0.1.79': resolution: {integrity: sha512-sD5qP2njBRnhNlTNFJDdpeCN6aR3qVamLySTwhX3ec8sdfeT/chf/x2dw2UXoIGMoVaVk/y2ifwxBj/h2a2jug==} @@ -1799,21 +1821,25 @@ packages: resolution: {integrity: sha512-hRZygRlaGCjcNTNY9GV7dDI18sG1dK3cc7ujHq72LoDad23zFDUGMQjiSxHWK+/r92iMV+j2MiHbvzayxqynsg==} cpu: [arm64] os: [linux] + libc: [glibc] '@rolldown/binding-linux-arm64-musl@1.0.0-beta.32': resolution: {integrity: sha512-HzgT6h+CXLs+GKAU0Wvkt3rvcv0CmDBsDjlPhh4GHysOKbG9NjpKYX2zvjx671E9pGbTvcPpwy7gGsy7xpu+8g==} cpu: [arm64] os: [linux] + libc: [musl] '@rolldown/binding-linux-x64-gnu@1.0.0-beta.32': resolution: {integrity: sha512-Ab/wbf6gdzphDbsg51UaxsC93foQ7wxhtg0SVCXd25BrV4MAJ1HoDtKN/f4h0maFmJobkqYub2DlmoasUzkvBg==} cpu: [x64] os: [linux] + libc: [glibc] '@rolldown/binding-linux-x64-musl@1.0.0-beta.32': resolution: {integrity: sha512-VoxqGEfh5A1Yx+zBp/FR5QwAbtzbuvky2SVc+ii4g1gLD4zww6mt/hPi5zG+b88zYPFBKHpxMtsz9cWqXU5V5Q==} cpu: [x64] os: [linux] + libc: [musl] '@rolldown/binding-openharmony-arm64@1.0.0-beta.32': resolution: {integrity: sha512-qZ1ViyOUDGbiZrSAJ/FIAhYUElDfVxxFW6DLT/w4KeoZN3HsF4jmRP95mXtl51/oGrqzU9l9Q2f7/P4O/o2ZZA==} @@ -1857,21 +1883,25 @@ packages: resolution: {integrity: sha512-ms6uwECUIcu+6e82C5HJhRMHnfsI+l33v7XQezntzRPN0+sG3EpikEoT7SGbgt4vDwaWLR7wS20suN4qd5r3GA==} cpu: [arm64] os: [linux] + libc: [glibc] '@rspack/binding-linux-arm64-musl@1.4.11': resolution: {integrity: sha512-9evq0DOdxMN/H8VM8ZmyY9NSuBgILNVV6ydBfVPMHPx4r1E7JZGpWeKDegZcS5Erw3sS9kVSIxyX78L5PDzzKw==} cpu: [arm64] os: [linux] + libc: [musl] '@rspack/binding-linux-x64-gnu@1.4.11': resolution: {integrity: sha512-bHYFLxPPYBOSaHdQbEoCYGMQ1gOrEWj7Mro/DLfSHZi1a0okcQ2Q1y0i1DczReim3ZhLGNrK7k1IpFXCRbAobQ==} cpu: [x64] os: [linux] + libc: [glibc] '@rspack/binding-linux-x64-musl@1.4.11': resolution: {integrity: sha512-wrm4E7q2k4+cwT6Uhp6hIQ3eUe/YoaUttj6j5TqHYZX6YeLrNPtD9+ne6lQQ17BV8wmm6NZsmoFIJ5xIptpRhQ==} cpu: [x64] os: [linux] + libc: [musl] '@rspack/binding-wasm32-wasi@1.4.11': resolution: {integrity: sha512-hiYxHZjaZ17wQtXyLCK0IdtOvMWreGVTiGsaHCxyeT+SldDG+r16bXNjmlqfZsjlfl1mkAqKz1dg+mMX28OTqw==} @@ -1911,6 +1941,9 @@ packages: '@sec-ant/readable-stream@0.4.1': resolution: {integrity: sha512-831qok9r2t8AlxLko40y2ebgSDhenenCatLVeW/uBtnHPyhHOvG0C7TvfgecV+wHzIm5KUICgzmVpWS+IMEAeg==} + '@serve.zone/interfaces@5.4.3': + resolution: {integrity: sha512-9ijFhHoC7GYyyAUJbBoDYmcoCmIXTFPiD6fI3x68SWiC0xA+2LG0nOe14D32c1QN9X/3i2Ac5/1sUibfjHsIGg==} + '@shikijs/engine-oniguruma@3.12.2': resolution: {integrity: sha512-hozwnFHsLvujK4/CPVHNo3Bcg2EsnG8krI/ZQ2FlBlCRpPZW4XAEQmEwqegJsypsTAN9ehu2tEYe30lYKSZW/w==} @@ -7944,6 +7977,7 @@ snapshots: - '@aws-sdk/credential-providers' - '@mongodb-js/zstd' - '@nuxt/kit' + - aws-crt - encoding - gcp-metadata - kerberos @@ -9027,6 +9061,12 @@ snapshots: '@sec-ant/readable-stream@0.4.1': {} + '@serve.zone/interfaces@5.4.3': + dependencies: + '@api.global/typedrequest-interfaces': 3.0.19 + '@push.rocks/smartlog-interfaces': 3.0.2 + '@tsclass/tsclass': 9.2.0 + '@shikijs/engine-oniguruma@3.12.2': dependencies: '@shikijs/types': 3.12.2 diff --git a/ts/00demo/demo.data.images.ts b/ts/00demo/demo.data.images.ts index 67ff001..505c5af 100644 --- a/ts/00demo/demo.data.images.ts +++ b/ts/00demo/demo.data.images.ts @@ -6,8 +6,12 @@ export const demoImages: plugins.servezoneInterfaces.data.IImage[] = [ data: { name: 'DemoImage1', description: 'DemoImage1', + location: { + internal: true, + externalRegistryId: '', + externalImageTag: '', + }, versions: [], } } ]; - diff --git a/ts/manager.auth/classes.authmanager.ts b/ts/manager.auth/classes.authmanager.ts index afbc184..911e8a6 100644 --- a/ts/manager.auth/classes.authmanager.ts +++ b/ts/manager.auth/classes.authmanager.ts @@ -50,7 +50,7 @@ export class CloudlyAuthManager { } this.typedrouter.addTypedHandler( - new plugins.typedrequest.TypedHandler( + new plugins.typedrequest.TypedHandler( 'adminLoginWithUsernameAndPassword', async (dataArg) => { let jwt: string; diff --git a/ts/manager.deployment/classes.deploymentmanager.ts b/ts/manager.deployment/classes.deploymentmanager.ts index 83f7919..8eb0564 100644 --- a/ts/manager.deployment/classes.deploymentmanager.ts +++ b/ts/manager.deployment/classes.deploymentmanager.ts @@ -305,8 +305,13 @@ export class DeploymentManager { const node = await this.cloudlyRef.nodeManager.CClusterNode.getInstance({ id: nodeId, }); - if (node && node.data.publicIp) { - await this.cloudlyRef.dnsManager.updateServiceDnsEntriesIp(serviceId, node.data.publicIp); + if (node?.data.baremetalId) { + const baremetal = await this.cloudlyRef.baremetalManager.CBareMetal.getInstance({ + id: node.data.baremetalId, + }); + if (baremetal?.data.primaryIp) { + await this.cloudlyRef.dnsManager.updateServiceDnsEntriesIp(serviceId, baremetal.data.primaryIp); + } } return deployment; @@ -321,4 +326,4 @@ export class DeploymentManager { // Cleanup if needed console.log('DeploymentManager stopped'); } -} \ No newline at end of file +} diff --git a/ts/manager.node/classes.nodemanager.ts b/ts/manager.node/classes.nodemanager.ts index 720992e..59cbdc1 100644 --- a/ts/manager.node/classes.nodemanager.ts +++ b/ts/manager.node/classes.nodemanager.ts @@ -23,7 +23,7 @@ export class CloudlyNodeManager { * is used be serverconfig module on the node to get the actual node config */ this.typedRouter.addTypedHandler( - new plugins.typedrequest.TypedHandler( + new plugins.typedrequest.TypedHandler( 'getNodeConfig', async (requestData) => { const nodeId = requestData.nodeId; diff --git a/ts/manager.task/predefinedtasks.ts b/ts/manager.task/predefinedtasks.ts index 0eebe5b..513079a 100644 --- a/ts/manager.task/predefinedtasks.ts +++ b/ts/manager.task/predefinedtasks.ts @@ -361,7 +361,7 @@ export function createPredefinedTasks(taskManager: CloudlyTaskManager) { // TODO: Get actual resource usage const nodeUsage = { nodeId: node.id, - nodeName: node.data.name, + nodeName: node.data.swarmNodeId || node.id, cpu: Math.random() * 100, // Placeholder memory: Math.random() * 100, // Placeholder disk: Math.random() * 100, // Placeholder @@ -477,7 +477,7 @@ export function createPredefinedTasks(taskManager: CloudlyTaskManager) { type: 'outdated-image', severity: 'medium', image: image.data.name, - version: image.data.version, + version: image.data.versions[0]?.versionString || 'unknown', }); } } diff --git a/ts_apiclient/classes.cloudlyapiclient.ts b/ts_apiclient/classes.cloudlyapiclient.ts index 2a1b0ba..b098080 100644 --- a/ts_apiclient/classes.cloudlyapiclient.ts +++ b/ts_apiclient/classes.cloudlyapiclient.ts @@ -139,7 +139,7 @@ export class CloudlyApiClient { */ public async getServerConfigFromCloudlyByIdentity( identityArg: plugins.servezoneInterfaces.data.IIdentity = this.identity - ): Promise { + ): Promise { const serverConfigRequest = this.typedsocketClient.createTypedRequest( 'getServerConfig' @@ -355,11 +355,12 @@ export class CloudlyApiClient { }> => { const op = 'updateSettings'; const wsReq = this.createWsRequest(op); + const payload = { identity: this.identity, updates } as any; if (wsReq) { - return wsReq.fire({ identity: this.identity, updates }); + return wsReq.fire(payload); } const httpReq = this.createHttpRequest(op); - return httpReq.fire({ identity: this.identity, updates }); + return httpReq.fire(payload); }, testProviderConnection: async (provider: string): Promise<{ connectionValid: boolean; @@ -367,11 +368,12 @@ export class CloudlyApiClient { }> => { const op = 'testProviderConnection'; const wsReq = this.createWsRequest(op); + const payload = { identity: this.identity, provider: provider as any } as any; if (wsReq) { - return wsReq.fire({ identity: this.identity, provider: provider as any }); + return wsReq.fire(payload); } const httpReq = this.createHttpRequest(op); - return httpReq.fire({ identity: this.identity, provider: provider as any }); + return httpReq.fire(payload); } } diff --git a/ts_apiclient/classes.externalregistry.ts b/ts_apiclient/classes.externalregistry.ts index a4db200..86d4537 100644 --- a/ts_apiclient/classes.externalregistry.ts +++ b/ts_apiclient/classes.externalregistry.ts @@ -60,6 +60,7 @@ export class ExternalRegistry implements plugins.servezoneInterfaces.data.IExter ); const response = await updateRegistryTR.fire({ identity: this.cloudlyClientRef.identity, + registryId: this.id, registryData: this.data, }); diff --git a/ts_interfaces/00_commitinfo_data.ts b/ts_interfaces/00_commitinfo_data.ts deleted file mode 100644 index a70d43f..0000000 --- a/ts_interfaces/00_commitinfo_data.ts +++ /dev/null @@ -1,8 +0,0 @@ -/** - * autocreated commitinfo by @push.rocks/commitinfo - */ -export const commitinfo = { - name: '@serve.zone/interfaces', - version: '1.1.2', - description: 'interfaces for working with containers' -} diff --git a/ts_interfaces/data/baremetal.ts b/ts_interfaces/data/baremetal.ts deleted file mode 100644 index 75381e4..0000000 --- a/ts_interfaces/data/baremetal.ts +++ /dev/null @@ -1,73 +0,0 @@ -import * as plugins from '../plugins.js'; - -export interface IBareMetal { - id: string; - data: { - hostname: string; - - /** - * IPMI management IP address - */ - ipmiAddress?: string; - - /** - * Encrypted IPMI credentials - */ - ipmiCredentials?: { - username: string; - passwordEncrypted: string; - }; - - /** - * Primary network IP address - */ - primaryIp: string; - - /** - * Provider of the physical server - */ - provider: 'hetzner' | 'aws' | 'digitalocean' | 'onpremise'; - - /** - * Data center or location - */ - location: string; - - /** - * Hardware specifications - */ - specs: { - cpuModel: string; - cpuCores: number; - memoryGB: number; - storageGB: number; - storageType: 'ssd' | 'hdd' | 'nvme'; - }; - - /** - * Current power state - */ - powerState: 'on' | 'off' | 'unknown'; - - /** - * Operating system information - */ - osInfo: { - name: string; - version: string; - kernel?: string; - }; - - /** - * Array of ClusterNode IDs running on this hardware - */ - assignedNodeIds: string[]; - - /** - * Metadata for provider-specific information - */ - providerMetadata?: { - [key: string]: any; - }; - }; -} \ No newline at end of file diff --git a/ts_interfaces/data/cloudlyconfig.ts b/ts_interfaces/data/cloudlyconfig.ts deleted file mode 100644 index 9ea2d4b..0000000 --- a/ts_interfaces/data/cloudlyconfig.ts +++ /dev/null @@ -1,14 +0,0 @@ -import * as plugins from '../plugins.js'; - -export interface ICloudlyConfig { - environment?: 'production' | 'integration'; - letsEncryptEmail?: string; - letsEncryptPrivateKey?: string; - jwtKeypair?: plugins.tsclass.network.IJwtKeypair; - mongoDescriptor?: plugins.tsclass.database.IMongoDescriptor; - s3Descriptor?: plugins.tsclass.storage.IS3Descriptor; - publicUrl?: string; - publicPort?: string; - sslMode?: 'none' | 'letsencrypt' | 'external'; - servezoneAdminaccount?: string; -} \ No newline at end of file diff --git a/ts_interfaces/data/cluster.ts b/ts_interfaces/data/cluster.ts deleted file mode 100644 index 8512815..0000000 --- a/ts_interfaces/data/cluster.ts +++ /dev/null @@ -1,41 +0,0 @@ -import * as plugins from '../plugins.js'; - -import { type IDockerRegistryInfo } from '../data/docker.js'; -import type { IClusterNode } from './clusternode.js'; - -export interface ICluster { - id: string; - data: { - name: string; - - /** - * a cluster has a machine user that governs access rights. - */ - userId: string; - - /** - * how can the cluster reach cloudly - */ - cloudlyUrl?: string; - - /** - * Cluster setup mode - manual by default, or auto-provision with cloud provider - */ - setupMode?: 'manual' | 'hetzner' | 'aws' | 'digitalocean'; - - /** - * Nodes that are part of the cluster - */ - nodes: IClusterNode[]; - - /** - * ACME info. This is used to get SSL certificates. - */ - acmeInfo: { - serverAddress: string; - serverSecret: string; - }; - - sshKeys: plugins.tsclass.network.ISshKey[]; - }; -} diff --git a/ts_interfaces/data/clusternode.ts b/ts_interfaces/data/clusternode.ts deleted file mode 100644 index 821abb5..0000000 --- a/ts_interfaces/data/clusternode.ts +++ /dev/null @@ -1,71 +0,0 @@ -import * as plugins from '../plugins.js'; - -export interface IClusterNodeMetrics { - cpuUsagePercent: number; - memoryUsedMB: number; - memoryAvailableMB: number; - diskUsedGB: number; - diskAvailableGB: number; - containerCount: number; - timestamp: number; -} - -export interface IClusterNode { - id: string; - data: { - /** - * Reference to the cluster this node belongs to - */ - clusterId: string; - - /** - * Reference to the physical server (if applicable) - */ - baremetalId?: string; - - /** - * Type of node - */ - nodeType: 'baremetal' | 'vm' | 'container'; - - /** - * Current status of the node - */ - status: 'initializing' | 'online' | 'offline' | 'maintenance'; - - /** - * Role of the node in the cluster - */ - role: 'master' | 'worker'; - - /** - * Timestamp when node joined the cluster - */ - joinedAt: number; - - /** - * Last health check timestamp - */ - lastHealthCheck: number; - - /** - * Current metrics for the node - */ - metrics?: IClusterNodeMetrics; - - /** - * Docker swarm node ID if part of swarm - */ - swarmNodeId?: string; - - /** - * SSH keys deployed to this node - */ - sshKeys: plugins.tsclass.network.ISshKey[]; - - /** - * Debian packages installed on this node - */ - requiredDebianPackages: string[]; - }; -} \ No newline at end of file diff --git a/ts_interfaces/data/config.ts b/ts_interfaces/data/config.ts deleted file mode 100644 index 5806ab1..0000000 --- a/ts_interfaces/data/config.ts +++ /dev/null @@ -1 +0,0 @@ -export type TConfigType = 'server' | 'cluster' | 'coreflow' | 'service'; diff --git a/ts_interfaces/data/deployment.ts b/ts_interfaces/data/deployment.ts deleted file mode 100644 index ada7619..0000000 --- a/ts_interfaces/data/deployment.ts +++ /dev/null @@ -1,63 +0,0 @@ -import * as plugins from '../plugins.js'; - -/** - * a deployment happens when a service is deployed - * tracks the status of a deployment - */ -export interface IDeployment { - id: string; - - /** - * The service being deployed (single service per deployment) - */ - serviceId: string; - - /** - * The node this deployment is running on - */ - nodeId: string; - - /** - * Docker container ID for this deployment - */ - containerId?: string; - - /** - * Image used for this deployment - */ - usedImageId: string; - - /** - * Version of the service deployed - */ - version: string; - - /** - * Timestamp when deployed - */ - deployedAt: number; - - /** - * Deployment log entries - */ - deploymentLog: string[]; - - /** - * Current status of the deployment - */ - status: 'scheduled' | 'starting' | 'running' | 'stopping' | 'stopped' | 'failed'; - - /** - * Health status of the deployment - */ - healthStatus?: 'healthy' | 'unhealthy' | 'unknown'; - - /** - * Resource usage for this deployment - */ - resourceUsage?: { - cpuUsagePercent: number; - memoryUsedMB: number; - lastUpdated: number; - }; -} \ No newline at end of file diff --git a/ts_interfaces/data/dns.ts b/ts_interfaces/data/dns.ts deleted file mode 100644 index ee5111a..0000000 --- a/ts_interfaces/data/dns.ts +++ /dev/null @@ -1,100 +0,0 @@ -export type TDnsRecordType = 'A' | 'AAAA' | 'CNAME' | 'MX' | 'TXT' | 'NS' | 'SOA' | 'SRV' | 'CAA' | 'PTR'; - -export interface IDnsEntry { - id: string; - data: { - /** - * The DNS record type - */ - type: TDnsRecordType; - - /** - * The DNS record name (e.g., www, @, mail) - * @ represents the root domain - */ - name: string; - - /** - * The value of the DNS record - * - For A/AAAA: IP address - * - For CNAME: Target domain - * - For MX: Mail server hostname - * - For TXT: Text value - * - For NS: Nameserver hostname - * - For SRV: Target hostname - * - For CAA: CAA record value - * - For PTR: Domain name - */ - value: string; - - /** - * Time to live in seconds - * Default: 3600 (1 hour) - */ - ttl: number; - - /** - * Priority (used for MX and SRV records) - * Lower values have higher priority - */ - priority?: number; - - /** - * The DNS zone this entry belongs to - * e.g., example.com - * @deprecated Use domainId instead - */ - zone: string; - - /** - * The domain ID this DNS entry belongs to - * Links to the Domain entity - */ - domainId?: string; - - /** - * Additional fields for SRV records - */ - weight?: number; - port?: number; - - /** - * Whether this DNS entry is active - */ - active: boolean; - - /** - * Optional description for documentation - */ - description?: string; - - /** - * Timestamp when the entry was created - */ - createdAt?: number; - - /** - * Timestamp when the entry was last updated - */ - updatedAt?: number; - - /** - * Whether this DNS entry was auto-generated - */ - isAutoGenerated?: boolean; - - /** - * The service ID that created this DNS entry (for auto-generated entries) - */ - sourceServiceId?: string; - - /** - * The source type of this DNS entry - * - manual: Created by user through UI/API - * - service: Auto-generated from service configuration - * - system: Created by system processes - * - external: Synced from external DNS providers - */ - sourceType?: 'manual' | 'service' | 'system' | 'external'; - }; -} \ No newline at end of file diff --git a/ts_interfaces/data/docker.ts b/ts_interfaces/data/docker.ts deleted file mode 100644 index ef0c503..0000000 --- a/ts_interfaces/data/docker.ts +++ /dev/null @@ -1,15 +0,0 @@ -import * as plugins from '../plugins.js'; - -export interface IDockerRegistryInfo { - serveraddress: string; - username: string; - password: string; -} - -export interface IServiceRessources { - cpuLimit?: number; - cpuReservation?: number; - memorySizeLimitMB?: number; - memorySizeReservationMB?: number; - volumeMounts?: plugins.tsclass.container.IVolumeMount[]; -} diff --git a/ts_interfaces/data/domain.ts b/ts_interfaces/data/domain.ts deleted file mode 100644 index 0826d92..0000000 --- a/ts_interfaces/data/domain.ts +++ /dev/null @@ -1,124 +0,0 @@ -export type TDomainStatus = 'active' | 'pending' | 'expired' | 'suspended' | 'transferred'; -export type TDomainVerificationStatus = 'verified' | 'pending' | 'failed' | 'not_required'; - -export interface IDomain { - id: string; - data: { - /** - * The domain name (e.g., example.com) - */ - name: string; - - /** - * Description or notes about the domain - */ - description?: string; - - /** - * Current status of the domain - */ - status: TDomainStatus; - - /** - * Domain verification status - */ - verificationStatus: TDomainVerificationStatus; - - /** - * Nameservers for the domain - */ - nameservers: string[]; - - /** - * Domain registrar information - */ - registrar?: { - name: string; - url?: string; - }; - - /** - * Domain registration date (timestamp) - */ - registeredAt?: number; - - /** - * Domain expiration date (timestamp) - */ - expiresAt?: number; - - /** - * Whether auto-renewal is enabled - */ - autoRenew: boolean; - - /** - * DNSSEC enabled - */ - dnssecEnabled?: boolean; - - /** - * Tags for categorization - */ - tags?: string[]; - - /** - * Whether this domain is primary for the organization - */ - isPrimary?: boolean; - - /** - * SSL certificate status - */ - sslStatus?: 'active' | 'pending' | 'expired' | 'none'; - - /** - * Cloudly activation state controls whether we actively manage DNS/certificates - * - available: discovered/imported, not actively managed - * - activated: actively managed (DNS edits allowed, certs considered) - * - ignored: explicitly ignored from management/automation - */ - activationState?: 'available' | 'activated' | 'ignored'; - - /** - * Last verification attempt timestamp - */ - lastVerificationAt?: number; - - /** - * Verification method used - */ - verificationMethod?: 'dns' | 'http' | 'email' | 'manual'; - - /** - * Verification token (for DNS/HTTP verification) - */ - verificationToken?: string; - - /** - * Cloudflare zone ID if managed by Cloudflare - */ - cloudflareZoneId?: string; - - /** - * Sync metadata - */ - syncSource?: 'cloudflare' | 'manual' | null; - lastSyncAt?: number; - - /** - * Whether domain is managed externally - */ - isExternal?: boolean; - - /** - * Creation timestamp - */ - createdAt?: number; - - /** - * Last update timestamp - */ - updatedAt?: number; - }; -} diff --git a/ts_interfaces/data/event.ts b/ts_interfaces/data/event.ts deleted file mode 100644 index d548bc7..0000000 --- a/ts_interfaces/data/event.ts +++ /dev/null @@ -1,11 +0,0 @@ -import * as plugins from '../plugins.js'; - -export interface IEvent_Cloudly_ContainerVersionNotification - extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedEvent, - IEvent_Cloudly_ContainerVersionNotification - > { - name: 'newContainerVersion'; - uniqueEventId: string; - payload: plugins.tsclass.container.IContainer; -} diff --git a/ts_interfaces/data/externalregistry.ts b/ts_interfaces/data/externalregistry.ts deleted file mode 100644 index 4ecbbc0..0000000 --- a/ts_interfaces/data/externalregistry.ts +++ /dev/null @@ -1,110 +0,0 @@ -import * as plugins from '../plugins.js'; - -export interface IExternalRegistry { - id: string; - data: { - /** - * Registry type - */ - type: 'docker' | 'npm'; - - /** - * Human-readable name for the registry - */ - name: string; - - /** - * Registry URL (e.g., https://registry.gitlab.com, docker.io) - */ - url: string; - - /** - * Username for authentication (optional for token-based or public registries) - */ - username?: string; - - /** - * Password, access token, or API key for authentication (optional for public registries) - */ - password?: string; - - /** - * Optional description - */ - description?: string; - - /** - * Whether this is the default registry for its type - */ - isDefault?: boolean; - - /** - * Authentication type - */ - authType?: 'none' | 'basic' | 'token' | 'oauth2'; - - /** - * Allow insecure registry connections (HTTP or self-signed certs) - */ - insecure?: boolean; - - /** - * Optional namespace/organization for the registry - */ - namespace?: string; - - /** - * Proxy configuration - */ - proxy?: { - http?: string; - https?: string; - noProxy?: string; - }; - - /** - * Registry-specific configuration - */ - config?: { - /** - * For Docker registries - */ - dockerConfig?: { - email?: string; - serverAddress?: string; - }; - /** - * For npm registries - */ - npmConfig?: { - scope?: string; - alwaysAuth?: boolean; - }; - }; - - /** - * Status of the registry connection - */ - status?: 'active' | 'inactive' | 'error' | 'unverified'; - - /** - * Last error message if status is 'error' - */ - lastError?: string; - - /** - * Timestamp when the registry was last successfully verified - */ - lastVerified?: number; - - /** - * Timestamp when the registry was created - */ - createdAt?: number; - - /** - * Timestamp when the registry was last updated - */ - updatedAt?: number; - }; -} \ No newline at end of file diff --git a/ts_interfaces/data/image.ts b/ts_interfaces/data/image.ts deleted file mode 100644 index 18314bf..0000000 --- a/ts_interfaces/data/image.ts +++ /dev/null @@ -1,20 +0,0 @@ -import * as plugins from '../plugins.js'; - -export interface IImage { - id: string; - data: { - name: string; - location: { - internal: boolean; - externalRegistryId: string; - externalImageTag: string; - } - description: string; - versions: Array<{ - versionString: string; - storagePath?: string; - size: number; - createdAt: number; - }>; - }; -} diff --git a/ts_interfaces/data/index.ts b/ts_interfaces/data/index.ts deleted file mode 100644 index 0875717..0000000 --- a/ts_interfaces/data/index.ts +++ /dev/null @@ -1,21 +0,0 @@ -export * from './cloudlyconfig.js'; -export * from './cluster.js'; -export * from './config.js'; -export * from './deployment.js'; -export * from './dns.js'; -export * from './docker.js'; -export * from './domain.js'; -export * from './event.js'; -export * from './externalregistry.js'; -export * from './image.js'; -export * from './secretbundle.js'; -export * from './secretgroup.js'; -export * from './baremetal.js'; -export * from './clusternode.js'; -export * from './settings.js'; -export * from './service.js'; -export * from './status.js'; -export * from './taskexecution.js'; -export * from './traffic.js'; -export * from './user.js'; -export * from './version.js'; diff --git a/ts_interfaces/data/secretbundle.ts b/ts_interfaces/data/secretbundle.ts deleted file mode 100644 index a7fa107..0000000 --- a/ts_interfaces/data/secretbundle.ts +++ /dev/null @@ -1,61 +0,0 @@ -export interface ISecretBundle { - id: string; - data: { - name: string; - description: string; - - /** - * determines if the secret is a service or an external secret - * if external secret additional checks are put in place to protect the secret - * - * * service: - * the bundle belongs to a service and can only be used by that service - * * npmci: - * the bundle is a secret bundle that is used by an npmci pipeline - * production secrets will be omitted in any case - * * gitzone: - * the bundle is a secret bundle that is used by a gitzone. - * Only local environment variables are allowed - * * external: - * the bundle is a secret bundle that is used by an external service - */ - type: 'service' | 'npmci' | 'gitzone' | 'external'; - - - /** - * set this if the secretBundle belongs to a service - */ - serviceId?: string; - - /** - * You can add specific secret groups using this - */ - includedSecretGroupIds: string[]; - - /** - * access to this secretBundle also grants access to resources with matching tags - */ - includedTags: { - key: string; - value?: string; - }[]; - - /** - * access to this secretBundle also grants access to the images - */ - imageClaims: { - imageId: string; - permissions: ('read' | 'write')[]; - }[]; - - /** - * authrozations select a specific environment of a config bundle - */ - authorizations: Array; - }; -} - -export interface ISecretBundleAuthorization { - secretAccessKey: string; - environment: string; -} diff --git a/ts_interfaces/data/secretgroup.ts b/ts_interfaces/data/secretgroup.ts deleted file mode 100644 index 10fe73e..0000000 --- a/ts_interfaces/data/secretgroup.ts +++ /dev/null @@ -1,54 +0,0 @@ -export interface ISecretGroup { - /** - * the insatnce id. This should be a random id, except for default - */ - id: string; - - data: { - name: string; - description: string; - - /** - * the key of the secretgroup like CI_RUNNER_TOKEN - */ - key: string; - - /** - * the priority of the secretgroup - * will be used to determine which secretgroup will be used - * when there are multiple secretgroups with the same key - */ - priority?: number; - - /** - * any tags that can be used to filter the secretgroup - * can be used for putting secrets into projects - */ - tags: { - key: string; - value: string; - }[]; - /** - * the values for this secretGroup - */ - environments: { - [key: string]: { - value: string; - - /** - * can be used to update the value - */ - updateToken?: string; - - /** - * the linux timestamp of the last update - */ - lastUpdated: number; - history: { - timestamp: string; - value: string; - }[]; - }; - }; - }; -} diff --git a/ts_interfaces/data/server.ts b/ts_interfaces/data/server.ts deleted file mode 100644 index 7b04289..0000000 --- a/ts_interfaces/data/server.ts +++ /dev/null @@ -1,36 +0,0 @@ -import * as plugins from '../plugins.js'; - -import { type IDockerRegistryInfo } from './docker.js'; - -export interface IServerMetrics { - serverId: string; - cpuUsageInPercent: number; - memoryUsageinMB: number; - memoryAvailableInMB: number; - containerCount: number; - containerMetrics: Array<{ - containerId: string; - containerName: string; - cpuUsageInPercent: number; - memoryUsageInMB: number; - }>; -} - -export interface IServer { - id: string; - data: { - type: 'baremetal' | 'hetzner'; - - assignedClusterId: string; - - /** - * a list of debian packages to be installed - */ - requiredDebianPackages: string[]; - - /** - * a list of SSH keys to deploy - */ - sshKeys: plugins.tsclass.network.ISshKey[]; - }; -} diff --git a/ts_interfaces/data/service.ts b/ts_interfaces/data/service.ts deleted file mode 100644 index 4d51429..0000000 --- a/ts_interfaces/data/service.ts +++ /dev/null @@ -1,77 +0,0 @@ -import type { IServiceRessources } from './docker.js'; - -export interface IService { - id: string; - data: { - name: string; - description: string; - imageId: string; - imageVersion: string; - environment: { [key: string]: string }; - /** - * the main secret bundle id, exclusive to the service - */ - secretBundleId: string; - /** - * those secret bundle ids do not belong to the service itself - * and thus live past the service lifecycle - */ - additionalSecretBundleIds?: string[]; - - /** - * Service category determines deployment behavior - * - base: Core services that run on every node (coreflow, coretraffic, corelog) - * - distributed: Services that run on limited nodes (cores3, coremongo) - * - workload: User applications - */ - serviceCategory: 'base' | 'distributed' | 'workload'; - - /** - * Deployment strategy for the service - * - all-nodes: Deploy to every node in the cluster - * - limited-replicas: Deploy to a limited number of nodes - * - custom: Custom deployment logic - */ - deploymentStrategy: 'all-nodes' | 'limited-replicas' | 'custom'; - - /** - * Maximum number of replicas for distributed services - * For example, 3 for cores3 or coremongo - */ - maxReplicas?: number; - - /** - * Whether to enforce anti-affinity rules - * When true, tries to spread deployments across different BareMetal servers - */ - antiAffinity?: boolean; - - scaleFactor: number; - balancingStrategy: 'round-robin' | 'least-connections'; - ports: { - web: number; - custom?: { [domain: string]: string }; - }; - resources?: IServiceRessources; - domains: { - /** - * Optional domain ID to specify which domain to use - * If not specified, will use the default domain or require manual configuration - */ - domainId?: string; - /** - * The subdomain name (e.g., 'api', 'www', '@' for root) - */ - name: string; - /** - * The port to expose (defaults to ports.web if not specified) - */ - port?: number; - /** - * The protocol for this domain entry - */ - protocol?: 'http' | 'https' | 'ssh'; - }[]; - deploymentIds: string[]; - }; -} diff --git a/ts_interfaces/data/settings.ts b/ts_interfaces/data/settings.ts deleted file mode 100644 index f551b9f..0000000 --- a/ts_interfaces/data/settings.ts +++ /dev/null @@ -1,56 +0,0 @@ -import * as plugins from '../plugins.js'; - -/** - * Interface for Cloudly settings stored in EasyStore - * These are runtime-configurable settings that can be modified via the UI - */ -export interface ICloudlySettings { - // Cloud Provider Tokens - hetznerToken?: string; - cloudflareToken?: string; - - // AWS Credentials - awsAccessKey?: string; - awsSecretKey?: string; - awsRegion?: string; - - // DigitalOcean - digitalOceanToken?: string; - - // Azure Credentials - azureClientId?: string; - azureClientSecret?: string; - azureTenantId?: string; - azureSubscriptionId?: string; - - // Google Cloud - googleCloudKeyJson?: string; - googleCloudProjectId?: string; - - // Vultr - vultrApiKey?: string; - - // Linode - linodeToken?: string; - - // OVH - ovhApplicationKey?: string; - ovhApplicationSecret?: string; - ovhConsumerKey?: string; - - // Scaleway - scalewayAccessKey?: string; - scalewaySecretKey?: string; - scalewayOrganizationId?: string; - - // Other settings that might be added in the future - [key: string]: string | undefined; -} - -/** - * Interface for masked settings (used in API responses) - * Shows only last 4 characters of sensitive tokens - */ -export type ICloudlySettingsMasked = { - [K in keyof ICloudlySettings]: string | undefined; -}; \ No newline at end of file diff --git a/ts_interfaces/data/status.ts b/ts_interfaces/data/status.ts deleted file mode 100644 index 6f2b5d5..0000000 --- a/ts_interfaces/data/status.ts +++ /dev/null @@ -1,20 +0,0 @@ -import * as plugins from '../plugins.js'; - -export interface IClusterStatus { - name: string; - ip: string; - nodesCount: number; - containersUnderManagementCount: number; - nodeStatusId: string; - containerStatusArray: IContainerStatus[]; -} - -export interface INodeStatus { - nodeId: string; -} - -export interface IContainerStatus { - serviceName: string; - dockerImageUrl: string; - dockerImageVersion: string; -} diff --git a/ts_interfaces/data/taskexecution.ts b/ts_interfaces/data/taskexecution.ts deleted file mode 100644 index 4206aba..0000000 --- a/ts_interfaces/data/taskexecution.ts +++ /dev/null @@ -1,84 +0,0 @@ -/** - * Task execution tracking for the task management system - * Tasks themselves are hard-coded using @push.rocks/taskbuffer - * This interface tracks execution history and outcomes - */ -export interface ITaskExecution { - id: string; - data: { - /** - * Name of the task being executed - */ - taskName: string; - - /** - * Optional description of what the task does - */ - taskDescription?: string; - - /** - * Category for grouping tasks - */ - category?: 'maintenance' | 'deployment' | 'backup' | 'monitoring' | 'cleanup' | 'system' | 'security'; - - /** - * Timestamp when the task started - */ - startedAt: number; - - /** - * Timestamp when the task completed - */ - completedAt?: number; - - /** - * Current status of the task execution - */ - status: 'running' | 'completed' | 'failed' | 'cancelled'; - - /** - * Duration in milliseconds - */ - duration?: number; - - /** - * How the task was triggered - */ - triggeredBy: 'schedule' | 'manual' | 'system'; - - /** - * User ID if manually triggered - */ - userId?: string; - - /** - * Execution logs - */ - logs: Array<{ - timestamp: number; - message: string; - severity: 'info' | 'warning' | 'error' | 'success'; - }>; - - /** - * Task-specific metrics - */ - metrics?: { - [key: string]: any; - }; - - /** - * Final result/output of the task - */ - result?: any; - - /** - * Error details if the task failed - */ - error?: { - message: string; - stack?: string; - code?: string; - }; - }; -} \ No newline at end of file diff --git a/ts_interfaces/data/traffic.ts b/ts_interfaces/data/traffic.ts deleted file mode 100644 index b5a3bd9..0000000 --- a/ts_interfaces/data/traffic.ts +++ /dev/null @@ -1,5 +0,0 @@ -import * as plugins from '../plugins.js'; - -interface IReverseProxyConfig extends plugins.tsclass.network.IReverseProxyConfig {} - -export { type IReverseProxyConfig }; diff --git a/ts_interfaces/data/user.ts b/ts_interfaces/data/user.ts deleted file mode 100644 index 2e143f4..0000000 --- a/ts_interfaces/data/user.ts +++ /dev/null @@ -1,30 +0,0 @@ -export interface IToken { - token: string; - expiresAt: number; - assignedRoles: string[]; -} - -/** - * an identity is assumed by authentication as a user - * an identity is ephemeral and has to be renewed regularly - */ -export interface IIdentity { - name: string; - userId: string; - type: 'machine' | 'human'; - role: 'admin' | 'user' | 'api' | 'cluster'; - expiresAt: number; - /** the jwt token should contain above data for verification */ - jwt: string; -} - -export interface IUser { - id: string; - data: { - type: 'machine' | 'human'; - role: 'admin' | 'user' | 'api' | 'cluster'; - username?: string; - password?: string; - tokens?: IToken[]; - } -} \ No newline at end of file diff --git a/ts_interfaces/data/version.ts b/ts_interfaces/data/version.ts deleted file mode 100644 index 73ce675..0000000 --- a/ts_interfaces/data/version.ts +++ /dev/null @@ -1,11 +0,0 @@ -export interface IContainerVersionData { - /** - * the docker image url - * example: registry.gitlab.com/hosttoday/ht-docker-node:latest - */ - dockerImageUrl: string; - /** - * the docker image version. Note: This is different from docker tags that are often used for versions. - */ - dockerImageVersion: string; -} diff --git a/ts_interfaces/index.ts b/ts_interfaces/index.ts deleted file mode 100644 index e992c34..0000000 --- a/ts_interfaces/index.ts +++ /dev/null @@ -1,9 +0,0 @@ -import * as data from './data/index.js'; -import * as platformservice from './platformservice/index.js'; -import * as requests from './requests/index.js'; - -export { - data, - platformservice, - requests -} diff --git a/ts_interfaces/platformservice/00readme.md b/ts_interfaces/platformservice/00readme.md deleted file mode 100644 index a160700..0000000 --- a/ts_interfaces/platformservice/00readme.md +++ /dev/null @@ -1 +0,0 @@ -The platform folder contains types that can be used for talking with the underlying platform by apps running on serve.zone. \ No newline at end of file diff --git a/ts_interfaces/platformservice/aibridge.ts b/ts_interfaces/platformservice/aibridge.ts deleted file mode 100644 index 54e51dc..0000000 --- a/ts_interfaces/platformservice/aibridge.ts +++ /dev/null @@ -1,23 +0,0 @@ -import * as plugins from '../plugins.js'; - -export interface IChat { - systemMessage: string; - messages: { - role: 'assistant' | 'user'; - content: string; - }[]; -} - -export interface IReq_Chat extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IReq_Chat -> { - method: 'chat', - request: { - chat: IChat; - }; - response: { - chat: IChat; - latestMessage: string; - } -} \ No newline at end of file diff --git a/ts_interfaces/platformservice/index.ts b/ts_interfaces/platformservice/index.ts deleted file mode 100644 index f0c8924..0000000 --- a/ts_interfaces/platformservice/index.ts +++ /dev/null @@ -1,13 +0,0 @@ -import * as aibridge from './aibridge.js'; -import * as letter from './letter.js'; -import * as mta from './mta.js'; -import * as pushnotification from './pushnotification.js'; -import * as sms from './sms.js'; - -export { - aibridge, - letter, - mta, - pushnotification, - sms, -} diff --git a/ts_interfaces/platformservice/letter.ts b/ts_interfaces/platformservice/letter.ts deleted file mode 100644 index 9d94127..0000000 --- a/ts_interfaces/platformservice/letter.ts +++ /dev/null @@ -1,34 +0,0 @@ -import * as plugins from '../plugins.js'; - -export interface IRequest_SendLetter extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_SendLetter -> { - method: 'sendLetter'; - request: { - /** - * will be used in logs - */ - description: string; - /** - * if you send any PDF / invoice that you have not made sure to be letterxpress compliant - * we strongly recommend using a cover page - */ - needsCover: boolean; - title?: string; - from?: plugins.tsclass.business.IAddress; - to?: plugins.tsclass.business.IAddress; - coverBody?: string; - service: ('Einschreiben')[]; - pdfAttachments?: Array<{ - name: string; - binaryAttachmentString: string; - }> - }; - response: { - /** - * this process id allows status retrieval of the letter - */ - processId: string; - }; -} \ No newline at end of file diff --git a/ts_interfaces/platformservice/mta.ts b/ts_interfaces/platformservice/mta.ts deleted file mode 100644 index 2881cb7..0000000 --- a/ts_interfaces/platformservice/mta.ts +++ /dev/null @@ -1,70 +0,0 @@ -import * as plugins from '../plugins.js'; - -export type TTemplates = 'default' | 'linkaction' | 'notification'; - -export interface IReq_SendEmail extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IReq_SendEmail -> { - method: 'sendEmail'; - request: { - title: string; - from: string; - to: string; - body: string; - attachments?: Array<{ - name: string; - binaryAttachmentString: string; - }> - }; - response: { - /** - * the response id allows for handling of responses to that email - */ - responseId: string; - }; -} - -export interface IReq_RegisterRecipient extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IReq_RegisterRecipient -> { - method: 'registerRecepient'; - request: { - emailAddress: string; - }; - response: { - status: 'ok' | 'not ok'; - }; -} - -export interface IReq_CheckEmailStatus extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IReq_CheckEmailStatus -> { - method: 'checkEmailStatus'; - request: { - emailId: string; - }; - response: { - status: string, - details?: { message: string; } - }; -} - -export interface IReq_GetEMailStats extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IReq_GetEMailStats -> { - method: 'getEmailStats'; - request: { - jwt: string; - }; - response: { - totalEmailsSent: number; - totalEmailsDelivered: number; - totalEmailsBounced: number; - averageDeliveryTimeMs: number; - lastUpdated: string; - }; -} diff --git a/ts_interfaces/platformservice/pushnotification.ts b/ts_interfaces/platformservice/pushnotification.ts deleted file mode 100644 index b99cff1..0000000 --- a/ts_interfaces/platformservice/pushnotification.ts +++ /dev/null @@ -1,16 +0,0 @@ -import * as plugins from '../plugins.js'; - -export interface IRequest_SendPushNotification extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_SendPushNotification -> { - method: 'sendPushNotification'; - request: { - deviceToken: string; - message: string; - } - response: { - ok: boolean; - status: string; - } -} \ No newline at end of file diff --git a/ts_interfaces/platformservice/sms.ts b/ts_interfaces/platformservice/sms.ts deleted file mode 100644 index 9150c99..0000000 --- a/ts_interfaces/platformservice/sms.ts +++ /dev/null @@ -1,33 +0,0 @@ -import * as plugins from '../plugins.js'; - -export interface IRequest_SendSms - extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_SendSms - > { - method: 'sendSms'; - request: { - toNumber: number; - fromName: string; - messageText: string; - }; - response: { - status: 'ok' | 'not ok'; - } - } - - export interface IRequest_SendVerificationCode - extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_SendVerificationCode - > { - method: 'sendVerificationCode'; - request: { - toNumber: number; - fromName: string; - }; - response: { - status: 'ok' | 'not ok'; - verificationCode: string; - } - } diff --git a/ts_interfaces/plugins.ts b/ts_interfaces/plugins.ts deleted file mode 100644 index a620bd1..0000000 --- a/ts_interfaces/plugins.ts +++ /dev/null @@ -1,20 +0,0 @@ -// @apiglobal scope -import * as typedrequestInterfaces from '@api.global/typedrequest-interfaces'; - -export { - typedrequestInterfaces -} - -// @push.rocks scope -import * as smartlogInterfaces from '@push.rocks/smartlog-interfaces'; - -export { - smartlogInterfaces, -} - -// tsclass scope -import * as tsclass from '@tsclass/tsclass'; - -export { - tsclass -} diff --git a/ts_interfaces/readme.md b/ts_interfaces/readme.md deleted file mode 100644 index 21269ea..0000000 --- a/ts_interfaces/readme.md +++ /dev/null @@ -1,391 +0,0 @@ -# @serve.zone/interfaces 📋 - -**TypeScript interfaces for the Cloudly ecosystem.** Type-safe contracts for multi-cloud infrastructure management. - -## 🎯 What is @serve.zone/interfaces? - -This package provides the complete set of TypeScript interfaces that power the Cloudly platform. It ensures type safety and consistency across all components - from API requests to data models, from service definitions to infrastructure configurations. - -## ✨ Features - -- **🔒 Type Safety** - Comprehensive TypeScript interfaces for all Cloudly operations -- **📦 Modular Structure** - Organized by domain for easy navigation -- **🔄 Version Compatibility** - Interfaces versioned with the platform -- **📚 Well Documented** - Each interface includes JSDoc comments -- **🎭 Multi-Purpose** - Used by API clients, CLI tools, and web interfaces -- **✅ Validation Ready** - Compatible with runtime type checking libraries - -## 🚀 Installation - -```bash -pnpm add @serve.zone/interfaces -``` - -## 🏗️ Interface Categories - -### 📡 Request/Response Interfaces - -Typed contracts for API communication: - -```typescript -import { - IRequest_GetAllImages, - IRequest_CreateCluster, - IRequest_DeployService -} from '@serve.zone/interfaces'; - -// Type-safe request -const request: IRequest_GetAllImages['request'] = { - identity: userIdentity, - filters: { - tag: 'production' - } -}; - -// Type-safe response -const response: IRequest_GetAllImages['response'] = { - images: [...] -}; -``` - -### 📦 Data Models - -Core data structures for Cloudly entities: - -```typescript -import { - ICluster, - IService, - IImage, - ISecret, - IServer -} from '@serve.zone/interfaces'; - -// Define a service -const service: IService = { - id: 'service-123', - data: { - name: 'api-service', - imageId: 'image-456', - imageVersion: '2.0.0', - environment: { - NODE_ENV: 'production' - }, - scaleFactor: 3, - balancingStrategy: 'round-robin', - ports: { - web: 80, - metrics: 9090 - }, - domains: [ - { name: 'api.example.com' } - ], - deploymentIds: [], - deploymentDirectiveIds: [] - } -}; -``` - -### 🔐 Authentication & Identity - -Identity management interfaces: - -```typescript -import { - IIdentity, - IServiceToken, - IPermission -} from '@serve.zone/interfaces'; - -const identity: IIdentity = { - id: 'user-789', - name: 'service-account', - type: 'service', - permissions: ['cluster:read', 'service:write'], - tokenHash: 'hashed-token', - metadata: { - createdAt: new Date(), - lastAccess: new Date() - } -}; -``` - -### 🌐 Network Configuration - -Networking and routing interfaces: - -```typescript -import { - IReverseProxyConfig, - IDomainConfig, - ILoadBalancerConfig -} from '@serve.zone/interfaces'; - -const proxyConfig: IReverseProxyConfig = { - domain: 'app.example.com', - path: '/api', - serviceAddress: 'http://api-service:3000', - ssl: true, - headers: { - 'X-Real-IP': '$remote_addr' - } -}; -``` - -### 📊 Monitoring & Metrics - -Observability interfaces: - -```typescript -import { - IServerMetrics, - IServiceMetrics, - IClusterHealth -} from '@serve.zone/interfaces'; - -const metrics: IServerMetrics = { - serverId: 'server-001', - cpuUsageInPercent: 65, - memoryUsageinMB: 3072, - memoryAvailableInMB: 8192, - diskUsageInPercent: 40, - networkInMbps: 100, - networkOutMbps: 150, - containerCount: 12, - containerMetrics: [...] -}; -``` - -### 🔒 Secret Management - -Security and credential interfaces: - -```typescript -import { - ISecretGroup, - ISecretBundle, - IEncryptedData -} from '@serve.zone/interfaces'; - -const secretGroup: ISecretGroup = { - id: 'secrets-123', - name: 'database-credentials', - secrets: [ - { - key: 'DB_HOST', - value: 'encrypted-value', - encrypted: true - }, - { - key: 'DB_PASSWORD', - value: 'encrypted-value', - encrypted: true - } - ], - metadata: { - environment: 'production', - service: 'api' - } -}; -``` - -## 📚 Common Usage Patterns - -### Creating Type-Safe API Clients - -```typescript -import { - IRequest_CreateService, - IService -} from '@serve.zone/interfaces'; - -class ServiceClient { - async createService( - serviceData: IService['data'] - ): Promise { - const request: IRequest_CreateService['request'] = { - identity: this.identity, - serviceData - }; - - const response = await this.client.send( - 'createService', - request - ); - - return response.service; - } -} -``` - -### Validating Incoming Data - -```typescript -import { ICluster } from '@serve.zone/interfaces'; -import { validateType } from 'your-validation-library'; - -function validateClusterData(data: unknown): ICluster { - if (!validateType(data)) { - throw new Error('Invalid cluster data'); - } - return data; -} -``` - -### Building Configuration Objects - -```typescript -import { - ICloudlyConfig, - IMongoDescriptor -} from '@serve.zone/interfaces'; - -const config: ICloudlyConfig = { - cfToken: process.env.CF_TOKEN!, - hetznerToken: process.env.HETZNER_TOKEN!, - environment: 'production', - letsEncryptEmail: 'certs@example.com', - publicUrl: 'cloudly.example.com', - publicPort: 443, - mongoDescriptor: { - mongoDbUrl: process.env.MONGO_URL!, - mongoDbName: 'cloudly', - mongoDbUser: process.env.MONGO_USER!, - mongoDbPass: process.env.MONGO_PASS! - } -}; -``` - -## 🎯 Advanced Features - -### Generic Request Handler - -```typescript -import { ITypedRequest } from '@serve.zone/interfaces'; - -class RequestHandler { - async handle( - request: T['request'] - ): Promise { - // Type-safe request handling - return this.processRequest(request); - } -} -``` - -### Discriminated Unions - -```typescript -import { IDeploymentStatus } from '@serve.zone/interfaces'; - -function handleStatus(status: IDeploymentStatus) { - switch (status.type) { - case 'pending': - console.log('Deployment pending...'); - break; - case 'running': - console.log(`Running on ${status.serverId}`); - break; - case 'failed': - console.log(`Failed: ${status.error}`); - break; - } -} -``` - -### Extending Interfaces - -```typescript -import { IService } from '@serve.zone/interfaces'; - -interface IExtendedService extends IService { - customMetadata: { - team: string; - costCenter: string; - sla: 'standard' | 'premium'; - }; -} -``` - -## 🔄 Version Compatibility - -| @serve.zone/interfaces | @serve.zone/cloudly | @serve.zone/api | @serve.zone/cli | -|------------------------|---------------------|-----------------|-----------------| -| 5.x | 5.x | 5.x | 5.x | -| 4.x | 4.x | 4.x | 4.x | -| 3.x | 3.x | 3.x | 3.x | - -## 📖 Interface Documentation - -All interfaces include comprehensive JSDoc comments: - -```typescript -/** - * Represents a cluster configuration - * @interface ICluster - */ -export interface ICluster { - /** - * Unique identifier for the cluster - * @type {string} - */ - id: string; - - /** - * Cluster configuration data - * @type {IClusterData} - */ - data: IClusterData; -} -``` - -## 🛠️ Development Tips - -### Import Organization - -```typescript -// Group imports by category -import { - // Data models - ICluster, - IService, - IImage, - - // Requests - IRequest_CreateCluster, - IRequest_DeployService, - - // Configuration - ICloudlyConfig, - IReverseProxyConfig -} from '@serve.zone/interfaces'; -``` - -### Type Guards - -```typescript -import { IService, ICluster } from '@serve.zone/interfaces'; - -function isService(entity: IService | ICluster): entity is IService { - return 'imageId' in entity.data; -} -``` - -## License and Legal Information - -This repository contains open-source code that is licensed under the MIT License. A copy of the MIT License can be found in the [license](license) file within this repository. - -**Please note:** The MIT License does not grant permission to use the trade names, trademarks, service marks, or product names of the project, except as required for reasonable and customary use in describing the origin of the work and reproducing the content of the NOTICE file. - -### Trademarks - -This project is owned and maintained by Task Venture Capital GmbH. The names and logos associated with Task Venture Capital GmbH and any related products or services are trademarks of Task Venture Capital GmbH and are not included within the scope of the MIT license granted herein. Use of these trademarks must comply with Task Venture Capital GmbH's Trademark Guidelines, and any usage must be approved in writing by Task Venture Capital GmbH. - -### Company Information - -Task Venture Capital GmbH -Registered at District court Bremen HRB 35230 HB, Germany - -For any legal inquiries or if you require further information, please contact us via email at hello@task.vc. - -By using this repository, you acknowledge that you have read this section, agree to comply with its terms, and understand that the licensing of the code does not imply endorsement by Task Venture Capital GmbH of any derivative works. \ No newline at end of file diff --git a/ts_interfaces/requests/admin.ts b/ts_interfaces/requests/admin.ts deleted file mode 100644 index 71dd54b..0000000 --- a/ts_interfaces/requests/admin.ts +++ /dev/null @@ -1,16 +0,0 @@ -import * as plugins from '../plugins.js'; -import * as userInterfaces from '../data/user.js'; - -export interface IReq_Admin_LoginWithUsernameAndPassword extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IReq_Admin_LoginWithUsernameAndPassword -> { - method: 'adminLoginWithUsernameAndPassword'; - request: { - username: string; - password: string; - }; - response: { - identity: userInterfaces.IIdentity; - } -} \ No newline at end of file diff --git a/ts_interfaces/requests/baremetal.ts b/ts_interfaces/requests/baremetal.ts deleted file mode 100644 index ba26fda..0000000 --- a/ts_interfaces/requests/baremetal.ts +++ /dev/null @@ -1,22 +0,0 @@ -import * as plugins from '../plugins.js'; -import type { IBareMetal } from '../data/baremetal.js'; - -export interface IRequest_Any_Cloudly_GetBaremetalServers { - method: 'getBaremetalServers'; - request: {}; - response: { - baremetals: IBareMetal[]; - }; -} - -export interface IRequest_Any_Cloudly_ControlBaremetal { - method: 'controlBaremetal'; - request: { - baremetalId: string; - action: 'powerOn' | 'powerOff' | 'reset'; - }; - response: { - success: boolean; - message: string; - }; -} \ No newline at end of file diff --git a/ts_interfaces/requests/certificate.ts b/ts_interfaces/requests/certificate.ts deleted file mode 100644 index 5616a6c..0000000 --- a/ts_interfaces/requests/certificate.ts +++ /dev/null @@ -1,18 +0,0 @@ -import * as plugins from '../plugins.js'; -import * as userInterfaces from '../data/user.js'; - -export interface IRequest_Any_Cloudly_GetCertificateForDomain - extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_Any_Cloudly_GetCertificateForDomain - > { - method: 'getCertificateForDomain'; - request: { - identity: userInterfaces.IIdentity; - domainName: string; - type: 'ssl'; - }; - response: { - certificate: plugins.tsclass.network.ICert; - }; -} diff --git a/ts_interfaces/requests/cluster.ts b/ts_interfaces/requests/cluster.ts deleted file mode 100644 index 9401777..0000000 --- a/ts_interfaces/requests/cluster.ts +++ /dev/null @@ -1,83 +0,0 @@ -import * as userInterfaces from '../data/user.js'; -import * as clusterInterfaces from '../data/cluster.js'; -import * as plugins from '../plugins.js'; - -/** - * get all clusters - */ -export interface IReq_Any_Cloudly_GetClusters extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IReq_Any_Cloudly_GetClusters -> { - method: 'getClusters'; - request: { - identity: userInterfaces.IIdentity; - }; - response: { - clusters: clusterInterfaces.ICluster[]; - }; -} - -export interface IReq_Any_Cloudly_GetClusterById -extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IReq_Any_Cloudly_GetClusterById -> { - method: 'getClusterById'; - request: { - identity: userInterfaces.IIdentity; - clusterId: string; - }; - response: { - cluster: clusterInterfaces.ICluster; - }; -} - -export interface IRequest_CreateCluster extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_CreateCluster -> { - method: 'createCluster'; - request: { - identity: userInterfaces.IIdentity; - clusterName: string; - setupMode?: 'manual' | 'hetzner' | 'aws' | 'digitalocean'; - }; - response: { - cluster: clusterInterfaces.ICluster; - }; -} - -/** - * updates a cluster - */ -export interface IReq_Any_Cloudly_UpdateCluster extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IReq_Any_Cloudly_UpdateCluster -> { - method: 'updateCluster'; - request: { - identity: userInterfaces.IIdentity; - clusterData: clusterInterfaces.ICluster['data']; - }; - response: { - resultCluster: clusterInterfaces.ICluster; - }; -} - -/** - * deletes a cluster - */ -export interface IReq_Any_Cloudly_DeleteClusterById extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IReq_Any_Cloudly_DeleteClusterById -> { - method: 'deleteClusterById'; - request: { - identity: userInterfaces.IIdentity; - clusterId: string; - }; - response: { - ok: boolean; - }; -} diff --git a/ts_interfaces/requests/config.ts b/ts_interfaces/requests/config.ts deleted file mode 100644 index b53a831..0000000 --- a/ts_interfaces/requests/config.ts +++ /dev/null @@ -1,48 +0,0 @@ -import * as plugins from '../plugins.js'; -import * as clusterInterfaces from '../data/cluster.js'; -import * as serverInterfaces from '../data/server.js'; -import * as userInterfaces from '../data/user.js'; -import type { IService } from '../data/service.js'; - -export interface IRequest_Any_Cloudly_GetServerConfig -extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_Any_Cloudly_GetServerConfig -> { - method: 'getServerConfig'; - request: { - identity: userInterfaces.IIdentity; - serverId: string; - }; - response: { - configData: serverInterfaces.IServer; - }; -} - -export interface IRequest_Any_Cloudly_GetClusterConfig -extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_Any_Cloudly_GetClusterConfig -> { - method: 'getClusterConfig'; - request: { - identity: userInterfaces.IIdentity; - }; - response: { - configData: clusterInterfaces.ICluster; - services: IService[]; - }; -} - -export interface IRequest_Cloudly_Coreflow_PushClusterConfig -extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_Cloudly_Coreflow_PushClusterConfig -> { - method: 'pushClusterConfig'; - request: { - configData: clusterInterfaces.ICluster; - services: IService[]; - }; - response: {}; -} diff --git a/ts_interfaces/requests/deployment.ts b/ts_interfaces/requests/deployment.ts deleted file mode 100644 index f8cce68..0000000 --- a/ts_interfaces/requests/deployment.ts +++ /dev/null @@ -1,141 +0,0 @@ -import * as plugins from '../plugins.js'; -import type { IDeployment } from '../data/deployment.js'; -import type { IIdentity } from '../data/user.js'; - -export interface IReq_Any_Cloudly_GetDeploymentById -extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IReq_Any_Cloudly_GetDeploymentById -> { - method: 'getDeploymentById'; - request: { - identity: IIdentity; - deploymentId: string; - }; - response: { - deployment: IDeployment; - }; -} - -export interface IReq_Any_Cloudly_GetDeployments -extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IReq_Any_Cloudly_GetDeployments -> { - method: 'getDeployments'; - request: { - identity: IIdentity; - }; - response: { - deployments: IDeployment[]; - }; -} - -export interface IReq_Any_Cloudly_GetDeploymentsByService -extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IReq_Any_Cloudly_GetDeploymentsByService -> { - method: 'getDeploymentsByService'; - request: { - identity: IIdentity; - serviceId: string; - }; - response: { - deployments: IDeployment[]; - }; -} - -export interface IReq_Any_Cloudly_GetDeploymentsByNode -extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IReq_Any_Cloudly_GetDeploymentsByNode -> { - method: 'getDeploymentsByNode'; - request: { - identity: IIdentity; - nodeId: string; - }; - response: { - deployments: IDeployment[]; - }; -} - -export interface IReq_Any_Cloudly_CreateDeployment -extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IReq_Any_Cloudly_CreateDeployment -> { - method: 'createDeployment'; - request: { - identity: IIdentity; - deploymentData: Partial; - }; - response: { - deployment: IDeployment; - }; -} - -export interface IReq_Any_Cloudly_UpdateDeployment -extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IReq_Any_Cloudly_UpdateDeployment -> { - method: 'updateDeployment'; - request: { - identity: IIdentity; - deploymentId: string; - deploymentData: Partial; - }; - response: { - deployment: IDeployment; - }; -} - -export interface IReq_Any_Cloudly_DeleteDeploymentById -extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IReq_Any_Cloudly_DeleteDeploymentById -> { - method: 'deleteDeploymentById'; - request: { - identity: IIdentity; - deploymentId: string; - }; - response: { - success: boolean; - }; -} - -export interface IReq_Any_Cloudly_RestartDeployment -extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IReq_Any_Cloudly_RestartDeployment -> { - method: 'restartDeployment'; - request: { - identity: IIdentity; - deploymentId: string; - }; - response: { - success: boolean; - deployment: IDeployment; - }; -} - -export interface IReq_Any_Cloudly_ScaleDeployment -extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IReq_Any_Cloudly_ScaleDeployment -> { - method: 'scaleDeployment'; - request: { - identity: IIdentity; - deploymentId: string; - replicas: number; - }; - response: { - success: boolean; - deployment: IDeployment; - }; -} \ No newline at end of file diff --git a/ts_interfaces/requests/dns.ts b/ts_interfaces/requests/dns.ts deleted file mode 100644 index d114176..0000000 --- a/ts_interfaces/requests/dns.ts +++ /dev/null @@ -1,93 +0,0 @@ -import * as plugins from '../plugins.js'; -import type { IDnsEntry } from '../data/dns.js'; -import type { IIdentity } from '../data/user.js'; - -export interface IRequest_Any_Cloudly_GetDnsEntries -extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_Any_Cloudly_GetDnsEntries -> { - method: 'getDnsEntries'; - request: { - identity: IIdentity; - zone?: string; // Optional filter by zone - }; - response: { - dnsEntries: IDnsEntry[]; - }; -} - -export interface IRequest_Any_Cloudly_GetDnsEntryById -extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_Any_Cloudly_GetDnsEntryById -> { - method: 'getDnsEntryById'; - request: { - identity: IIdentity; - dnsEntryId: string; - }; - response: { - dnsEntry: IDnsEntry; - }; -} - -export interface IRequest_Any_Cloudly_CreateDnsEntry -extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_Any_Cloudly_CreateDnsEntry -> { - method: 'createDnsEntry'; - request: { - identity: IIdentity; - dnsEntryData: IDnsEntry['data']; - }; - response: { - dnsEntry: IDnsEntry; - }; -} - -export interface IRequest_Any_Cloudly_UpdateDnsEntry -extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_Any_Cloudly_UpdateDnsEntry -> { - method: 'updateDnsEntry'; - request: { - identity: IIdentity; - dnsEntryId: string; - dnsEntryData: IDnsEntry['data']; - }; - response: { - dnsEntry: IDnsEntry; - }; -} - -export interface IRequest_Any_Cloudly_DeleteDnsEntry -extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_Any_Cloudly_DeleteDnsEntry -> { - method: 'deleteDnsEntry'; - request: { - identity: IIdentity; - dnsEntryId: string; - }; - response: { - success: boolean; - }; -} - -export interface IRequest_Any_Cloudly_GetDnsZones -extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_Any_Cloudly_GetDnsZones -> { - method: 'getDnsZones'; - request: { - identity: IIdentity; - }; - response: { - zones: string[]; - }; -} \ No newline at end of file diff --git a/ts_interfaces/requests/domain.ts b/ts_interfaces/requests/domain.ts deleted file mode 100644 index 66362eb..0000000 --- a/ts_interfaces/requests/domain.ts +++ /dev/null @@ -1,99 +0,0 @@ -import * as plugins from '../plugins.js'; -import type { IDomain } from '../data/domain.js'; -import type { IIdentity } from '../data/user.js'; - -export interface IRequest_Any_Cloudly_GetDomains -extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_Any_Cloudly_GetDomains -> { - method: 'getDomains'; - request: { - identity: IIdentity; - }; - response: { - domains: IDomain[]; - }; -} - -export interface IRequest_Any_Cloudly_GetDomainById -extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_Any_Cloudly_GetDomainById -> { - method: 'getDomainById'; - request: { - identity: IIdentity; - domainId: string; - }; - response: { - domain: IDomain; - }; -} - -export interface IRequest_Any_Cloudly_CreateDomain -extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_Any_Cloudly_CreateDomain -> { - method: 'createDomain'; - request: { - identity: IIdentity; - domainData: IDomain['data']; - }; - response: { - domain: IDomain; - }; -} - -export interface IRequest_Any_Cloudly_UpdateDomain -extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_Any_Cloudly_UpdateDomain -> { - method: 'updateDomain'; - request: { - identity: IIdentity; - domainId: string; - domainData: IDomain['data']; - }; - response: { - domain: IDomain; - }; -} - -export interface IRequest_Any_Cloudly_DeleteDomain -extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_Any_Cloudly_DeleteDomain -> { - method: 'deleteDomain'; - request: { - identity: IIdentity; - domainId: string; - }; - response: { - success: boolean; - }; -} - -export interface IRequest_Any_Cloudly_VerifyDomain -extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_Any_Cloudly_VerifyDomain -> { - method: 'verifyDomain'; - request: { - identity: IIdentity; - domainId: string; - verificationMethod?: 'dns' | 'http' | 'email' | 'manual'; - }; - response: { - domain: IDomain; - verificationResult: { - success: boolean; - message?: string; - details?: any; - }; - }; -} \ No newline at end of file diff --git a/ts_interfaces/requests/externalregistry.ts b/ts_interfaces/requests/externalregistry.ts deleted file mode 100644 index 12bb49f..0000000 --- a/ts_interfaces/requests/externalregistry.ts +++ /dev/null @@ -1,89 +0,0 @@ -import * as plugins from '../plugins.js'; -import * as data from '../data/index.js'; -import * as userInterfaces from '../data/user.js'; - -export interface IReq_GetRegistryById extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IReq_GetRegistryById -> { - method: 'getExternalRegistryById'; - request: { - identity: userInterfaces.IIdentity; - id: string; - }; - response: { - registry: data.IExternalRegistry; - }; -} - -export interface IReq_GetRegistries extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IReq_GetRegistries -> { - method: 'getExternalRegistries'; - request: { - identity: userInterfaces.IIdentity; - }; - response: { - registries: data.IExternalRegistry[]; - }; -} - -export interface IReq_CreateRegistry extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IReq_CreateRegistry -> { - method: 'createExternalRegistry'; - request: { - identity: userInterfaces.IIdentity; - registryData: data.IExternalRegistry['data']; - }; - response: { - registry: data.IExternalRegistry; - }; -} - -export interface IReq_UpdateRegistry extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IReq_UpdateRegistry -> { - method: 'updateExternalRegistry'; - request: { - identity: userInterfaces.IIdentity; - registryId: string; - registryData: data.IExternalRegistry['data']; - }; - response: { - resultRegistry: data.IExternalRegistry; - }; -} - -export interface IReq_DeleteRegistryById extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IReq_DeleteRegistryById -> { - method: 'deleteExternalRegistryById'; - request: { - identity: userInterfaces.IIdentity; - registryId: string; - }; - response: { - ok: boolean; - }; -} - -export interface IReq_VerifyRegistry extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IReq_VerifyRegistry -> { - method: 'verifyExternalRegistry'; - request: { - identity: userInterfaces.IIdentity; - registryId: string; - }; - response: { - success: boolean; - message?: string; - registry?: data.IExternalRegistry; - }; -} \ No newline at end of file diff --git a/ts_interfaces/requests/identity.ts b/ts_interfaces/requests/identity.ts deleted file mode 100644 index 0aa5ea3..0000000 --- a/ts_interfaces/requests/identity.ts +++ /dev/null @@ -1,23 +0,0 @@ -import * as plugins from '../plugins.js'; -import * as userInterfaces from '../data/user.js' - -// ======== -// IDENTITY -// ======== - -/** - * get the identity that then will be used to get the config - */ -export interface IRequest_Any_Cloudly_CoreflowManager_GetIdentityByToken -extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_Any_Cloudly_CoreflowManager_GetIdentityByToken -> { - method: 'getIdentityByToken'; - request: { - token: string; - }; - response: { - identity: userInterfaces.IIdentity; - }; -} diff --git a/ts_interfaces/requests/image.ts b/ts_interfaces/requests/image.ts deleted file mode 100644 index 7da482c..0000000 --- a/ts_interfaces/requests/image.ts +++ /dev/null @@ -1,95 +0,0 @@ -import * as plugins from '../plugins.js'; -import * as userInterfaces from '../data/user.js'; - -import type { IImage } from '../data/index.js'; - -export interface IRequest_GetAllImages extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_GetAllImages -> { - method: 'getAllImages'; - request: { - identity: userInterfaces.IIdentity; - }; - response: { - images: IImage[]; - }; -} - -/** - * gets a single image - * authentication can happen via imageClaim or identity - */ -export interface IRequest_GetImage extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_GetImage -> { - method: 'getImage'; - request: { - identity: userInterfaces.IIdentity; - imageId: string; - }; - response: { - image: IImage; - }; -} - -export interface IRequest_CreateImage extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_CreateImage -> { - method: 'createImage'; - request: { - identity: userInterfaces.IIdentity; - name: string; - description: string; - }; - response: { - image: IImage; - }; - -} - -export interface IRequest_PushImageVersion extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_PushImageVersion -> { - method: 'pushImageVersion'; - request: { - identity: userInterfaces.IIdentity; - imageId: string; - versionString: string; - imageStream: plugins.typedrequestInterfaces.IVirtualStream; - }; - response: { - allowed: boolean; - }; -} - -export interface IRequest_PullImageVersion extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_PullImageVersion -> { - method: 'pullImageVersion'; - request: { - identity: userInterfaces.IIdentity; - imageId: string; - versionString: string; - }; - response: { - imageStream: plugins.typedrequestInterfaces.IVirtualStream; - }; -} - -export interface IRequest_DeleteImage extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_DeleteImage -> { - method: 'deleteImage'; - request: { - identity: userInterfaces.IIdentity; - imageId: string; - }; - response: { - }; -} diff --git a/ts_interfaces/requests/index.ts b/ts_interfaces/requests/index.ts deleted file mode 100644 index f3799a3..0000000 --- a/ts_interfaces/requests/index.ts +++ /dev/null @@ -1,55 +0,0 @@ -import * as plugins from '../plugins.js'; - -import * as adminRequests from './admin.js'; -import * as baremetalRequests from './baremetal.js'; -import * as certificateRequests from './certificate.js'; -import * as clusterRequests from './cluster.js'; -import * as configRequests from './config.js'; -import * as deploymentRequests from './deployment.js'; -import * as dnsRequests from './dns.js'; -import * as domainRequests from './domain.js'; -import * as externalRegistryRequests from './externalregistry.js'; -import * as identityRequests from './identity.js'; -import * as imageRequests from './image.js'; -import * as informRequests from './inform.js'; -import * as logRequests from './log.js'; -import * as networkRequests from './network.js'; -import * as nodeRequests from './node.js'; -import * as routingRequests from './routing.js'; -import * as secretBundleRequests from './secretbundle.js'; -import * as secretGroupRequests from './secretgroup.js'; -import * as serverRequests from './server.js'; -import * as serviceRequests from './service.js'; -import * as settingsRequests from './settings.js'; -import * as statusRequests from './status.js'; -import * as taskRequests from './task.js'; -import * as versionRequests from './version.js'; - -export { - adminRequests as admin, - baremetalRequests as baremetal, - certificateRequests as certificate, - clusterRequests as cluster, - configRequests as config, - deploymentRequests as deployment, - dnsRequests as dns, - domainRequests as domain, - externalRegistryRequests as externalRegistry, - identityRequests as identity, - imageRequests as image, - informRequests as inform, - logRequests as log, - networkRequests as network, - nodeRequests as node, - routingRequests as routing, - secretBundleRequests as secretbundle, - secretGroupRequests as secretgroup, - serverRequests as server, - serviceRequests as service, - settingsRequests as settings, - statusRequests as status, - taskRequests as task, - versionRequests as version, -}; - -export * from './inform.js'; \ No newline at end of file diff --git a/ts_interfaces/requests/inform.ts b/ts_interfaces/requests/inform.ts deleted file mode 100644 index e2bb1ee..0000000 --- a/ts_interfaces/requests/inform.ts +++ /dev/null @@ -1,12 +0,0 @@ -import * as plugins from '../plugins.js'; - -export interface IRequest_InformAboutNewContainerImage extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_InformAboutNewContainerImage -> { - method: 'servezonestandard_InformAboutNewContainerVersion'; - request: { - containerImageInfo: plugins.tsclass.container.IContainer - }; - response: {}; -} \ No newline at end of file diff --git a/ts_interfaces/requests/log.ts b/ts_interfaces/requests/log.ts deleted file mode 100644 index 5c49e5a..0000000 --- a/ts_interfaces/requests/log.ts +++ /dev/null @@ -1,13 +0,0 @@ -import * as plugins from '../plugins.js'; - -export interface IRequest_Log extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_Log -> { - method: 'log'; - request: { - authToken: string; - logPackages: plugins.smartlogInterfaces.ILogPackage[]; - }, - response: {}; -} \ No newline at end of file diff --git a/ts_interfaces/requests/network.ts b/ts_interfaces/requests/network.ts deleted file mode 100644 index c5a54b1..0000000 --- a/ts_interfaces/requests/network.ts +++ /dev/null @@ -1,9 +0,0 @@ -import * as plugins from '../plugins.js'; - -export interface IRequest_Any_Cloudly_GetNetworkNodes { - method: 'getNetworkNodes'; - request: {}; - response: { - networkNodes: plugins.tsclass.network.INetworkNode[]; - }; -} diff --git a/ts_interfaces/requests/node.ts b/ts_interfaces/requests/node.ts deleted file mode 100644 index 4d727d6..0000000 --- a/ts_interfaces/requests/node.ts +++ /dev/null @@ -1,33 +0,0 @@ -import * as plugins from '../plugins.js'; -import type { IClusterNode } from '../data/clusternode.js'; -import type { IDeployment } from '../data/deployment.js'; - -export interface IRequest_Any_Cloudly_GetNodeConfig { - method: 'getNodeConfig'; - request: { - nodeId: string; - }; - response: { - configData: IClusterNode; - }; -} - -export interface IRequest_Any_Cloudly_GetNodesByCluster { - method: 'getNodesByCluster'; - request: { - clusterId: string; - }; - response: { - nodes: IClusterNode[]; - }; -} - -export interface IRequest_Any_Cloudly_GetNodeDeployments { - method: 'getNodeDeployments'; - request: { - nodeId: string; - }; - response: { - deployments: IDeployment[]; - }; -} \ No newline at end of file diff --git a/ts_interfaces/requests/routing.ts b/ts_interfaces/requests/routing.ts deleted file mode 100644 index caf6755..0000000 --- a/ts_interfaces/requests/routing.ts +++ /dev/null @@ -1,12 +0,0 @@ -import { type IReverseProxyConfig } from '../data/traffic.js'; - -export interface IRequest_Coreflow_Coretraffic_RoutingUpdate { - method: 'updateRouting'; - request: { - reverseConfigs: IReverseProxyConfig[]; - }; - response: { - status: 'ok' | 'error'; - errorText: string; - }; -} diff --git a/ts_interfaces/requests/secretbundle.ts b/ts_interfaces/requests/secretbundle.ts deleted file mode 100644 index c9c5f4c..0000000 --- a/ts_interfaces/requests/secretbundle.ts +++ /dev/null @@ -1,103 +0,0 @@ -import * as plugins from '../plugins.js'; -import * as data from '../data/index.js'; -import * as userInterfaces from '../data/user.js'; - -export interface IReq_GetSecretBundles extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IReq_GetSecretBundles -> { - method: 'getSecretBundles'; - request: { - identity: userInterfaces.IIdentity; - }; - response: { - secretBundles: data.ISecretBundle[]; - }; - -} - -export interface IReq_GetSecretBundleById extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IReq_GetSecretBundleById -> { - method: 'getSecretBundleById'; - request: { - identity: userInterfaces.IIdentity; - secretBundleId: string; - }; - response: { - secretBundle: data.ISecretBundle; - }; - -} - -export interface IReq_CreateSecretBundle extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IReq_CreateSecretBundle -> { - method: 'createSecretBundle'; - request: { - identity: userInterfaces.IIdentity; - secretBundle: data.ISecretBundle; - }; - response: { - resultSecretBundle: data.ISecretBundle; - }; -} - -export interface IReq_UpdateSecretBundle extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IReq_UpdateSecretBundle -> { - method: 'updateSecretBundle'; - request: { - identity: userInterfaces.IIdentity; - secretBundle: data.ISecretBundle; - }; - response: { - resultSecretBundle: data.ISecretBundle; - }; -} - -export interface IReq_DeleteSecretBundleById extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IReq_DeleteSecretBundleById -> { - method: 'deleteSecretBundleById'; - request: { - identity: userInterfaces.IIdentity; - secretBundleId: string; - }; - response: { - ok: boolean; - }; -} - -export interface IReq_GetSecretBundleByAuthorization extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IReq_GetSecretBundleByAuthorization -> { - method: 'getSecretBundleByAuthorization'; - request: { - identity: userInterfaces.IIdentity; - secretBundleAuthorization: data.ISecretBundleAuthorization; - }; - response: { - secretBundle: data.ISecretBundle; - }; -} - -export interface IReq_GetFlatKeyValueObject extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IReq_GetFlatKeyValueObject -> { - method: 'getFlatKeyValueObject'; - request: { - identity: userInterfaces.IIdentity; - seccretBundleId: string; - secretBundleAuthorization: data.ISecretBundleAuthorization; - }; - response: { - flatKeyValueObject: {[key: string]: string}; - }; -} diff --git a/ts_interfaces/requests/secretgroup.ts b/ts_interfaces/requests/secretgroup.ts deleted file mode 100644 index ddcac1e..0000000 --- a/ts_interfaces/requests/secretgroup.ts +++ /dev/null @@ -1,74 +0,0 @@ -import * as plugins from '../plugins.js'; -import * as data from '../data/index.js'; -import * as userInterfaces from '../data/user.js'; - -export interface IReq_GetSecretGroups extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IReq_GetSecretGroups -> { - method: 'getSecretGroups'; - request: { - identity: userInterfaces.IIdentity; - }; - response: { - secretGroups: data.ISecretGroup[]; - }; - -} - -export interface IReq_GetSecretGroupById extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IReq_GetSecretGroupById -> { - method: 'getSecretGroupById'; - request: { - identity: userInterfaces.IIdentity; - secretGroupId: string; - }; - response: { - secretGroup: data.ISecretGroup; - }; - -} - -export interface IReq_CreateSecretGroup extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IReq_CreateSecretGroup -> { - method: 'createSecretGroup'; - request: { - identity: userInterfaces.IIdentity; - secretGroup: data.ISecretGroup; - }; - response: { - resultSecretGroup: data.ISecretGroup; - }; -} - -export interface IReq_UpdateSecretGroup extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IReq_UpdateSecretGroup -> { - method: 'updateSecretGroup'; - request: { - identity: userInterfaces.IIdentity; - secretGroup: data.ISecretGroup; - }; - response: { - resultSecretGroup: data.ISecretGroup; - }; -} - -export interface IReq_DeleteSecretGroupById extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IReq_DeleteSecretGroupById -> { - method: 'deleteSecretGroupById'; - request: { - identity: userInterfaces.IIdentity; - secretGroupId: string; - }; - response: { - ok: boolean; - }; -} \ No newline at end of file diff --git a/ts_interfaces/requests/server.ts b/ts_interfaces/requests/server.ts deleted file mode 100644 index 02c42ac..0000000 --- a/ts_interfaces/requests/server.ts +++ /dev/null @@ -1,47 +0,0 @@ -import type { IServerMetrics } from '../data/server.js'; -import * as plugins from '../plugins.js'; - -/** - * This request can be used between any two players - * Examples: - * WebApp -> Cloudly (get metrics) - * Cloudly -> Webapp (send metrics) - * Cloudly -> Coreflow (get metrics) - * Coreflow -> Cloudly (send metrics) - */ -export interface IRequest_Any_Cloudly_ServerStatus -extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_Any_Cloudly_ServerStatus -> { - method: 'getOrSendServerMetrics', - request: { - getOrSend: 'get' | 'send'; - serverMetrics?: IServerMetrics; - }, - response: { - serverMetrics?: IServerMetrics; - }, -} - -/** - * this request can be used between any two players - * Examples: - * WebApp -> Cloudly - * Cloudly -> Coreflow - * Cloudly -> HostingProvider - */ -export interface IRequest_TriggerServerAction - extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_TriggerServerAction - > { - method: 'triggerServerAction'; - request: { - actionName: 'reboot' | 'rebuild'; - payload: any; - }; - response: { - actionConfirmed: boolean; - }; -} \ No newline at end of file diff --git a/ts_interfaces/requests/service.ts b/ts_interfaces/requests/service.ts deleted file mode 100644 index 80549f3..0000000 --- a/ts_interfaces/requests/service.ts +++ /dev/null @@ -1,95 +0,0 @@ -import * as plugins from '../plugins.js'; -import type { IService } from '../data/service.js'; -import type { IIdentity } from '../data/user.js'; -import type { IServiceRessources } from '../data/docker.js'; - -export interface IRequest_Any_Cloudly_GetServiceById -extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_Any_Cloudly_GetServiceById -> { - method: 'getServiceById'; - request: { - identity: IIdentity; - serviceId: string; - }; - response: { - service: IService; - }; -} - -export interface IRequest_Any_Cloudly_GetServices -extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_Any_Cloudly_GetServices -> { - method: 'getServices'; - request: { - identity: IIdentity; - }; - response: { - services: IService[]; - }; -} - -export interface IRequest_Any_Cloudly_CreateService -extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_Any_Cloudly_CreateService -> { - method: 'createService'; - request: { - identity: IIdentity; - serviceData: IService['data']; - }; - response: { - service: IService; - }; -} - -export interface IRequest_Any_Cloudly_UpdateService -extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_Any_Cloudly_UpdateService -> { - method: 'updateService'; - request: { - identity: IIdentity; - serviceId: string; - serviceData: IService['data']; - }; - response: { - service: IService; - }; -} - -export interface IRequest_Any_Cloudly_DeleteServiceById -extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_Any_Cloudly_DeleteServiceById -> { - method: 'deleteServiceById'; - request: { - identity: IIdentity; - serviceId: string; - }; - response: { - success: boolean; - }; -} - -export interface IRequest_Any_Cloudly_GetServiceSecretBundlesAsFlatObject -extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_Any_Cloudly_GetServiceSecretBundlesAsFlatObject -> { - method: 'getServiceSecretBundlesAsFlatObject'; - request: { - identity: IIdentity; - serviceId: string; - environment: string; - }; - response: { - flatKeyValueObject: {[key: string]: string}; - }; -} diff --git a/ts_interfaces/requests/settings.ts b/ts_interfaces/requests/settings.ts deleted file mode 100644 index b7c3393..0000000 --- a/ts_interfaces/requests/settings.ts +++ /dev/null @@ -1,59 +0,0 @@ -import * as plugins from '../plugins.js'; -import type { ICloudlySettings, ICloudlySettingsMasked } from '../data/settings.js'; - -// Get Settings -export interface IRequest_GetSettings extends plugins.typedrequestInterfaces.ITypedRequest { - method: 'getSettings'; - request: {}; - response: { - settings: ICloudlySettingsMasked; - }; -} - -// Update Settings -export interface IRequest_UpdateSettings extends plugins.typedrequestInterfaces.ITypedRequest { - method: 'updateSettings'; - request: { - updates: Partial; - }; - response: { - success: boolean; - message: string; - }; -} - -// Clear Specific Setting -export interface IRequest_ClearSetting extends plugins.typedrequestInterfaces.ITypedRequest { - method: 'clearSetting'; - request: { - key: keyof ICloudlySettings; - }; - response: { - success: boolean; - message: string; - }; -} - -// Test Provider Connection -export interface IRequest_TestProviderConnection extends plugins.typedrequestInterfaces.ITypedRequest { - method: 'testProviderConnection'; - request: { - provider: 'hetzner' | 'cloudflare' | 'aws' | 'digitalocean' | 'azure' | 'google' | 'vultr' | 'linode' | 'ovh' | 'scaleway'; - }; - response: { - success: boolean; - message: string; - connectionValid: boolean; - }; -} - -// Get Single Setting (for internal use, not exposed to frontend) -export interface IRequest_GetSetting extends plugins.typedrequestInterfaces.ITypedRequest { - method: 'getSetting'; - request: { - key: keyof ICloudlySettings; - }; - response: { - value: string | undefined; - }; -} \ No newline at end of file diff --git a/ts_interfaces/requests/status.ts b/ts_interfaces/requests/status.ts deleted file mode 100644 index ac45a5f..0000000 --- a/ts_interfaces/requests/status.ts +++ /dev/null @@ -1,12 +0,0 @@ -import * as userInterfaces from '../data/user.js'; - -/** - * a status update dashboard - */ -export interface IRequest_Coreflow_Cloudly_CoreflowManagerStatusupdate { - method: 'cloudlyStatus'; - request: { - identity: userInterfaces.IIdentity; - }; - response: {}; -} diff --git a/ts_interfaces/requests/task.ts b/ts_interfaces/requests/task.ts deleted file mode 100644 index 7d4c4c6..0000000 --- a/ts_interfaces/requests/task.ts +++ /dev/null @@ -1,95 +0,0 @@ -import * as plugins from '../plugins.js'; -import * as data from '../data/index.js'; -import * as userInterfaces from '../data/user.js'; - -// Get all tasks -export interface IRequest_Any_Cloudly_GetTasks - extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_Any_Cloudly_GetTasks - > { - method: 'getTasks'; - request: { - identity: userInterfaces.IIdentity; - }; - response: { - tasks: Array<{ - name: string; - description: string; - category: 'maintenance' | 'deployment' | 'backup' | 'monitoring' | 'cleanup' | 'system' | 'security'; - schedule?: string; - lastRun?: number; - enabled: boolean; - }>; - }; -} - -// Get task executions -export interface IRequest_Any_Cloudly_GetTaskExecutions - extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_Any_Cloudly_GetTaskExecutions - > { - method: 'getTaskExecutions'; - request: { - identity: userInterfaces.IIdentity; - filter?: { - taskName?: string; - status?: string; - startedAfter?: number; - startedBefore?: number; - }; - }; - response: { - executions: data.ITaskExecution[]; - }; -} - -// Get task execution by ID -export interface IRequest_Any_Cloudly_GetTaskExecutionById - extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_Any_Cloudly_GetTaskExecutionById - > { - method: 'getTaskExecutionById'; - request: { - identity: userInterfaces.IIdentity; - executionId: string; - }; - response: { - execution: data.ITaskExecution; - }; -} - -// Trigger task manually -export interface IRequest_Any_Cloudly_TriggerTask - extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_Any_Cloudly_TriggerTask - > { - method: 'triggerTask'; - request: { - identity: userInterfaces.IIdentity; - taskName: string; - userId?: string; - }; - response: { - execution: data.ITaskExecution; - }; -} - -// Cancel a running task -export interface IRequest_Any_Cloudly_CancelTask - extends plugins.typedrequestInterfaces.implementsTR< - plugins.typedrequestInterfaces.ITypedRequest, - IRequest_Any_Cloudly_CancelTask - > { - method: 'cancelTask'; - request: { - identity: userInterfaces.IIdentity; - executionId: string; - }; - response: { - success: boolean; - }; -} \ No newline at end of file diff --git a/ts_interfaces/requests/version.ts b/ts_interfaces/requests/version.ts deleted file mode 100644 index e2e66eb..0000000 --- a/ts_interfaces/requests/version.ts +++ /dev/null @@ -1,8 +0,0 @@ -import * as versionInterfaces from '../data/version.js'; - -// Containers -export interface IRequest_Any_Cloudly_VersionManager_InformCloudlyAboutNewContainerVersion { - method: 'informCloudlyAboutNewContainerVersion'; - request: versionInterfaces.IContainerVersionData; - response: {}; -} diff --git a/ts_interfaces/tspublish.json b/ts_interfaces/tspublish.json deleted file mode 100644 index 7a81088..0000000 --- a/ts_interfaces/tspublish.json +++ /dev/null @@ -1,13 +0,0 @@ -{ - "order": 0, - "name": "@serve.zone/interfaces", - "dependencies": [ - "@api.global/typedrequest-interfaces", - "@push.rocks/smartlog-interfaces", - "@tsclass/tsclass" - ], - "registries": [ - "registry.npmjs.org:public", - "verdaccio.lossless.digital:public" - ] -} \ No newline at end of file diff --git a/ts_web/elements/views/backups/index.ts b/ts_web/elements/views/backups/index.ts index fed5293..ee1fd8f 100644 --- a/ts_web/elements/views/backups/index.ts +++ b/ts_web/elements/views/backups/index.ts @@ -25,7 +25,7 @@ export class CloudlyViewBackups extends DeesElement { .heading1=${'Backups'} .heading2=${'decoded in client'} .data=${this.data.backups} - .displayFunction=${(itemArg: plugins.interfaces.data.ICluster) => { return { id: itemArg.id, serverAmount: itemArg.data.servers.length }; }} + .displayFunction=${(itemArg: plugins.interfaces.data.ICluster) => { return { id: itemArg.id, serverAmount: itemArg.data.nodes.length }; }} .dataActions=${[ { name: 'add configBundle', iconName: 'plus', type: ['header', 'footer'], actionFunc: async () => { await plugins.deesCatalog.DeesModal.createAndShow({ heading: 'Add ConfigBundle', content: html` @@ -49,4 +49,3 @@ export class CloudlyViewBackups extends DeesElement { } declare global { interface HTMLElementTagNameMap { 'cloudly-view-backups': CloudlyViewBackups; } } - diff --git a/ts_web/elements/views/clusters/index.ts b/ts_web/elements/views/clusters/index.ts index 0d82566..e0e1314 100644 --- a/ts_web/elements/views/clusters/index.ts +++ b/ts_web/elements/views/clusters/index.ts @@ -43,7 +43,7 @@ export class CloudlyViewClusters extends DeesElement { .displayFunction=${(itemArg: plugins.interfaces.data.ICluster) => { return { id: itemArg.id, - serverAmount: itemArg.data.servers.length, + serverAmount: itemArg.data.nodes.length, }; }} .dataActions=${[ @@ -108,4 +108,3 @@ declare global { 'cloudly-view-clusters': CloudlyViewClusters; } } - diff --git a/ts_web/elements/views/dbs/index.ts b/ts_web/elements/views/dbs/index.ts index 04708a6..564f17e 100644 --- a/ts_web/elements/views/dbs/index.ts +++ b/ts_web/elements/views/dbs/index.ts @@ -25,7 +25,7 @@ export class CloudlyViewDbs extends DeesElement { .heading1=${'DBs'} .heading2=${'decoded in client'} .data=${this.data.dbs} - .displayFunction=${(itemArg: plugins.interfaces.data.ICluster) => { return { id: itemArg.id, serverAmount: itemArg.data.servers.length }; }} + .displayFunction=${(itemArg: plugins.interfaces.data.ICluster) => { return { id: itemArg.id, serverAmount: itemArg.data.nodes.length }; }} .dataActions=${[ { name: 'add configBundle', iconName: 'plus', type: ['header', 'footer'], actionFunc: async () => { await plugins.deesCatalog.DeesModal.createAndShow({ heading: 'Add ConfigBundle', content: html` @@ -49,4 +49,3 @@ export class CloudlyViewDbs extends DeesElement { } declare global { interface HTMLElementTagNameMap { 'cloudly-view-dbs': CloudlyViewDbs; } } - diff --git a/ts_web/elements/views/domains/index.ts b/ts_web/elements/views/domains/index.ts index 64929b8..e3fc904 100644 --- a/ts_web/elements/views/domains/index.ts +++ b/ts_web/elements/views/domains/index.ts @@ -128,7 +128,7 @@ export class CloudlyViewDomains extends DeesElement { const form = modalArg.shadowRoot.querySelector('dees-form') as any; const formData = await form.gatherData(); const tags = formData.tags ? formData.tags.split(',').map((tag: string) => tag.trim()).filter((tag: string) => tag) : []; - await appstate.dataState.dispatchAction(appstate.updateDomainAction, { domainId: domain.id, updates: { name: formData.name, description: formData.description || undefined, status: formData.status, autoRenew: formData.autoRenew, dnssecEnabled: formData.dnssecEnabled, tags }, }); + await appstate.dataState.dispatchAction(appstate.updateDomainAction, { domainId: domain.id, domainData: { ...domain.data, name: formData.name, description: formData.description || undefined, status: formData.status, autoRenew: formData.autoRenew, dnssecEnabled: formData.dnssecEnabled, tags }, }); await modalArg.destroy(); }}, { name: 'Cancel', action: async (modalArg: any) => modalArg.destroy() }, diff --git a/ts_web/elements/views/logs/index.ts b/ts_web/elements/views/logs/index.ts index 4c661c8..5cdc0f3 100644 --- a/ts_web/elements/views/logs/index.ts +++ b/ts_web/elements/views/logs/index.ts @@ -33,7 +33,7 @@ export class CloudlyViewLogs extends DeesElement { .heading2=${'decoded in client'} .data=${this.data.deployments} .displayFunction=${(itemArg: plugins.interfaces.data.ICluster) => { - return { id: itemArg.id, serverAmount: itemArg.data.servers.length }; + return { id: itemArg.id, serverAmount: itemArg.data.nodes.length }; }} .dataActions=${[ { name: 'add configBundle', iconName: 'plus', type: ['header', 'footer'], actionFunc: async () => { @@ -58,4 +58,3 @@ export class CloudlyViewLogs extends DeesElement { } declare global { interface HTMLElementTagNameMap { 'cloudly-view-logs': CloudlyViewLogs; } } - diff --git a/ts_web/elements/views/mails/index.ts b/ts_web/elements/views/mails/index.ts index a6a0af3..39ae614 100644 --- a/ts_web/elements/views/mails/index.ts +++ b/ts_web/elements/views/mails/index.ts @@ -33,7 +33,7 @@ export class CloudlyViewMails extends DeesElement { .heading2=${'decoded in client'} .data=${this.data.deployments} .displayFunction=${(itemArg: plugins.interfaces.data.ICluster) => { - return { id: itemArg.id, serverAmount: itemArg.data.servers.length }; + return { id: itemArg.id, serverAmount: itemArg.data.nodes.length }; }} .dataActions=${[ { name: 'add configBundle', iconName: 'plus', type: ['header', 'footer'], actionFunc: async () => { @@ -58,4 +58,3 @@ export class CloudlyViewMails extends DeesElement { } declare global { interface HTMLElementTagNameMap { 'cloudly-view-mails': CloudlyViewMails; } } - diff --git a/ts_web/elements/views/s3/index.ts b/ts_web/elements/views/s3/index.ts index 59d2a3b..8067966 100644 --- a/ts_web/elements/views/s3/index.ts +++ b/ts_web/elements/views/s3/index.ts @@ -25,7 +25,7 @@ export class CloudlyViewS3 extends DeesElement { .heading1=${'S3'} .heading2=${'decoded in client'} .data=${this.data.s3} - .displayFunction=${(itemArg: plugins.interfaces.data.ICluster) => { return { id: itemArg.id, serverAmount: itemArg.data.servers.length }; }} + .displayFunction=${(itemArg: plugins.interfaces.data.ICluster) => { return { id: itemArg.id, serverAmount: itemArg.data.nodes.length }; }} .dataActions=${[ { name: 'add configBundle', iconName: 'plus', type: ['header', 'footer'], actionFunc: async () => { await plugins.deesCatalog.DeesModal.createAndShow({ heading: 'Add ConfigBundle', content: html` @@ -49,4 +49,3 @@ export class CloudlyViewS3 extends DeesElement { } declare global { interface HTMLElementTagNameMap { 'cloudly-view-s3': CloudlyViewS3; } } - diff --git a/ts_web/elements/views/services/index.ts b/ts_web/elements/views/services/index.ts index 338beab..3cbd2c8 100644 --- a/ts_web/elements/views/services/index.ts +++ b/ts_web/elements/views/services/index.ts @@ -117,6 +117,7 @@ export class CloudlyViewServices extends DeesElement { antiAffinity: formData.antiAffinity, imageId: formData.imageId, imageVersion: formData.imageVersion, + secretBundleId: '', scaleFactor: parseInt(formData.scaleFactor), balancingStrategy: formData.balancingStrategy, ports: { web: parseInt(formData.webPort) }, @@ -222,4 +223,3 @@ declare global { 'cloudly-view-services': CloudlyViewServices; } } - diff --git a/tsconfig.json b/tsconfig.json index 3e5d170..db5bd0d 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -14,13 +14,10 @@ ], "@serve.zone/cli": [ "./ts_cliclient/index.js" - ], - "@serve.zone/interfaces": [ - "./ts_interfaces/index.js" ] } }, "exclude": [ "dist_*/**/*.d.ts" ] -} \ No newline at end of file +}