@zlayer/api-client 0.10.86 → 0.10.88
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.openapi-generator/FILES +58 -1
- package/README.md +48 -6
- package/dist/apis/AuthenticationApi.d.ts +43 -1
- package/dist/apis/AuthenticationApi.js +112 -0
- package/dist/apis/ContainerNetworksApi.d.ts +123 -0
- package/dist/apis/ContainerNetworksApi.js +331 -0
- package/dist/apis/ContainersApi.d.ts +7 -4
- package/dist/apis/ContainersApi.js +13 -4
- package/dist/apis/EventsApi.d.ts +35 -0
- package/dist/apis/EventsApi.js +81 -0
- package/dist/apis/PermissionsApi.d.ts +18 -0
- package/dist/apis/PermissionsApi.js +46 -0
- package/dist/apis/SecretsApi.d.ts +38 -1
- package/dist/apis/SecretsApi.js +109 -0
- package/dist/apis/VolumesApi.d.ts +41 -7
- package/dist/apis/VolumesApi.js +102 -5
- package/dist/apis/index.d.ts +2 -0
- package/dist/apis/index.js +2 -0
- package/dist/models/BridgeNetwork.d.ts +72 -0
- package/dist/models/BridgeNetwork.js +67 -0
- package/dist/models/BridgeNetworkAttachment.d.ts +50 -0
- package/dist/models/BridgeNetworkAttachment.js +56 -0
- package/dist/models/BridgeNetworkDetails.d.ts +79 -0
- package/dist/models/BridgeNetworkDetails.js +72 -0
- package/dist/models/BridgeNetworkDriver.d.ts +25 -0
- package/dist/models/BridgeNetworkDriver.js +51 -0
- package/dist/models/ConnectBridgeNetworkRequest.d.ts +45 -0
- package/dist/models/ConnectBridgeNetworkRequest.js +54 -0
- package/dist/models/ContainerEvent.d.ts +82 -0
- package/dist/models/ContainerEvent.js +67 -0
- package/dist/models/ContainerEventKind.d.ts +27 -0
- package/dist/models/ContainerEventKind.js +53 -0
- package/dist/models/ContainerHealthInfo.d.ts +53 -0
- package/dist/models/ContainerHealthInfo.js +54 -0
- package/dist/models/ContainerInfo.d.ts +40 -0
- package/dist/models/ContainerInfo.js +13 -0
- package/dist/models/ContainerRestartKind.d.ts +27 -0
- package/dist/models/ContainerRestartKind.js +53 -0
- package/dist/models/ContainerRestartPolicy.d.ts +53 -0
- package/dist/models/ContainerRestartPolicy.js +55 -0
- package/dist/models/ContainerWaitResponse.d.ts +30 -2
- package/dist/models/ContainerWaitResponse.js +6 -0
- package/dist/models/CreateBridgeNetworkRequest.d.ts +60 -0
- package/dist/models/CreateBridgeNetworkRequest.js +59 -0
- package/dist/models/CreateContainerRequest.d.ts +77 -0
- package/dist/models/CreateContainerRequest.js +23 -0
- package/dist/models/CreateVolumeRequest.d.ts +54 -0
- package/dist/models/CreateVolumeRequest.js +56 -0
- package/dist/models/DisconnectBridgeNetworkRequest.d.ts +38 -0
- package/dist/models/DisconnectBridgeNetworkRequest.js +52 -0
- package/dist/models/HealthCheckRequest.d.ts +94 -0
- package/dist/models/HealthCheckRequest.js +66 -0
- package/dist/models/NetworkAttachmentInfo.d.ts +49 -0
- package/dist/models/NetworkAttachmentInfo.js +54 -0
- package/dist/models/NetworkAttachmentRequest.d.ts +51 -0
- package/dist/models/NetworkAttachmentRequest.js +54 -0
- package/dist/models/OidcCallbackResponse.d.ts +47 -0
- package/dist/models/OidcCallbackResponse.js +59 -0
- package/dist/models/OidcProviderPublic.d.ts +39 -0
- package/dist/models/OidcProviderPublic.js +54 -0
- package/dist/models/PortMapping.d.ts +55 -0
- package/dist/models/PortMapping.js +57 -0
- package/dist/models/PortProtocol.d.ts +25 -0
- package/dist/models/PortProtocol.js +51 -0
- package/dist/models/PullImageRequest.d.ts +18 -0
- package/dist/models/PullImageRequest.js +5 -0
- package/dist/models/RegistryAuth.d.ts +52 -0
- package/dist/models/RegistryAuth.js +57 -0
- package/dist/models/RegistryAuthType.d.ts +25 -0
- package/dist/models/RegistryAuthType.js +51 -0
- package/dist/models/RevealAllSecretsResponse.d.ts +41 -0
- package/dist/models/RevealAllSecretsResponse.js +54 -0
- package/dist/models/RotateSecretRequest.d.ts +32 -0
- package/dist/models/RotateSecretRequest.js +50 -0
- package/dist/models/RotateSecretResponse.d.ts +46 -0
- package/dist/models/RotateSecretResponse.js +56 -0
- package/dist/models/VolumeInfo.d.ts +70 -0
- package/dist/models/VolumeInfo.js +64 -0
- package/dist/models/VolumeMount.d.ts +16 -3
- package/dist/models/VolumeMount.js +4 -3
- package/dist/models/VolumeMountType.d.ts +30 -0
- package/dist/models/VolumeMountType.js +56 -0
- package/dist/models/VolumeSummary.d.ts +7 -4
- package/dist/models/index.d.ts +27 -0
- package/dist/models/index.js +27 -0
- package/docs/AddMemberRequest.md +1 -1
- package/docs/AuditApi.md +3 -3
- package/docs/AuditEntry.md +1 -1
- package/docs/AuthenticationApi.md +212 -18
- package/docs/BackendGroupInfo.md +1 -1
- package/docs/BackendInfo.md +1 -1
- package/docs/BackendsResponse.md +1 -1
- package/docs/BootstrapRequest.md +1 -1
- package/docs/BridgeNetwork.md +47 -0
- package/docs/BridgeNetworkAttachment.md +41 -0
- package/docs/BridgeNetworkDetails.md +49 -0
- package/docs/BridgeNetworkDriver.md +33 -0
- package/docs/BuildApi.md +21 -21
- package/docs/BuildKind.md +1 -1
- package/docs/BuildRequest.md +1 -1
- package/docs/BuildRequestWithContext.md +1 -1
- package/docs/BuildStateEnum.md +1 -1
- package/docs/BuildStatus.md +1 -1
- package/docs/BulkImportResponse.md +1 -1
- package/docs/CertInfo.md +1 -1
- package/docs/ClusterApi.md +12 -12
- package/docs/ClusterJoinRequest.md +1 -1
- package/docs/ClusterJoinResponse.md +1 -1
- package/docs/ClusterNodeSummary.md +1 -1
- package/docs/ClusterPeer.md +1 -1
- package/docs/ConnectBridgeNetworkRequest.md +39 -0
- package/docs/ContainerEvent.md +47 -0
- package/docs/ContainerEventKind.md +33 -0
- package/docs/ContainerExecRequest.md +1 -1
- package/docs/ContainerExecResponse.md +1 -1
- package/docs/ContainerHealthInfo.md +39 -0
- package/docs/ContainerInfo.md +11 -1
- package/docs/ContainerNetworksApi.md +466 -0
- package/docs/ContainerResourceLimits.md +1 -1
- package/docs/ContainerRestartKind.md +33 -0
- package/docs/ContainerRestartPolicy.md +39 -0
- package/docs/ContainerStatsResponse.md +1 -1
- package/docs/ContainerWaitResponse.md +8 -2
- package/docs/ContainersApi.md +51 -42
- package/docs/CreateBridgeNetworkRequest.md +43 -0
- package/docs/CreateContainerRequest.md +19 -1
- package/docs/CreateDeploymentRequest.md +1 -1
- package/docs/CreateEnvironmentRequest.md +1 -1
- package/docs/CreateGitCredentialRequest.md +1 -1
- package/docs/CreateGroupRequest.md +1 -1
- package/docs/CreateNodeTunnelRequest.md +1 -1
- package/docs/CreateNodeTunnelResponse.md +1 -1
- package/docs/CreateNotifierRequest.md +1 -1
- package/docs/CreateProjectRequest.md +1 -1
- package/docs/CreateRegistryCredentialRequest.md +1 -1
- package/docs/CreateSecretRequest.md +1 -1
- package/docs/CreateSyncRequest.md +1 -1
- package/docs/CreateTaskRequest.md +1 -1
- package/docs/CreateTunnelRequest.md +1 -1
- package/docs/CreateTunnelResponse.md +1 -1
- package/docs/CreateUserRequest.md +1 -1
- package/docs/CreateVariableRequest.md +1 -1
- package/docs/CreateVolumeRequest.md +41 -0
- package/docs/CreateWorkflowRequest.md +1 -1
- package/docs/CredentialsApi.md +18 -18
- package/docs/CronApi.md +15 -15
- package/docs/CronJobResponse.md +1 -1
- package/docs/CronStatusResponse.md +1 -1
- package/docs/CsrfResponse.md +1 -1
- package/docs/DeploymentDetails.md +1 -1
- package/docs/DeploymentSummary.md +1 -1
- package/docs/DeploymentsApi.md +12 -12
- package/docs/DisconnectBridgeNetworkRequest.md +37 -0
- package/docs/DnsStatusResponse.md +1 -1
- package/docs/EnvironmentsApi.md +15 -15
- package/docs/EventsApi.md +85 -0
- package/docs/ForceLeaderRequest.md +1 -1
- package/docs/ForceLeaderResponse.md +1 -1
- package/docs/GitCredentialKindSchema.md +1 -1
- package/docs/GitCredentialResponse.md +1 -1
- package/docs/GpuInfoSummary.md +1 -1
- package/docs/GpuUtilizationReport.md +1 -1
- package/docs/GrantPermissionRequest.md +1 -1
- package/docs/GroupMembersResponse.md +1 -1
- package/docs/GroupsApi.md +21 -21
- package/docs/HealthApi.md +6 -6
- package/docs/HealthCheckRequest.md +51 -0
- package/docs/HealthResponse.md +1 -1
- package/docs/HeartbeatRequest.md +1 -1
- package/docs/ImageInfoDto.md +1 -1
- package/docs/ImagesApi.md +15 -15
- package/docs/InternalApi.md +6 -6
- package/docs/InternalScaleRequest.md +1 -1
- package/docs/InternalScaleResponse.md +1 -1
- package/docs/IpAllocationResponse.md +1 -1
- package/docs/JobExecutionResponse.md +1 -1
- package/docs/JobsApi.md +12 -12
- package/docs/JoinTokenResponse.md +1 -1
- package/docs/KillContainerRequest.md +1 -1
- package/docs/LinkDeploymentRequest.md +1 -1
- package/docs/LoginRequest.md +1 -1
- package/docs/LoginResponse.md +1 -1
- package/docs/NetworkAttachmentInfo.md +39 -0
- package/docs/NetworkAttachmentRequest.md +39 -0
- package/docs/NetworkSummary.md +1 -1
- package/docs/NetworksApi.md +15 -15
- package/docs/NodeDetails.md +1 -1
- package/docs/NodeResourceInfo.md +1 -1
- package/docs/NodeSummary.md +1 -1
- package/docs/NodesApi.md +12 -12
- package/docs/NotifierConfig.md +1 -1
- package/docs/NotifierConfigOneOf.md +1 -1
- package/docs/NotifierConfigOneOf1.md +1 -1
- package/docs/NotifierConfigOneOf2.md +1 -1
- package/docs/NotifierConfigOneOf3.md +1 -1
- package/docs/NotifierKind.md +1 -1
- package/docs/NotifiersApi.md +18 -18
- package/docs/OidcCallbackResponse.md +39 -0
- package/docs/OidcProviderPublic.md +37 -0
- package/docs/OverlayApi.md +12 -12
- package/docs/OverlayStatusResponse.md +1 -1
- package/docs/PeerInfo.md +1 -1
- package/docs/PeerListResponse.md +1 -1
- package/docs/PermissionLevel.md +1 -1
- package/docs/PermissionsApi.md +80 -9
- package/docs/PortMapping.md +41 -0
- package/docs/PortProtocol.md +33 -0
- package/docs/ProjectPullResponse.md +1 -1
- package/docs/ProjectsApi.md +27 -27
- package/docs/ProxyApi.md +12 -12
- package/docs/PruneResultDto.md +1 -1
- package/docs/PullImageRequest.md +5 -1
- package/docs/PullImageResponse.md +1 -1
- package/docs/RegisteredServiceInfo.md +1 -1
- package/docs/RegistryAuth.md +39 -0
- package/docs/RegistryAuthType.md +33 -0
- package/docs/RegistryAuthTypeSchema.md +1 -1
- package/docs/RegistryCredentialResponse.md +1 -1
- package/docs/ReplicationInfo.md +1 -1
- package/docs/RestartContainerRequest.md +1 -1
- package/docs/RevealAllSecretsResponse.md +37 -0
- package/docs/RotateSecretRequest.md +35 -0
- package/docs/RotateSecretResponse.md +39 -0
- package/docs/RouteInfo.md +1 -1
- package/docs/RoutesResponse.md +1 -1
- package/docs/ScaleRequest.md +1 -1
- package/docs/SecretMetadataResponse.md +1 -1
- package/docs/SecretsApi.md +175 -15
- package/docs/ServiceDetails.md +1 -1
- package/docs/ServiceEndpoint.md +1 -1
- package/docs/ServiceHealthInfo.md +1 -1
- package/docs/ServiceMetrics.md +1 -1
- package/docs/ServiceSummary.md +1 -1
- package/docs/ServicesApi.md +12 -12
- package/docs/SetPasswordRequest.md +1 -1
- package/docs/StepResult.md +1 -1
- package/docs/StopContainerRequest.md +1 -1
- package/docs/StorageApi.md +3 -3
- package/docs/StorageStatusResponse.md +1 -1
- package/docs/StoredEnvironment.md +1 -1
- package/docs/StoredNotifier.md +1 -1
- package/docs/StoredPermission.md +1 -1
- package/docs/StoredProject.md +1 -1
- package/docs/StoredSync.md +1 -1
- package/docs/StoredTask.md +1 -1
- package/docs/StoredUserGroup.md +1 -1
- package/docs/StoredVariable.md +1 -1
- package/docs/StoredWorkflow.md +1 -1
- package/docs/StreamBackendInfo.md +1 -1
- package/docs/StreamInfo.md +1 -1
- package/docs/StreamsResponse.md +1 -1
- package/docs/SubjectKind.md +1 -1
- package/docs/SuccessResponse.md +1 -1
- package/docs/SyncApplyResponse.md +1 -1
- package/docs/SyncDiffResponse.md +1 -1
- package/docs/SyncResourceResponse.md +1 -1
- package/docs/SyncResourceResult.md +1 -1
- package/docs/SyncsApi.md +15 -15
- package/docs/TagImageRequest.md +1 -1
- package/docs/TaskKind.md +1 -1
- package/docs/TaskRun.md +1 -1
- package/docs/TasksApi.md +18 -18
- package/docs/TemplateInfo.md +1 -1
- package/docs/TestNotifierResponse.md +1 -1
- package/docs/TlsResponse.md +1 -1
- package/docs/TokenRequest.md +1 -1
- package/docs/TokenResponse.md +1 -1
- package/docs/TriggerBuildResponse.md +1 -1
- package/docs/TriggerCronResponse.md +1 -1
- package/docs/TriggerJobResponse.md +1 -1
- package/docs/TunnelStatus.md +1 -1
- package/docs/TunnelSummary.md +1 -1
- package/docs/TunnelsApi.md +18 -18
- package/docs/UpdateEnvironmentRequest.md +1 -1
- package/docs/UpdateGroupRequest.md +1 -1
- package/docs/UpdateLabelsRequest.md +1 -1
- package/docs/UpdateLabelsResponse.md +1 -1
- package/docs/UpdateNotifierRequest.md +1 -1
- package/docs/UpdateProjectRequest.md +1 -1
- package/docs/UpdateUserRequest.md +1 -1
- package/docs/UpdateVariableRequest.md +1 -1
- package/docs/UserRole.md +1 -1
- package/docs/UserView.md +1 -1
- package/docs/UsersApi.md +18 -18
- package/docs/VariablesApi.md +15 -15
- package/docs/VolumeInfo.md +45 -0
- package/docs/VolumeMount.md +4 -2
- package/docs/VolumeMountType.md +33 -0
- package/docs/VolumeSummary.md +2 -2
- package/docs/VolumesApi.md +163 -13
- package/docs/WebhookInfoResponse.md +1 -1
- package/docs/WebhookResponse.md +1 -1
- package/docs/WebhooksApi.md +9 -9
- package/docs/WorkflowAction.md +1 -1
- package/docs/WorkflowActionOneOf.md +1 -1
- package/docs/WorkflowActionOneOf1.md +1 -1
- package/docs/WorkflowActionOneOf2.md +1 -1
- package/docs/WorkflowActionOneOf3.md +1 -1
- package/docs/WorkflowRun.md +1 -1
- package/docs/WorkflowRunStatus.md +1 -1
- package/docs/WorkflowStep.md +1 -1
- package/docs/WorkflowsApi.md +18 -18
- package/package.json +1 -1
- package/src/apis/AuthenticationApi.ts +140 -0
- package/src/apis/ContainerNetworksApi.ts +418 -0
- package/src/apis/ContainersApi.ts +19 -4
- package/src/apis/EventsApi.ts +82 -0
- package/src/apis/PermissionsApi.ts +59 -0
- package/src/apis/SecretsApi.ts +151 -0
- package/src/apis/VolumesApi.ts +133 -10
- package/src/apis/index.ts +2 -0
- package/src/models/BridgeNetwork.ts +127 -0
- package/src/models/BridgeNetworkAttachment.ts +90 -0
- package/src/models/BridgeNetworkDetails.ts +143 -0
- package/src/models/BridgeNetworkDriver.ts +53 -0
- package/src/models/ConnectBridgeNetworkRequest.ts +83 -0
- package/src/models/ContainerEvent.ts +137 -0
- package/src/models/ContainerEventKind.ts +55 -0
- package/src/models/ContainerHealthInfo.ts +91 -0
- package/src/models/ContainerInfo.ts +69 -0
- package/src/models/ContainerRestartKind.ts +55 -0
- package/src/models/ContainerRestartPolicy.ts +100 -0
- package/src/models/ContainerWaitResponse.ts +36 -2
- package/src/models/CreateBridgeNetworkRequest.ts +109 -0
- package/src/models/CreateContainerRequest.ts +125 -0
- package/src/models/CreateVolumeRequest.ts +92 -0
- package/src/models/DisconnectBridgeNetworkRequest.ts +74 -0
- package/src/models/HealthCheckRequest.ts +144 -0
- package/src/models/NetworkAttachmentInfo.ts +87 -0
- package/src/models/NetworkAttachmentRequest.ts +89 -0
- package/src/models/OidcCallbackResponse.ts +94 -0
- package/src/models/OidcProviderPublic.ts +76 -0
- package/src/models/PortMapping.ts +104 -0
- package/src/models/PortProtocol.ts +53 -0
- package/src/models/PullImageRequest.ts +29 -0
- package/src/models/RegistryAuth.ts +100 -0
- package/src/models/RegistryAuthType.ts +53 -0
- package/src/models/RevealAllSecretsResponse.ts +76 -0
- package/src/models/RotateSecretRequest.ts +66 -0
- package/src/models/RotateSecretResponse.ts +85 -0
- package/src/models/VolumeInfo.ts +114 -0
- package/src/models/VolumeMount.ts +28 -5
- package/src/models/VolumeMountType.ts +58 -0
- package/src/models/VolumeSummary.ts +7 -4
- package/src/models/index.ts +27 -0
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* ZLayer API
|
|
3
|
+
* Container orchestration API for ZLayer
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 0.1.0
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
import type { BridgeNetworkDriver } from './BridgeNetworkDriver';
|
|
13
|
+
/**
|
|
14
|
+
* Body for `POST /api/v1/container-networks`.
|
|
15
|
+
* @export
|
|
16
|
+
* @interface CreateBridgeNetworkRequest
|
|
17
|
+
*/
|
|
18
|
+
export interface CreateBridgeNetworkRequest {
|
|
19
|
+
/**
|
|
20
|
+
* Driver, defaults to `bridge`.
|
|
21
|
+
* @type {BridgeNetworkDriver}
|
|
22
|
+
* @memberof CreateBridgeNetworkRequest
|
|
23
|
+
*/
|
|
24
|
+
driver?: BridgeNetworkDriver | null;
|
|
25
|
+
/**
|
|
26
|
+
* Internal-only (no egress) network.
|
|
27
|
+
* @type {boolean}
|
|
28
|
+
* @memberof CreateBridgeNetworkRequest
|
|
29
|
+
*/
|
|
30
|
+
internal?: boolean;
|
|
31
|
+
/**
|
|
32
|
+
* Arbitrary labels.
|
|
33
|
+
* @type {{ [key: string]: string; }}
|
|
34
|
+
* @memberof CreateBridgeNetworkRequest
|
|
35
|
+
*/
|
|
36
|
+
labels?: {
|
|
37
|
+
[key: string]: string;
|
|
38
|
+
};
|
|
39
|
+
/**
|
|
40
|
+
* Network name (must match `^[a-z0-9][a-z0-9_-]{0,63}$`).
|
|
41
|
+
* @type {string}
|
|
42
|
+
* @memberof CreateBridgeNetworkRequest
|
|
43
|
+
*/
|
|
44
|
+
name: string;
|
|
45
|
+
/**
|
|
46
|
+
* Subnet CIDR (e.g. `"10.240.0.0/24"`). Validated as
|
|
47
|
+
* [`ipnetwork::IpNetwork`].
|
|
48
|
+
* @type {string}
|
|
49
|
+
* @memberof CreateBridgeNetworkRequest
|
|
50
|
+
*/
|
|
51
|
+
subnet?: string | null;
|
|
52
|
+
}
|
|
53
|
+
/**
|
|
54
|
+
* Check if a given object implements the CreateBridgeNetworkRequest interface.
|
|
55
|
+
*/
|
|
56
|
+
export declare function instanceOfCreateBridgeNetworkRequest(value: object): value is CreateBridgeNetworkRequest;
|
|
57
|
+
export declare function CreateBridgeNetworkRequestFromJSON(json: any): CreateBridgeNetworkRequest;
|
|
58
|
+
export declare function CreateBridgeNetworkRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): CreateBridgeNetworkRequest;
|
|
59
|
+
export declare function CreateBridgeNetworkRequestToJSON(json: any): CreateBridgeNetworkRequest;
|
|
60
|
+
export declare function CreateBridgeNetworkRequestToJSONTyped(value?: CreateBridgeNetworkRequest | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
/**
|
|
5
|
+
* ZLayer API
|
|
6
|
+
* Container orchestration API for ZLayer
|
|
7
|
+
*
|
|
8
|
+
* The version of the OpenAPI document: 0.1.0
|
|
9
|
+
*
|
|
10
|
+
*
|
|
11
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
12
|
+
* https://openapi-generator.tech
|
|
13
|
+
* Do not edit the class manually.
|
|
14
|
+
*/
|
|
15
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
+
exports.instanceOfCreateBridgeNetworkRequest = instanceOfCreateBridgeNetworkRequest;
|
|
17
|
+
exports.CreateBridgeNetworkRequestFromJSON = CreateBridgeNetworkRequestFromJSON;
|
|
18
|
+
exports.CreateBridgeNetworkRequestFromJSONTyped = CreateBridgeNetworkRequestFromJSONTyped;
|
|
19
|
+
exports.CreateBridgeNetworkRequestToJSON = CreateBridgeNetworkRequestToJSON;
|
|
20
|
+
exports.CreateBridgeNetworkRequestToJSONTyped = CreateBridgeNetworkRequestToJSONTyped;
|
|
21
|
+
const BridgeNetworkDriver_1 = require("./BridgeNetworkDriver");
|
|
22
|
+
/**
|
|
23
|
+
* Check if a given object implements the CreateBridgeNetworkRequest interface.
|
|
24
|
+
*/
|
|
25
|
+
function instanceOfCreateBridgeNetworkRequest(value) {
|
|
26
|
+
if (!('name' in value) || value['name'] === undefined)
|
|
27
|
+
return false;
|
|
28
|
+
return true;
|
|
29
|
+
}
|
|
30
|
+
function CreateBridgeNetworkRequestFromJSON(json) {
|
|
31
|
+
return CreateBridgeNetworkRequestFromJSONTyped(json, false);
|
|
32
|
+
}
|
|
33
|
+
function CreateBridgeNetworkRequestFromJSONTyped(json, ignoreDiscriminator) {
|
|
34
|
+
if (json == null) {
|
|
35
|
+
return json;
|
|
36
|
+
}
|
|
37
|
+
return {
|
|
38
|
+
'driver': json['driver'] == null ? undefined : (0, BridgeNetworkDriver_1.BridgeNetworkDriverFromJSON)(json['driver']),
|
|
39
|
+
'internal': json['internal'] == null ? undefined : json['internal'],
|
|
40
|
+
'labels': json['labels'] == null ? undefined : json['labels'],
|
|
41
|
+
'name': json['name'],
|
|
42
|
+
'subnet': json['subnet'] == null ? undefined : json['subnet'],
|
|
43
|
+
};
|
|
44
|
+
}
|
|
45
|
+
function CreateBridgeNetworkRequestToJSON(json) {
|
|
46
|
+
return CreateBridgeNetworkRequestToJSONTyped(json, false);
|
|
47
|
+
}
|
|
48
|
+
function CreateBridgeNetworkRequestToJSONTyped(value, ignoreDiscriminator = false) {
|
|
49
|
+
if (value == null) {
|
|
50
|
+
return value;
|
|
51
|
+
}
|
|
52
|
+
return {
|
|
53
|
+
'driver': (0, BridgeNetworkDriver_1.BridgeNetworkDriverToJSON)(value['driver']),
|
|
54
|
+
'internal': value['internal'],
|
|
55
|
+
'labels': value['labels'],
|
|
56
|
+
'name': value['name'],
|
|
57
|
+
'subnet': value['subnet'],
|
|
58
|
+
};
|
|
59
|
+
}
|
|
@@ -9,8 +9,13 @@
|
|
|
9
9
|
* https://openapi-generator.tech
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
|
+
import type { ContainerRestartPolicy } from './ContainerRestartPolicy';
|
|
13
|
+
import type { NetworkAttachmentRequest } from './NetworkAttachmentRequest';
|
|
12
14
|
import type { VolumeMount } from './VolumeMount';
|
|
15
|
+
import type { HealthCheckRequest } from './HealthCheckRequest';
|
|
16
|
+
import type { PortMapping } from './PortMapping';
|
|
13
17
|
import type { ContainerResourceLimits } from './ContainerResourceLimits';
|
|
18
|
+
import type { RegistryAuth } from './RegistryAuth';
|
|
14
19
|
/**
|
|
15
20
|
* Request to create and start a container
|
|
16
21
|
* @export
|
|
@@ -23,6 +28,13 @@ export interface CreateContainerRequest {
|
|
|
23
28
|
* @memberof CreateContainerRequest
|
|
24
29
|
*/
|
|
25
30
|
command?: Array<string> | null;
|
|
31
|
+
/**
|
|
32
|
+
* Additional DNS servers (maps to Docker's `--dns`). Each entry must be
|
|
33
|
+
* a plausible IPv4 or IPv6 address.
|
|
34
|
+
* @type {Array<string>}
|
|
35
|
+
* @memberof CreateContainerRequest
|
|
36
|
+
*/
|
|
37
|
+
dns?: Array<string>;
|
|
26
38
|
/**
|
|
27
39
|
* Environment variables
|
|
28
40
|
* @type {{ [key: string]: string; }}
|
|
@@ -31,6 +43,28 @@ export interface CreateContainerRequest {
|
|
|
31
43
|
env?: {
|
|
32
44
|
[key: string]: string;
|
|
33
45
|
};
|
|
46
|
+
/**
|
|
47
|
+
* Extra `hostname:ip` entries appended to `/etc/hosts` (maps to Docker's
|
|
48
|
+
* `--add-host`). The special literal `host-gateway` is accepted as the
|
|
49
|
+
* `ip` half.
|
|
50
|
+
* @type {Array<string>}
|
|
51
|
+
* @memberof CreateContainerRequest
|
|
52
|
+
*/
|
|
53
|
+
extraHosts?: Array<string>;
|
|
54
|
+
/**
|
|
55
|
+
* Optional health check. When omitted, the daemon installs a no-op
|
|
56
|
+
* placeholder (`HealthCheck::Tcp { port: 0 }`) matching the current
|
|
57
|
+
* default; the health monitor treats `port == 0` as "skip".
|
|
58
|
+
* @type {HealthCheckRequest}
|
|
59
|
+
* @memberof CreateContainerRequest
|
|
60
|
+
*/
|
|
61
|
+
healthCheck?: HealthCheckRequest | null;
|
|
62
|
+
/**
|
|
63
|
+
* Optional container hostname (maps to Docker's `--hostname`).
|
|
64
|
+
* @type {string}
|
|
65
|
+
* @memberof CreateContainerRequest
|
|
66
|
+
*/
|
|
67
|
+
hostname?: string | null;
|
|
34
68
|
/**
|
|
35
69
|
* OCI image reference (e.g., "nginx:latest", "ubuntu:22.04")
|
|
36
70
|
* @type {string}
|
|
@@ -51,18 +85,61 @@ export interface CreateContainerRequest {
|
|
|
51
85
|
* @memberof CreateContainerRequest
|
|
52
86
|
*/
|
|
53
87
|
name?: string | null;
|
|
88
|
+
/**
|
|
89
|
+
* User-defined bridge/overlay networks to attach the newly-created
|
|
90
|
+
* container to. Each entry references a network by id or name and is
|
|
91
|
+
* attached after the container is successfully started. If any
|
|
92
|
+
* attachment fails, the partially-started container is rolled back
|
|
93
|
+
* (stopped + removed) and the request is failed.
|
|
94
|
+
* @type {Array<NetworkAttachmentRequest>}
|
|
95
|
+
* @memberof CreateContainerRequest
|
|
96
|
+
*/
|
|
97
|
+
networks?: Array<NetworkAttachmentRequest>;
|
|
98
|
+
/**
|
|
99
|
+
* Published ports (Docker's `-p host:container/proto`). When omitted,
|
|
100
|
+
* the container is created without any host port publishing.
|
|
101
|
+
* @type {Array<PortMapping>}
|
|
102
|
+
* @memberof CreateContainerRequest
|
|
103
|
+
*/
|
|
104
|
+
ports?: Array<PortMapping>;
|
|
54
105
|
/**
|
|
55
106
|
* Image pull policy: "always", "`if_not_present`", or "never"
|
|
56
107
|
* @type {string}
|
|
57
108
|
* @memberof CreateContainerRequest
|
|
58
109
|
*/
|
|
59
110
|
pullPolicy?: string | null;
|
|
111
|
+
/**
|
|
112
|
+
* Inline Docker/OCI registry credentials used for this pull only. Not
|
|
113
|
+
* persisted, never logged, never echoed back on a response. When both
|
|
114
|
+
* `registry_credential_id` and `registry_auth` are set, this field
|
|
115
|
+
* takes precedence.
|
|
116
|
+
* @type {RegistryAuth}
|
|
117
|
+
* @memberof CreateContainerRequest
|
|
118
|
+
*/
|
|
119
|
+
registryAuth?: RegistryAuth | null;
|
|
120
|
+
/**
|
|
121
|
+
* Id of a persisted registry credential (from
|
|
122
|
+
* `POST /api/v1/credentials/registry`) to use when pulling the image.
|
|
123
|
+
* Ignored when [`Self::registry_auth`] is also supplied (inline auth
|
|
124
|
+
* wins). Requires the daemon to be configured with a credential store
|
|
125
|
+
* — otherwise the request is rejected with `400`.
|
|
126
|
+
* @type {string}
|
|
127
|
+
* @memberof CreateContainerRequest
|
|
128
|
+
*/
|
|
129
|
+
registryCredentialId?: string | null;
|
|
60
130
|
/**
|
|
61
131
|
* Resource limits (CPU, memory)
|
|
62
132
|
* @type {ContainerResourceLimits}
|
|
63
133
|
* @memberof CreateContainerRequest
|
|
64
134
|
*/
|
|
65
135
|
resources?: ContainerResourceLimits | null;
|
|
136
|
+
/**
|
|
137
|
+
* Container restart policy (Docker-style). When omitted, the runtime
|
|
138
|
+
* applies no explicit restart policy (Docker default: `"no"`).
|
|
139
|
+
* @type {ContainerRestartPolicy}
|
|
140
|
+
* @memberof CreateContainerRequest
|
|
141
|
+
*/
|
|
142
|
+
restartPolicy?: ContainerRestartPolicy | null;
|
|
66
143
|
/**
|
|
67
144
|
* Volume mounts
|
|
68
145
|
* @type {Array<VolumeMount>}
|
|
@@ -18,8 +18,13 @@ exports.CreateContainerRequestFromJSON = CreateContainerRequestFromJSON;
|
|
|
18
18
|
exports.CreateContainerRequestFromJSONTyped = CreateContainerRequestFromJSONTyped;
|
|
19
19
|
exports.CreateContainerRequestToJSON = CreateContainerRequestToJSON;
|
|
20
20
|
exports.CreateContainerRequestToJSONTyped = CreateContainerRequestToJSONTyped;
|
|
21
|
+
const ContainerRestartPolicy_1 = require("./ContainerRestartPolicy");
|
|
22
|
+
const NetworkAttachmentRequest_1 = require("./NetworkAttachmentRequest");
|
|
21
23
|
const VolumeMount_1 = require("./VolumeMount");
|
|
24
|
+
const HealthCheckRequest_1 = require("./HealthCheckRequest");
|
|
25
|
+
const PortMapping_1 = require("./PortMapping");
|
|
22
26
|
const ContainerResourceLimits_1 = require("./ContainerResourceLimits");
|
|
27
|
+
const RegistryAuth_1 = require("./RegistryAuth");
|
|
23
28
|
/**
|
|
24
29
|
* Check if a given object implements the CreateContainerRequest interface.
|
|
25
30
|
*/
|
|
@@ -37,12 +42,21 @@ function CreateContainerRequestFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
37
42
|
}
|
|
38
43
|
return {
|
|
39
44
|
'command': json['command'] == null ? undefined : json['command'],
|
|
45
|
+
'dns': json['dns'] == null ? undefined : json['dns'],
|
|
40
46
|
'env': json['env'] == null ? undefined : json['env'],
|
|
47
|
+
'extraHosts': json['extra_hosts'] == null ? undefined : json['extra_hosts'],
|
|
48
|
+
'healthCheck': json['health_check'] == null ? undefined : (0, HealthCheckRequest_1.HealthCheckRequestFromJSON)(json['health_check']),
|
|
49
|
+
'hostname': json['hostname'] == null ? undefined : json['hostname'],
|
|
41
50
|
'image': json['image'],
|
|
42
51
|
'labels': json['labels'] == null ? undefined : json['labels'],
|
|
43
52
|
'name': json['name'] == null ? undefined : json['name'],
|
|
53
|
+
'networks': json['networks'] == null ? undefined : (json['networks'].map(NetworkAttachmentRequest_1.NetworkAttachmentRequestFromJSON)),
|
|
54
|
+
'ports': json['ports'] == null ? undefined : (json['ports'].map(PortMapping_1.PortMappingFromJSON)),
|
|
44
55
|
'pullPolicy': json['pull_policy'] == null ? undefined : json['pull_policy'],
|
|
56
|
+
'registryAuth': json['registry_auth'] == null ? undefined : (0, RegistryAuth_1.RegistryAuthFromJSON)(json['registry_auth']),
|
|
57
|
+
'registryCredentialId': json['registry_credential_id'] == null ? undefined : json['registry_credential_id'],
|
|
45
58
|
'resources': json['resources'] == null ? undefined : (0, ContainerResourceLimits_1.ContainerResourceLimitsFromJSON)(json['resources']),
|
|
59
|
+
'restartPolicy': json['restart_policy'] == null ? undefined : (0, ContainerRestartPolicy_1.ContainerRestartPolicyFromJSON)(json['restart_policy']),
|
|
46
60
|
'volumes': json['volumes'] == null ? undefined : (json['volumes'].map(VolumeMount_1.VolumeMountFromJSON)),
|
|
47
61
|
'workDir': json['work_dir'] == null ? undefined : json['work_dir'],
|
|
48
62
|
};
|
|
@@ -56,12 +70,21 @@ function CreateContainerRequestToJSONTyped(value, ignoreDiscriminator = false) {
|
|
|
56
70
|
}
|
|
57
71
|
return {
|
|
58
72
|
'command': value['command'],
|
|
73
|
+
'dns': value['dns'],
|
|
59
74
|
'env': value['env'],
|
|
75
|
+
'extra_hosts': value['extraHosts'],
|
|
76
|
+
'health_check': (0, HealthCheckRequest_1.HealthCheckRequestToJSON)(value['healthCheck']),
|
|
77
|
+
'hostname': value['hostname'],
|
|
60
78
|
'image': value['image'],
|
|
61
79
|
'labels': value['labels'],
|
|
62
80
|
'name': value['name'],
|
|
81
|
+
'networks': value['networks'] == null ? undefined : (value['networks'].map(NetworkAttachmentRequest_1.NetworkAttachmentRequestToJSON)),
|
|
82
|
+
'ports': value['ports'] == null ? undefined : (value['ports'].map(PortMapping_1.PortMappingToJSON)),
|
|
63
83
|
'pull_policy': value['pullPolicy'],
|
|
84
|
+
'registry_auth': (0, RegistryAuth_1.RegistryAuthToJSON)(value['registryAuth']),
|
|
85
|
+
'registry_credential_id': value['registryCredentialId'],
|
|
64
86
|
'resources': (0, ContainerResourceLimits_1.ContainerResourceLimitsToJSON)(value['resources']),
|
|
87
|
+
'restart_policy': (0, ContainerRestartPolicy_1.ContainerRestartPolicyToJSON)(value['restartPolicy']),
|
|
65
88
|
'volumes': value['volumes'] == null ? undefined : (value['volumes'].map(VolumeMount_1.VolumeMountToJSON)),
|
|
66
89
|
'work_dir': value['workDir'],
|
|
67
90
|
};
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* ZLayer API
|
|
3
|
+
* Container orchestration API for ZLayer
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 0.1.0
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
/**
|
|
13
|
+
* Request body for `POST /api/v1/volumes`.
|
|
14
|
+
* @export
|
|
15
|
+
* @interface CreateVolumeRequest
|
|
16
|
+
*/
|
|
17
|
+
export interface CreateVolumeRequest {
|
|
18
|
+
/**
|
|
19
|
+
* Optional labels to attach to the volume.
|
|
20
|
+
* @type {{ [key: string]: string; }}
|
|
21
|
+
* @memberof CreateVolumeRequest
|
|
22
|
+
*/
|
|
23
|
+
labels?: {
|
|
24
|
+
[key: string]: string;
|
|
25
|
+
};
|
|
26
|
+
/**
|
|
27
|
+
* Volume name. Required. Must match `^[a-z0-9][a-z0-9_-]{0,63}$`.
|
|
28
|
+
* @type {string}
|
|
29
|
+
* @memberof CreateVolumeRequest
|
|
30
|
+
*/
|
|
31
|
+
name: string;
|
|
32
|
+
/**
|
|
33
|
+
* Optional size hint (humansize format: `"512Mi"`, `"10Gi"`).
|
|
34
|
+
* Recorded in the sidecar for display and future quota enforcement.
|
|
35
|
+
* @type {string}
|
|
36
|
+
* @memberof CreateVolumeRequest
|
|
37
|
+
*/
|
|
38
|
+
size?: string | null;
|
|
39
|
+
/**
|
|
40
|
+
* Optional storage tier. Accepts `"local"` (default), `"cached"`,
|
|
41
|
+
* `"network"`, matching `zlayer_spec::StorageTier`.
|
|
42
|
+
* @type {string}
|
|
43
|
+
* @memberof CreateVolumeRequest
|
|
44
|
+
*/
|
|
45
|
+
tier?: string | null;
|
|
46
|
+
}
|
|
47
|
+
/**
|
|
48
|
+
* Check if a given object implements the CreateVolumeRequest interface.
|
|
49
|
+
*/
|
|
50
|
+
export declare function instanceOfCreateVolumeRequest(value: object): value is CreateVolumeRequest;
|
|
51
|
+
export declare function CreateVolumeRequestFromJSON(json: any): CreateVolumeRequest;
|
|
52
|
+
export declare function CreateVolumeRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): CreateVolumeRequest;
|
|
53
|
+
export declare function CreateVolumeRequestToJSON(json: any): CreateVolumeRequest;
|
|
54
|
+
export declare function CreateVolumeRequestToJSONTyped(value?: CreateVolumeRequest | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
/**
|
|
5
|
+
* ZLayer API
|
|
6
|
+
* Container orchestration API for ZLayer
|
|
7
|
+
*
|
|
8
|
+
* The version of the OpenAPI document: 0.1.0
|
|
9
|
+
*
|
|
10
|
+
*
|
|
11
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
12
|
+
* https://openapi-generator.tech
|
|
13
|
+
* Do not edit the class manually.
|
|
14
|
+
*/
|
|
15
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
+
exports.instanceOfCreateVolumeRequest = instanceOfCreateVolumeRequest;
|
|
17
|
+
exports.CreateVolumeRequestFromJSON = CreateVolumeRequestFromJSON;
|
|
18
|
+
exports.CreateVolumeRequestFromJSONTyped = CreateVolumeRequestFromJSONTyped;
|
|
19
|
+
exports.CreateVolumeRequestToJSON = CreateVolumeRequestToJSON;
|
|
20
|
+
exports.CreateVolumeRequestToJSONTyped = CreateVolumeRequestToJSONTyped;
|
|
21
|
+
/**
|
|
22
|
+
* Check if a given object implements the CreateVolumeRequest interface.
|
|
23
|
+
*/
|
|
24
|
+
function instanceOfCreateVolumeRequest(value) {
|
|
25
|
+
if (!('name' in value) || value['name'] === undefined)
|
|
26
|
+
return false;
|
|
27
|
+
return true;
|
|
28
|
+
}
|
|
29
|
+
function CreateVolumeRequestFromJSON(json) {
|
|
30
|
+
return CreateVolumeRequestFromJSONTyped(json, false);
|
|
31
|
+
}
|
|
32
|
+
function CreateVolumeRequestFromJSONTyped(json, ignoreDiscriminator) {
|
|
33
|
+
if (json == null) {
|
|
34
|
+
return json;
|
|
35
|
+
}
|
|
36
|
+
return {
|
|
37
|
+
'labels': json['labels'] == null ? undefined : json['labels'],
|
|
38
|
+
'name': json['name'],
|
|
39
|
+
'size': json['size'] == null ? undefined : json['size'],
|
|
40
|
+
'tier': json['tier'] == null ? undefined : json['tier'],
|
|
41
|
+
};
|
|
42
|
+
}
|
|
43
|
+
function CreateVolumeRequestToJSON(json) {
|
|
44
|
+
return CreateVolumeRequestToJSONTyped(json, false);
|
|
45
|
+
}
|
|
46
|
+
function CreateVolumeRequestToJSONTyped(value, ignoreDiscriminator = false) {
|
|
47
|
+
if (value == null) {
|
|
48
|
+
return value;
|
|
49
|
+
}
|
|
50
|
+
return {
|
|
51
|
+
'labels': value['labels'],
|
|
52
|
+
'name': value['name'],
|
|
53
|
+
'size': value['size'],
|
|
54
|
+
'tier': value['tier'],
|
|
55
|
+
};
|
|
56
|
+
}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* ZLayer API
|
|
3
|
+
* Container orchestration API for ZLayer
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 0.1.0
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
/**
|
|
13
|
+
* Body for `POST /api/v1/container-networks/{id_or_name}/disconnect`.
|
|
14
|
+
* @export
|
|
15
|
+
* @interface DisconnectBridgeNetworkRequest
|
|
16
|
+
*/
|
|
17
|
+
export interface DisconnectBridgeNetworkRequest {
|
|
18
|
+
/**
|
|
19
|
+
* Container id to detach.
|
|
20
|
+
* @type {string}
|
|
21
|
+
* @memberof DisconnectBridgeNetworkRequest
|
|
22
|
+
*/
|
|
23
|
+
containerId: string;
|
|
24
|
+
/**
|
|
25
|
+
* If true, the runtime is asked to forcibly detach.
|
|
26
|
+
* @type {boolean}
|
|
27
|
+
* @memberof DisconnectBridgeNetworkRequest
|
|
28
|
+
*/
|
|
29
|
+
force?: boolean;
|
|
30
|
+
}
|
|
31
|
+
/**
|
|
32
|
+
* Check if a given object implements the DisconnectBridgeNetworkRequest interface.
|
|
33
|
+
*/
|
|
34
|
+
export declare function instanceOfDisconnectBridgeNetworkRequest(value: object): value is DisconnectBridgeNetworkRequest;
|
|
35
|
+
export declare function DisconnectBridgeNetworkRequestFromJSON(json: any): DisconnectBridgeNetworkRequest;
|
|
36
|
+
export declare function DisconnectBridgeNetworkRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): DisconnectBridgeNetworkRequest;
|
|
37
|
+
export declare function DisconnectBridgeNetworkRequestToJSON(json: any): DisconnectBridgeNetworkRequest;
|
|
38
|
+
export declare function DisconnectBridgeNetworkRequestToJSONTyped(value?: DisconnectBridgeNetworkRequest | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
/**
|
|
5
|
+
* ZLayer API
|
|
6
|
+
* Container orchestration API for ZLayer
|
|
7
|
+
*
|
|
8
|
+
* The version of the OpenAPI document: 0.1.0
|
|
9
|
+
*
|
|
10
|
+
*
|
|
11
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
12
|
+
* https://openapi-generator.tech
|
|
13
|
+
* Do not edit the class manually.
|
|
14
|
+
*/
|
|
15
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
+
exports.instanceOfDisconnectBridgeNetworkRequest = instanceOfDisconnectBridgeNetworkRequest;
|
|
17
|
+
exports.DisconnectBridgeNetworkRequestFromJSON = DisconnectBridgeNetworkRequestFromJSON;
|
|
18
|
+
exports.DisconnectBridgeNetworkRequestFromJSONTyped = DisconnectBridgeNetworkRequestFromJSONTyped;
|
|
19
|
+
exports.DisconnectBridgeNetworkRequestToJSON = DisconnectBridgeNetworkRequestToJSON;
|
|
20
|
+
exports.DisconnectBridgeNetworkRequestToJSONTyped = DisconnectBridgeNetworkRequestToJSONTyped;
|
|
21
|
+
/**
|
|
22
|
+
* Check if a given object implements the DisconnectBridgeNetworkRequest interface.
|
|
23
|
+
*/
|
|
24
|
+
function instanceOfDisconnectBridgeNetworkRequest(value) {
|
|
25
|
+
if (!('containerId' in value) || value['containerId'] === undefined)
|
|
26
|
+
return false;
|
|
27
|
+
return true;
|
|
28
|
+
}
|
|
29
|
+
function DisconnectBridgeNetworkRequestFromJSON(json) {
|
|
30
|
+
return DisconnectBridgeNetworkRequestFromJSONTyped(json, false);
|
|
31
|
+
}
|
|
32
|
+
function DisconnectBridgeNetworkRequestFromJSONTyped(json, ignoreDiscriminator) {
|
|
33
|
+
if (json == null) {
|
|
34
|
+
return json;
|
|
35
|
+
}
|
|
36
|
+
return {
|
|
37
|
+
'containerId': json['container_id'],
|
|
38
|
+
'force': json['force'] == null ? undefined : json['force'],
|
|
39
|
+
};
|
|
40
|
+
}
|
|
41
|
+
function DisconnectBridgeNetworkRequestToJSON(json) {
|
|
42
|
+
return DisconnectBridgeNetworkRequestToJSONTyped(json, false);
|
|
43
|
+
}
|
|
44
|
+
function DisconnectBridgeNetworkRequestToJSONTyped(value, ignoreDiscriminator = false) {
|
|
45
|
+
if (value == null) {
|
|
46
|
+
return value;
|
|
47
|
+
}
|
|
48
|
+
return {
|
|
49
|
+
'container_id': value['containerId'],
|
|
50
|
+
'force': value['force'],
|
|
51
|
+
};
|
|
52
|
+
}
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* ZLayer API
|
|
3
|
+
* Container orchestration API for ZLayer
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 0.1.0
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
/**
|
|
13
|
+
* Container health check request.
|
|
14
|
+
*
|
|
15
|
+
* Mirrors the on-disk `HealthCheck` enum (see `zlayer_spec::HealthCheck`) as a
|
|
16
|
+
* discriminated union keyed on `type`. Translated to `zlayer_spec::HealthSpec`
|
|
17
|
+
* by `HealthCheckRequest::to_health_spec`. Durations are humantime strings
|
|
18
|
+
* (for example `"10s"`, `"500ms"`, `"1m"`).
|
|
19
|
+
*
|
|
20
|
+
* ## Variants
|
|
21
|
+
* - `type: "tcp"` — requires `port` (1-65535).
|
|
22
|
+
* - `type: "http"` — requires `url`; `expect_status` defaults to 200.
|
|
23
|
+
* - `type: "command"` — requires `command` (array of argv tokens; joined with
|
|
24
|
+
* spaces and passed to `sh -c` by the health monitor, matching the existing
|
|
25
|
+
* compose-to-ZLayer conversion in `zlayer-docker`).
|
|
26
|
+
* @export
|
|
27
|
+
* @interface HealthCheckRequest
|
|
28
|
+
*/
|
|
29
|
+
export interface HealthCheckRequest {
|
|
30
|
+
/**
|
|
31
|
+
* Command argv (required when `type == "command"`). Joined with spaces
|
|
32
|
+
* and passed to `sh -c`.
|
|
33
|
+
* @type {Array<string>}
|
|
34
|
+
* @memberof HealthCheckRequest
|
|
35
|
+
*/
|
|
36
|
+
command?: Array<string> | null;
|
|
37
|
+
/**
|
|
38
|
+
* HTTP status code expected from `url` (defaults to 200).
|
|
39
|
+
* @type {number}
|
|
40
|
+
* @memberof HealthCheckRequest
|
|
41
|
+
*/
|
|
42
|
+
expectStatus?: number | null;
|
|
43
|
+
/**
|
|
44
|
+
* Interval between checks, humantime format (e.g. `"30s"`). Defaults to 30s.
|
|
45
|
+
* @type {string}
|
|
46
|
+
* @memberof HealthCheckRequest
|
|
47
|
+
*/
|
|
48
|
+
interval?: string | null;
|
|
49
|
+
/**
|
|
50
|
+
* TCP port (required when `type == "tcp"`).
|
|
51
|
+
* @type {number}
|
|
52
|
+
* @memberof HealthCheckRequest
|
|
53
|
+
*/
|
|
54
|
+
port?: number | null;
|
|
55
|
+
/**
|
|
56
|
+
* Number of consecutive failures before marking unhealthy. Defaults to 3.
|
|
57
|
+
* @type {number}
|
|
58
|
+
* @memberof HealthCheckRequest
|
|
59
|
+
*/
|
|
60
|
+
retries?: number | null;
|
|
61
|
+
/**
|
|
62
|
+
* Grace period before the first check runs, humantime format. Maps to
|
|
63
|
+
* `HealthSpec::start_grace`.
|
|
64
|
+
* @type {string}
|
|
65
|
+
* @memberof HealthCheckRequest
|
|
66
|
+
*/
|
|
67
|
+
startPeriod?: string | null;
|
|
68
|
+
/**
|
|
69
|
+
* Timeout per individual check, humantime format.
|
|
70
|
+
* @type {string}
|
|
71
|
+
* @memberof HealthCheckRequest
|
|
72
|
+
*/
|
|
73
|
+
timeout?: string | null;
|
|
74
|
+
/**
|
|
75
|
+
* Check variant: `"tcp"`, `"http"`, or `"command"`.
|
|
76
|
+
* @type {string}
|
|
77
|
+
* @memberof HealthCheckRequest
|
|
78
|
+
*/
|
|
79
|
+
type: string;
|
|
80
|
+
/**
|
|
81
|
+
* HTTP URL (required when `type == "http"`).
|
|
82
|
+
* @type {string}
|
|
83
|
+
* @memberof HealthCheckRequest
|
|
84
|
+
*/
|
|
85
|
+
url?: string | null;
|
|
86
|
+
}
|
|
87
|
+
/**
|
|
88
|
+
* Check if a given object implements the HealthCheckRequest interface.
|
|
89
|
+
*/
|
|
90
|
+
export declare function instanceOfHealthCheckRequest(value: object): value is HealthCheckRequest;
|
|
91
|
+
export declare function HealthCheckRequestFromJSON(json: any): HealthCheckRequest;
|
|
92
|
+
export declare function HealthCheckRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): HealthCheckRequest;
|
|
93
|
+
export declare function HealthCheckRequestToJSON(json: any): HealthCheckRequest;
|
|
94
|
+
export declare function HealthCheckRequestToJSONTyped(value?: HealthCheckRequest | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
/**
|
|
5
|
+
* ZLayer API
|
|
6
|
+
* Container orchestration API for ZLayer
|
|
7
|
+
*
|
|
8
|
+
* The version of the OpenAPI document: 0.1.0
|
|
9
|
+
*
|
|
10
|
+
*
|
|
11
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
12
|
+
* https://openapi-generator.tech
|
|
13
|
+
* Do not edit the class manually.
|
|
14
|
+
*/
|
|
15
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
+
exports.instanceOfHealthCheckRequest = instanceOfHealthCheckRequest;
|
|
17
|
+
exports.HealthCheckRequestFromJSON = HealthCheckRequestFromJSON;
|
|
18
|
+
exports.HealthCheckRequestFromJSONTyped = HealthCheckRequestFromJSONTyped;
|
|
19
|
+
exports.HealthCheckRequestToJSON = HealthCheckRequestToJSON;
|
|
20
|
+
exports.HealthCheckRequestToJSONTyped = HealthCheckRequestToJSONTyped;
|
|
21
|
+
/**
|
|
22
|
+
* Check if a given object implements the HealthCheckRequest interface.
|
|
23
|
+
*/
|
|
24
|
+
function instanceOfHealthCheckRequest(value) {
|
|
25
|
+
if (!('type' in value) || value['type'] === undefined)
|
|
26
|
+
return false;
|
|
27
|
+
return true;
|
|
28
|
+
}
|
|
29
|
+
function HealthCheckRequestFromJSON(json) {
|
|
30
|
+
return HealthCheckRequestFromJSONTyped(json, false);
|
|
31
|
+
}
|
|
32
|
+
function HealthCheckRequestFromJSONTyped(json, ignoreDiscriminator) {
|
|
33
|
+
if (json == null) {
|
|
34
|
+
return json;
|
|
35
|
+
}
|
|
36
|
+
return {
|
|
37
|
+
'command': json['command'] == null ? undefined : json['command'],
|
|
38
|
+
'expectStatus': json['expect_status'] == null ? undefined : json['expect_status'],
|
|
39
|
+
'interval': json['interval'] == null ? undefined : json['interval'],
|
|
40
|
+
'port': json['port'] == null ? undefined : json['port'],
|
|
41
|
+
'retries': json['retries'] == null ? undefined : json['retries'],
|
|
42
|
+
'startPeriod': json['start_period'] == null ? undefined : json['start_period'],
|
|
43
|
+
'timeout': json['timeout'] == null ? undefined : json['timeout'],
|
|
44
|
+
'type': json['type'],
|
|
45
|
+
'url': json['url'] == null ? undefined : json['url'],
|
|
46
|
+
};
|
|
47
|
+
}
|
|
48
|
+
function HealthCheckRequestToJSON(json) {
|
|
49
|
+
return HealthCheckRequestToJSONTyped(json, false);
|
|
50
|
+
}
|
|
51
|
+
function HealthCheckRequestToJSONTyped(value, ignoreDiscriminator = false) {
|
|
52
|
+
if (value == null) {
|
|
53
|
+
return value;
|
|
54
|
+
}
|
|
55
|
+
return {
|
|
56
|
+
'command': value['command'],
|
|
57
|
+
'expect_status': value['expectStatus'],
|
|
58
|
+
'interval': value['interval'],
|
|
59
|
+
'port': value['port'],
|
|
60
|
+
'retries': value['retries'],
|
|
61
|
+
'start_period': value['startPeriod'],
|
|
62
|
+
'timeout': value['timeout'],
|
|
63
|
+
'type': value['type'],
|
|
64
|
+
'url': value['url'],
|
|
65
|
+
};
|
|
66
|
+
}
|