UNPKG

googleapis

Version:
892 lines 292 kB
/// <reference types="node" /> import { OAuth2Client, JWT, Compute, UserRefreshClient, BaseExternalAccountClient, GaxiosPromise, GoogleConfigurable, MethodOptions, StreamMethodOptions, GlobalOptions, GoogleAuth, BodyResponseCallback, APIRequestContext } from 'googleapis-common'; import { Readable } from 'stream'; export declare namespace run_v1alpha1 { export interface Options extends GlobalOptions { version: 'v1alpha1'; } interface StandardParameters { /** * Auth client or API Key for the request */ auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient | BaseExternalAccountClient | GoogleAuth; /** * V1 error format. */ '$.xgafv'?: string; /** * OAuth access token. */ access_token?: string; /** * Data format for response. */ alt?: string; /** * JSONP */ callback?: string; /** * Selector specifying which fields to include in a partial response. */ fields?: string; /** * API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. */ key?: string; /** * OAuth 2.0 token for the current user. */ oauth_token?: string; /** * Returns response with indentations and line breaks. */ prettyPrint?: boolean; /** * Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. */ quotaUser?: string; /** * Legacy upload protocol for media (e.g. "media", "multipart"). */ uploadType?: string; /** * Upload protocol for media (e.g. "raw", "multipart"). */ upload_protocol?: string; } /** * Cloud Run Admin API * * Deploy and manage user provided container images that scale automatically based on HTTP traffic. * * @example * ```js * const {google} = require('googleapis'); * const run = google.run('v1alpha1'); * ``` */ export class Run { context: APIRequestContext; namespaces: Resource$Namespaces; projects: Resource$Projects; constructor(options: GlobalOptions, google?: GoogleConfigurable); } /** * Information for connecting over HTTP(s). */ export interface Schema$Addressable { /** * Deprecated - use url instead. */ hostname?: string | null; url?: string | null; } /** * Specifies the audit configuration for a service. The configuration determines which permission types are logged, and what identities, if any, are exempted from logging. An AuditConfig must have one or more AuditLogConfigs. If there are AuditConfigs for both `allServices` and a specific service, the union of the two AuditConfigs is used for that service: the log_types specified in each AuditConfig are enabled, and the exempted_members in each AuditLogConfig are exempted. Example Policy with multiple AuditConfigs: { "audit_configs": [ { "service": "allServices", "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:jose@example.com" ] \}, { "log_type": "DATA_WRITE" \}, { "log_type": "ADMIN_READ" \} ] \}, { "service": "sampleservice.googleapis.com", "audit_log_configs": [ { "log_type": "DATA_READ" \}, { "log_type": "DATA_WRITE", "exempted_members": [ "user:aliya@example.com" ] \} ] \} ] \} For sampleservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ logging. It also exempts jose@example.com from DATA_READ logging, and aliya@example.com from DATA_WRITE logging. */ export interface Schema$AuditConfig { /** * The configuration for logging of each type of permission. */ auditLogConfigs?: Schema$AuditLogConfig[]; /** * Specifies a service that will be enabled for audit logging. For example, `storage.googleapis.com`, `cloudsql.googleapis.com`. `allServices` is a special value that covers all services. */ service?: string | null; } /** * Provides the configuration for logging a type of permissions. Example: { "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:jose@example.com" ] \}, { "log_type": "DATA_WRITE" \} ] \} This enables 'DATA_READ' and 'DATA_WRITE' logging, while exempting jose@example.com from DATA_READ logging. */ export interface Schema$AuditLogConfig { /** * Specifies the identities that do not cause logging for this type of permission. Follows the same format of Binding.members. */ exemptedMembers?: string[] | null; /** * The log type that this config enables. */ logType?: string | null; } /** * A domain that a user has been authorized to administer. To authorize use of a domain, verify ownership via [Webmaster Central](https://www.google.com/webmasters/verification/home). */ export interface Schema$AuthorizedDomain { /** * Relative name of the domain authorized for use. Example: `example.com`. */ id?: string | null; /** * Read only. Full path to the `AuthorizedDomain` resource in the API. Example: `apps/myapp/authorizedDomains/example.com`. */ name?: string | null; } /** * Associates `members` with a `role`. */ export interface Schema$Binding { /** * The condition that is associated with this binding. If the condition evaluates to `true`, then this binding applies to the current request. If the condition evaluates to `false`, then this binding does not apply to the current request. However, a different role binding might grant the same role to one or more of the members in this binding. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies). */ condition?: Schema$Expr; /** * Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid\}`: An email address that represents a specific Google account. For example, `alice@example.com` . * `serviceAccount:{emailid\}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid\}`: An email address that represents a Google group. For example, `admins@example.com`. * `deleted:user:{emailid\}?uid={uniqueid\}`: An email address (plus unique identifier) representing a user that has been recently deleted. For example, `alice@example.com?uid=123456789012345678901`. If the user is recovered, this value reverts to `user:{emailid\}` and the recovered user retains the role in the binding. * `deleted:serviceAccount:{emailid\}?uid={uniqueid\}`: An email address (plus unique identifier) representing a service account that has been recently deleted. For example, `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`. If the service account is undeleted, this value reverts to `serviceAccount:{emailid\}` and the undeleted service account retains the role in the binding. * `deleted:group:{emailid\}?uid={uniqueid\}`: An email address (plus unique identifier) representing a Google group that has been recently deleted. For example, `admins@example.com?uid=123456789012345678901`. If the group is recovered, this value reverts to `group:{emailid\}` and the recovered group retains the role in the binding. * `domain:{domain\}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. */ members?: string[] | null; /** * Role that is assigned to `members`. For example, `roles/viewer`, `roles/editor`, or `roles/owner`. */ role?: string | null; } /** * Adds and removes POSIX capabilities from running containers. */ export interface Schema$Capabilities { /** * Added capabilities +optional */ add?: string[] | null; /** * Removed capabilities +optional */ drop?: string[] | null; } /** * ConfigMapEnvSource selects a ConfigMap to populate the environment variables with. The contents of the target ConfigMap's Data field will represent the key-value pairs as environment variables. */ export interface Schema$ConfigMapEnvSource { /** * This field should not be used directly as it is meant to be inlined directly into the message. Use the "name" field instead. */ localObjectReference?: Schema$LocalObjectReference; /** * Cloud Run fully managed: not supported Cloud Run for Anthos: supported The ConfigMap to select from. */ name?: string | null; /** * Cloud Run fully managed: not supported Cloud Run for Anthos: supported Specify whether the ConfigMap must be defined +optional */ optional?: boolean | null; } /** * Cloud Run fully managed: not supported Cloud Run on GKE: supported Selects a key from a ConfigMap. */ export interface Schema$ConfigMapKeySelector { /** * Cloud Run fully managed: not supported Cloud Run on GKE: supported The key to select. */ key?: string | null; /** * This field should not be used directly as it is meant to be inlined directly into the message. Use the "name" field instead. */ localObjectReference?: Schema$LocalObjectReference; /** * Cloud Run fully managed: not supported Cloud Run on GKE: supported The ConfigMap to select from. */ name?: string | null; /** * Cloud Run fully managed: not supported Cloud Run on GKE: supported Specify whether the ConfigMap or its key must be defined +optional */ optional?: boolean | null; } /** * Adapts a ConfigMap into a volume. The contents of the target ConfigMap's Data field will be presented in a volume as files using the keys in the Data field as the file names, unless the items element is populated with specific mappings of keys to paths. */ export interface Schema$ConfigMapVolumeSource { /** * Mode bits to use on created files by default. Must be a value between 0 and 0777. Defaults to 0644. Directories within the path are not affected by this setting. This might be in conflict with other options that affect the file mode, like fsGroup, and the result can be other mode bits set. */ defaultMode?: number | null; /** * If unspecified, each key-value pair in the Data field of the referenced Secret will be projected into the volume as a file whose name is the key and content is the value. If specified, the listed keys will be projected into the specified paths, and unlisted keys will not be present. If a key is specified which is not present in the Secret, the volume setup will error unless it is marked optional. */ items?: Schema$KeyToPath[]; /** * Name of the config. */ name?: string | null; /** * Specify whether the Secret or its keys must be defined. */ optional?: boolean | null; } /** * Configuration represents the "floating HEAD" of a linear history of Revisions, and optionally how the containers those revisions reference are built. Users create new Revisions by updating the Configuration's spec. The "latest created" revision's name is available under status, as is the "latest ready" revision's name. See also: https://github.com/knative/serving/blob/master/docs/spec/overview.md#configuration */ export interface Schema$Configuration { /** * The API version for this call such as "serving.knative.dev/v1alpha1". */ apiVersion?: string | null; /** * The kind of resource, in this case always "Configuration". */ kind?: string | null; /** * Metadata associated with this Configuration, including name, namespace, labels, and annotations. */ metadata?: Schema$ObjectMeta; /** * Spec holds the desired state of the Configuration (from the client). */ spec?: Schema$ConfigurationSpec; /** * Status communicates the observed state of the Configuration (from the controller). */ status?: Schema$ConfigurationStatus; } /** * ConfigurationCondition defines a readiness condition for a Configuration. */ export interface Schema$ConfigurationCondition { /** * Last time the condition transitioned from one status to another. +optional */ lastTransitionTime?: string | null; /** * Human-readable message indicating details about last transition. +optional */ message?: string | null; /** * One-word CamelCase reason for the condition's last transition. +optional */ reason?: string | null; /** * How to interpret failures of this condition, one of Error, Warning, Info +optional */ severity?: string | null; /** * Status of the condition, one of True, False, Unknown. */ status?: string | null; /** * ConfigurationConditionType is used to communicate the status of the reconciliation process. See also: https://github.com/knative/serving/blob/master/docs/spec/errors.md#error-conditions-and-reporting Types include:"Ready" */ type?: string | null; } /** * ConfigurationSpec holds the desired state of the Configuration (from the client). */ export interface Schema$ConfigurationSpec { /** * Deprecated and not currently populated by Cloud Run. See metadata.generation instead, which is the sequence number containing the latest generation of the desired state. Read-only. */ generation?: number | null; /** * RevisionTemplate holds the latest specification for the Revision to be stamped out. The template references the container image, and may also include labels and annotations that should be attached to the Revision. To correlate a Revision, and/or to force a Revision to be created when the spec doesn't otherwise change, a nonce label may be provided in the template metadata. For more details, see: https://github.com/knative/serving/blob/master/docs/client-conventions.md#associate-modifications-with-revisions Cloud Run does not currently support referencing a build that is responsible for materializing the container image from source. */ revisionTemplate?: Schema$RevisionTemplate; /** * Template holds the latest specification for the Revision to be stamped out. */ template?: Schema$RevisionTemplate; } /** * ConfigurationStatus communicates the observed state of the Configuration (from the controller). */ export interface Schema$ConfigurationStatus { /** * Conditions communicates information about ongoing/complete reconciliation processes that bring the "spec" inline with the observed state of the world. */ conditions?: Schema$ConfigurationCondition[]; /** * LatestCreatedRevisionName is the last revision that was created from this Configuration. It might not be ready yet, for that use LatestReadyRevisionName. */ latestCreatedRevisionName?: string | null; /** * LatestReadyRevisionName holds the name of the latest Revision stamped out from this Configuration that has had its "Ready" condition become "True". */ latestReadyRevisionName?: string | null; /** * ObservedGeneration is the 'Generation' of the Configuration that was last processed by the controller. The observed generation is updated even if the controller failed to process the spec and create the Revision. Clients polling for completed reconciliation should poll until observedGeneration = metadata.generation, and the Ready condition's status is True or False. */ observedGeneration?: number | null; } /** * A single application container. This specifies both the container to run, the command to run in the container and the arguments to supply to it. Note that additional arguments may be supplied by the system to the container at runtime. */ export interface Schema$Container { /** * Arguments to the entrypoint. The docker image's CMD is used if this is not provided. Variable references $(VAR_NAME) are expanded using the container's environment. If a variable cannot be resolved, the reference in the input string will be unchanged. The $(VAR_NAME) syntax can be escaped with a double $$, ie: $$(VAR_NAME). Escaped references will never be expanded, regardless of whether the variable exists or not. Cannot be updated. More info: https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/#running-a-command-in-a-shell +optional */ args?: string[] | null; /** * Entrypoint array. Not executed within a shell. The docker image's ENTRYPOINT is used if this is not provided. Variable references $(VAR_NAME) are expanded using the container's environment. If a variable cannot be resolved, the reference in the input string will be unchanged. The $(VAR_NAME) syntax can be escaped with a double $$, ie: $$(VAR_NAME). Escaped references will never be expanded, regardless of whether the variable exists or not. Cannot be updated. More info: https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/#running-a-command-in-a-shell +optional */ command?: string[] | null; /** * List of environment variables to set in the container. Cannot be updated. +optional */ env?: Schema$EnvVar[]; /** * List of sources to populate environment variables in the container. The keys defined within a source must be a C_IDENTIFIER. All invalid keys will be reported as an event when the container is starting. When a key exists in multiple sources, the value associated with the last source will take precedence. Values defined by an Env with a duplicate key will take precedence. Cannot be updated. +optional */ envFrom?: Schema$EnvFromSource[]; /** * Docker image name. More info: https://kubernetes.io/docs/concepts/containers/images */ image?: string | null; /** * Image pull policy. One of Always, Never, IfNotPresent. Defaults to Always if :latest tag is specified, or IfNotPresent otherwise. Cannot be updated. More info: https://kubernetes.io/docs/concepts/containers/images#updating-images +optional */ imagePullPolicy?: string | null; /** * Actions that the management system should take in response to container lifecycle events. Cannot be updated. +optional */ lifecycle?: Schema$Lifecycle; /** * Periodic probe of container liveness. Container will be restarted if the probe fails. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes +optional */ livenessProbe?: Schema$Probe; /** * Name of the container specified as a DNS_LABEL. Each container must have a unique name (DNS_LABEL). Cannot be updated. */ name?: string | null; /** * List of ports to expose from the container. Exposing a port here gives the system additional information about the network connections a container uses, but is primarily informational. Not specifying a port here DOES NOT prevent that port from being exposed. Any port which is listening on the default "0.0.0.0" address inside a container will be accessible from the network. Cannot be updated. +optional */ ports?: Schema$ContainerPort[]; /** * Periodic probe of container service readiness. Container will be removed from service endpoints if the probe fails. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes +optional */ readinessProbe?: Schema$Probe; /** * Compute Resources required by this container. Cannot be updated. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#resources +optional */ resources?: Schema$ResourceRequirements; /** * Security options the pod should run with. More info: https://kubernetes.io/docs/concepts/policy/security-context/ More info: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/ +optional */ securityContext?: Schema$SecurityContext; /** * Whether this container should allocate a buffer for stdin in the container runtime. If this is not set, reads from stdin in the container will always result in EOF. Default is false. +optional */ stdin?: boolean | null; /** * Whether the container runtime should close the stdin channel after it has been opened by a single attach. When stdin is true the stdin stream will remain open across multiple attach sessions. If stdinOnce is set to true, stdin is opened on container start, is empty until the first client attaches to stdin, and then remains open and accepts data until the client disconnects, at which time stdin is closed and remains closed until the container is restarted. If this flag is false, a container processes that reads from stdin will never receive an EOF. Default is false +optional */ stdinOnce?: boolean | null; /** * Optional: Path at which the file to which the container's termination message will be written is mounted into the container's filesystem. Message written is intended to be brief final status, such as an assertion failure message. Will be truncated by the node if greater than 4096 bytes. The total message length across all containers will be limited to 12kb. Defaults to /dev/termination-log. Cannot be updated. +optional */ terminationMessagePath?: string | null; /** * Indicate how the termination message should be populated. File will use the contents of terminationMessagePath to populate the container status message on both success and failure. FallbackToLogsOnError will use the last chunk of container log output if the termination message file is empty and the container exited with an error. The log output is limited to 2048 bytes or 80 lines, whichever is smaller. Defaults to File. Cannot be updated. +optional */ terminationMessagePolicy?: string | null; /** * Whether this container should allocate a TTY for itself, also requires 'stdin' to be true. Default is false. +optional */ tty?: boolean | null; /** * volumeDevices is the list of block devices to be used by the container. This is an alpha feature and may change in the future. +optional */ volumeDevices?: Schema$VolumeDevice[]; /** * Pod volumes to mount into the container's filesystem. Cannot be updated. +optional */ volumeMounts?: Schema$VolumeMount[]; /** * Container's working directory. If not specified, the container runtime's default will be used, which might be configured in the container image. Cannot be updated. +optional */ workingDir?: string | null; } /** * ContainerPort represents a network port in a single container. */ export interface Schema$ContainerPort { /** * Number of port to expose on the pod's IP address. This must be a valid port number, 0 < x < 65536. */ containerPort?: number | null; /** * What host IP to bind the external port to. +optional */ hostIP?: string | null; /** * Number of port to expose on the host. If specified, this must be a valid port number, 0 < x < 65536. If HostNetwork is specified, this must match ContainerPort. Most containers do not need this. +optional */ hostPort?: number | null; /** * If specified, this must be an IANA_SVC_NAME and unique within the pod. Each named port in a pod must have a unique name. Name for the port that can be referred to by services. +optional */ name?: string | null; /** * Protocol for port. Must be UDP or TCP. Defaults to "TCP". +optional */ protocol?: string | null; } /** * Resource to hold the state and status of a user's domain mapping. NOTE: This resource is currently in Beta. */ export interface Schema$DomainMapping { /** * The API version for this call such as "domains.cloudrun.com/v1alpha1". */ apiVersion?: string | null; /** * The kind of resource, in this case "DomainMapping". */ kind?: string | null; /** * Metadata associated with this BuildTemplate. */ metadata?: Schema$ObjectMeta; /** * The spec for this DomainMapping. */ spec?: Schema$DomainMappingSpec; /** * The current status of the DomainMapping. */ status?: Schema$DomainMappingStatus; } /** * DomainMappingCondition contains state information for a DomainMapping. */ export interface Schema$DomainMappingCondition { /** * Last time the condition transitioned from one status to another. +optional */ lastTransitionTime?: string | null; /** * Human readable message indicating details about the current status. +optional */ message?: string | null; /** * One-word CamelCase reason for the condition's current status. +optional */ reason?: string | null; /** * How to interpret failures of this condition, one of Error, Warning, Info +optional */ severity?: string | null; /** * Status of the condition, one of True, False, Unknown. */ status?: string | null; /** * Type of domain mapping condition. */ type?: string | null; } /** * The desired state of the Domain Mapping. */ export interface Schema$DomainMappingSpec { /** * The mode of the certificate. */ certificateMode?: string | null; /** * If set, the mapping will override any mapping set before this spec was set. It is recommended that the user leaves this empty to receive an error warning about a potential conflict and only set it once the respective UI has given such a warning. */ forceOverride?: boolean | null; /** * The name of the Knative Route that this DomainMapping applies to. The route must exist. */ routeName?: string | null; } /** * The current state of the Domain Mapping. */ export interface Schema$DomainMappingStatus { /** * Array of observed DomainMappingConditions, indicating the current state of the DomainMapping. */ conditions?: Schema$DomainMappingCondition[]; /** * The name of the route that the mapping currently points to. */ mappedRouteName?: string | null; /** * ObservedGeneration is the 'Generation' of the DomainMapping that was last processed by the controller. Clients polling for completed reconciliation should poll until observedGeneration = metadata.generation and the Ready condition's status is True or False. */ observedGeneration?: number | null; /** * The resource records required to configure this domain mapping. These records must be added to the domain's DNS configuration in order to serve the application via this domain mapping. */ resourceRecords?: Schema$ResourceRecord[]; /** * Cloud Run fully managed: not supported Cloud Run on GKE: supported Holds the URL that will serve the traffic of the DomainMapping. +optional */ url?: string | null; } /** * A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); \} The JSON representation for `Empty` is empty JSON object `{\}`. */ export interface Schema$Empty { } /** * EnvFromSource represents the source of a set of ConfigMaps */ export interface Schema$EnvFromSource { /** * The ConfigMap to select from +optional */ configMapRef?: Schema$ConfigMapEnvSource; /** * An optional identifier to prepend to each key in the ConfigMap. Must be a C_IDENTIFIER. +optional */ prefix?: string | null; /** * The Secret to select from +optional */ secretRef?: Schema$SecretEnvSource; } /** * EnvVar represents an environment variable present in a Container. */ export interface Schema$EnvVar { /** * Name of the environment variable. Must be a C_IDENTIFIER. */ name?: string | null; /** * Variable references $(VAR_NAME) are expanded using the previous defined environment variables in the container and any route environment variables. If a variable cannot be resolved, the reference in the input string will be unchanged. The $(VAR_NAME) syntax can be escaped with a double $$, ie: $$(VAR_NAME). Escaped references will never be expanded, regardless of whether the variable exists or not. Defaults to "". +optional */ value?: string | null; /** * Cloud Run fully managed: not supported Cloud Run on GKE: supported Source for the environment variable's value. Cannot be used if value is not empty. +optional */ valueFrom?: Schema$EnvVarSource; } /** * Cloud Run fully managed: not supported Cloud Run on GKE: supported EnvVarSource represents a source for the value of an EnvVar. */ export interface Schema$EnvVarSource { /** * Cloud Run fully managed: not supported Cloud Run on GKE: supported Selects a key of a ConfigMap. +optional */ configMapKeyRef?: Schema$ConfigMapKeySelector; /** * Cloud Run fully managed: not supported Cloud Run on GKE: supported Selects a key of a secret in the pod's namespace +optional */ secretKeyRef?: Schema$SecretKeySelector; } /** * ExecAction describes a "run in container" action. */ export interface Schema$ExecAction { /** * Command is the command line to execute inside the container, the working directory for the command is root ('/') in the container's filesystem. The command is simply exec'd, it is not run inside a shell, so traditional shell instructions ('|', etc) won't work. To use a shell, you need to explicitly call out to that shell. Exit status of 0 is treated as live/healthy and non-zero is unhealthy. +optional */ command?: string[] | null; } /** * Represents a textual expression in the Common Expression Language (CEL) syntax. CEL is a C-like expression language. The syntax and semantics of CEL are documented at https://github.com/google/cel-spec. Example (Comparison): title: "Summary size limit" description: "Determines if a summary is less than 100 chars" expression: "document.summary.size() < 100" Example (Equality): title: "Requestor is owner" description: "Determines if requestor is the document owner" expression: "document.owner == request.auth.claims.email" Example (Logic): title: "Public documents" description: "Determine whether the document should be publicly visible" expression: "document.type != 'private' && document.type != 'internal'" Example (Data Manipulation): title: "Notification string" description: "Create a notification string with a timestamp." expression: "'New message received at ' + string(document.create_time)" The exact variables and functions that may be referenced within an expression are determined by the service that evaluates it. See the service documentation for additional information. */ export interface Schema$Expr { /** * Optional. Description of the expression. This is a longer text which describes the expression, e.g. when hovered over it in a UI. */ description?: string | null; /** * Textual representation of an expression in Common Expression Language syntax. */ expression?: string | null; /** * Optional. String indicating the location of the expression for error reporting, e.g. a file name and a position in the file. */ location?: string | null; /** * Optional. Title for the expression, i.e. a short string describing its purpose. This can be used e.g. in UIs which allow to enter the expression. */ title?: string | null; } /** * Handler defines a specific action that should be taken */ export interface Schema$Handler { /** * One and only one of the following should be specified. Exec specifies the action to take. +optional */ exec?: Schema$ExecAction; /** * HTTPGet specifies the http request to perform. +optional */ httpGet?: Schema$HTTPGetAction; /** * TCPSocket specifies an action involving a TCP port. TCP hooks not yet supported */ tcpSocket?: Schema$TCPSocketAction; } /** * HTTPGetAction describes an action based on HTTP Get requests. */ export interface Schema$HTTPGetAction { /** * Host name to connect to, defaults to the pod IP. You probably want to set "Host" in httpHeaders instead. +optional */ host?: string | null; /** * Custom headers to set in the request. HTTP allows repeated headers. +optional */ httpHeaders?: Schema$HTTPHeader[]; /** * Path to access on the HTTP server. +optional */ path?: string | null; /** * Name or number of the port to access on the container. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME. */ port?: Schema$IntOrString; /** * Scheme to use for connecting to the host. Defaults to HTTP. +optional */ scheme?: string | null; } /** * HTTPHeader describes a custom header to be used in HTTP probes */ export interface Schema$HTTPHeader { /** * The header field name */ name?: string | null; /** * The header field value */ value?: string | null; } /** * InstanceSpec is a description of an instance. */ export interface Schema$InstanceSpec { /** * Optional. Optional duration in seconds the instance may be active relative to StartTime before the system will actively try to mark it failed and kill associated containers. If set to zero, the system will never attempt to kill an instance based on time. Otherwise, value must be a positive integer. +optional */ activeDeadlineSeconds?: string | null; /** * Optional. List of containers belonging to the instance. We disallow a number of fields on this Container. Only a single container may be provided. */ containers?: Schema$Container[]; /** * Optional. Restart policy for all containers within the instance. Allowed values are: - OnFailure: Instances will always be restarted on failure if the backoffLimit has not been reached. - Never: Instances are never restarted and all failures are permanent. Cannot be used if backoffLimit is set. +optional */ restartPolicy?: string | null; /** * Optional. Email address of the IAM service account associated with the instance of a Job. The service account represents the identity of the running instance, and determines what permissions the instance has. If not provided, the instance will use the project's default service account. +optional */ serviceAccountName?: string | null; /** * Optional. Optional duration in seconds the instance needs to terminate gracefully. Value must be non-negative integer. The value zero indicates delete immediately. The grace period is the duration in seconds after the processes running in the instance are sent a termination signal and the time when the processes are forcibly halted with a kill signal. Set this value longer than the expected cleanup time for your process. +optional */ terminationGracePeriodSeconds?: string | null; /** * Optional. List of volumes that can be mounted by containers belonging to the instance. More info: https://kubernetes.io/docs/concepts/storage/volumes +optional */ volumes?: Schema$Volume[]; } /** * Instance represents the status of an instance of a Job. */ export interface Schema$InstanceStatus { /** * Optional. Represents time when the instance was completed. It is not guaranteed to be set in happens-before order across separate operations. It is represented in RFC3339 form and is in UTC. +optional */ completionTime?: string | null; /** * Optional. The number of times this instance exited with code \> 0; +optional */ failed?: number | null; /** * Required. Index of the instance, unique per Job, and beginning at 0. */ index?: number | null; /** * Optional. Last exit code seen for this instance. +optional */ lastExitCode?: number | null; /** * Optional. The number of times this instance was restarted. Instances are restarted according the restartPolicy configured in the Job template. +optional */ restarted?: number | null; /** * Optional. Represents time when the instance was created by the job controller. It is not guaranteed to be set in happens-before order across separate operations. It is represented in RFC3339 form and is in UTC. +optional */ startTime?: string | null; /** * Optional. The number of times this instance exited with code == 0. +optional */ succeeded?: number | null; } /** * InstanceTemplateSpec describes the data an instance should have when created from a template. */ export interface Schema$InstanceTemplateSpec { /** * Optional. Specification of the desired behavior of the instance. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status +optional */ spec?: Schema$InstanceSpec; } /** * IntOrString is a type that can hold an int32 or a string. When used in JSON or YAML marshalling and unmarshalling, it produces or consumes the inner type. This allows you to have, for example, a JSON field that can accept a name or number. */ export interface Schema$IntOrString { /** * The int value. */ intVal?: number | null; /** * The string value. */ strVal?: string | null; /** * The type of the value. */ type?: number | null; } /** * Job represents the configuration of a single job. A job an immutable resource that references a container image which is run to completion. */ export interface Schema$Job { /** * Optional. APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources +optional */ apiVersion?: string | null; /** * Optional. Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds +optional */ kind?: string | null; /** * Optional. Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata +optional */ metadata?: Schema$ObjectMeta; /** * Optional. Specification of the desired behavior of a job. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status +optional */ spec?: Schema$JobSpec; /** * Optional. Current status of a job. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status +optional */ status?: Schema$JobStatus; } /** * JobCondition defines a readiness condition for a Revision. */ export interface Schema$JobCondition { /** * Optional. Last time the condition transitioned from one status to another. */ lastTransitionTime?: string | null; /** * Optional. Human readable message indicating details about the current status. */ message?: string | null; /** * Optional. One-word CamelCase reason for the condition's last transition. */ reason?: string | null; /** * Optional. How to interpret failures of this condition, one of Error, Warning, Info */ severity?: string | null; /** * Required. Status of the condition, one of True, False, Unknown. */ status?: string | null; /** * Required. Type is used to communicate the status of the reconciliation process. See also: https://github.com/knative/serving/blob/master/docs/spec/errors.md#error-conditions-and-reporting Types include: * "Completed": True when the Job has successfully completed. * "Started": True when the Job has successfully started running. * "ResourcesAvailable": True when underlying resources have been provisioned. */ type?: string | null; } /** * JobSpec describes how the job execution will look like. */ export interface Schema$JobSpec { /** * Optional. Specifies the duration in seconds relative to the startTime that the job may be active before the system tries to terminate it. If set to zero, the system will never attempt to terminate the job based on time. Otherwise, the value must be positive integer. +optional */ activeDeadlineSeconds?: string | null; /** * Optional. Specifies the number of retries per instance, before marking this job failed. If set to zero, instances will never retry on failure. +optional */ backoffLimit?: number | null; /** * Optional. Specifies the desired number of successfully finished instances the job should be run with. Setting to 1 means that parallelism is limited to 1 and the success of that instance signals the success of the job. More info: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/ +optional */ completions?: number | null; /** * Optional. Specifies the maximum desired number of instances the job should run at any given time. Must be <= completions. The actual number of instances running in steady state will be less than this number when ((.spec.completions - .status.successful) < .spec.parallelism), i.e. when the work left to do is less than max parallelism. More info: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/ +optional */ parallelism?: number | null; /** * Optional. Describes the instance that will be created when executing a job. */ template?: Schema$InstanceTemplateSpec; /** * Optional. ttlSecondsAfterFinished limits the lifetime of a Job that has finished execution (either Complete or Failed). If this field is set, ttlSecondsAfterFinished after the Job finishes, it is eligible to be automatically deleted. When the Job is being deleted, its lifecycle guarantees (e.g. finalizers) will be honored. If this field is set to zero, the Job won't be automatically deleted. +optional */ ttlSecondsAfterFinished?: number | null; } /** * JobStatus represents the current state of a Job. */ export interface Schema$JobStatus { /** * Optional. The number of actively running instances. +optional */ active?: number | null; /** * Optional. Represents time when the job was completed. It is not guaranteed to be set in happens-before order across separate operations. It is represented in RFC3339 form and is in UTC. +optional */ completionTime?: string | null; /** * Optional. The latest available observations of a job's current state. More info: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/ +optional */ conditions?: Schema$JobCondition[]; /** * Optional. The number of instances which reached phase Failed. +optional */ failed?: number | null; /** * Optional. ImageDigest holds the resolved digest for the image specified within .Spec.Template.Spec.Container.Image. The digest is resolved during the creation of the Job. This field holds the digest value regardless of whether a tag or digest was originally specified in the Container object. */ imageDigest?: string | null; /** * Optional. Status of completed, failed, and running instances. +optional */ instances?: Schema$InstanceStatus[]; /** * Optional. The 'generation' of the job that was last processed by the controller. */ observedGeneration?: number | null; /** * Optional. Represents time when the job was acknowledged by the job controller. It is not guaranteed to be set in happens-before order across separate operations. It is represented in RFC3339 form and is in UTC. +optional */ startTime?: string | null; /** * Optional. The number of instances which reached phase Succeeded. +optional */ succeeded?: number | null; } /** * Maps a string key to a path within a volume. */ export interface Schema$KeyToPath { /** * The key to project. */ key?: string | null; /** * Mode bits to use on this file, must be a value between 0 and 0777. If not specified, the volume defaultMode will be used. This might be in conflict with other options that affect the file mode, like fsGroup, and the result can be other mode bits set. +optional */ mode?: number | null; /** * The relative path of the file to map the key to. May not be an absolute path. May not contain the path element '..'. May not start with the string '..'. */ path?: string | null; } /** * Lifecycle describes actions that the management system should take in response to container lifecycle events. For the PostStart and PreStop lifecycle handlers, management of the container blocks until the action is complete, unless the container process fails, in which case the handler is aborted. */ export interface Schema$Lifecycle { /** * PostStart is called immediately after a container is created. If the handler fails, the container is terminated and restarted according to its restart policy. Other management of the container blocks until the hook completes. More info: https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/#container-hooks +optional */ postStart?: Schema$Handler; /** * PreStop is called immediately before a container is terminated. The container is terminated after the handler completes. The reason for termination is passed to the handler. Regardless of the outcome of the handler, the container is eventually terminated. Other management of the container blocks until the hook completes. More info: https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/#container-hooks +optional */ preStop?: Schema$Handle