@pulumi/openstack
Version:
A Pulumi package for creating and managing OpenStack cloud resources.
271 lines (270 loc) • 9.13 kB
TypeScript
import * as pulumi from "@pulumi/pulumi";
import * as inputs from "../types/input";
import * as outputs from "../types/output";
/**
* Manages a V1 Barbican container resource within OpenStack.
*
* ## Example Usage
*
* ### Simple container
*
* A container with the TLS certificates.
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as openstack from "@pulumi/openstack";
* import * as std from "@pulumi/std";
*
* const certificate1 = new openstack.keymanager.SecretV1("certificate_1", {
* name: "certificate",
* payload: std.file({
* input: "cert.pem",
* }).then(invoke => invoke.result),
* secretType: "certificate",
* payloadContentType: "text/plain",
* });
* const privateKey1 = new openstack.keymanager.SecretV1("private_key_1", {
* name: "private_key",
* payload: std.file({
* input: "cert-key.pem",
* }).then(invoke => invoke.result),
* secretType: "private",
* payloadContentType: "text/plain",
* });
* const intermediate1 = new openstack.keymanager.SecretV1("intermediate_1", {
* name: "intermediate",
* payload: std.file({
* input: "intermediate-ca.pem",
* }).then(invoke => invoke.result),
* secretType: "certificate",
* payloadContentType: "text/plain",
* });
* const tls1 = new openstack.keymanager.ContainerV1("tls_1", {
* name: "tls",
* type: "certificate",
* secretRefs: [
* {
* name: "certificate",
* secretRef: certificate1.secretRef,
* },
* {
* name: "private_key",
* secretRef: privateKey1.secretRef,
* },
* {
* name: "intermediates",
* secretRef: intermediate1.secretRef,
* },
* ],
* });
* ```
*
* ### Container with the ACL
*
* > **Note** Only read ACLs are supported
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as openstack from "@pulumi/openstack";
*
* const tls1 = new openstack.keymanager.ContainerV1("tls_1", {
* name: "tls",
* type: "certificate",
* secretRefs: [
* {
* name: "certificate",
* secretRef: certificate1.secretRef,
* },
* {
* name: "private_key",
* secretRef: privateKey1.secretRef,
* },
* {
* name: "intermediates",
* secretRef: intermediate1.secretRef,
* },
* ],
* acl: {
* read: {
* projectAccess: false,
* users: [
* "userid1",
* "userid2",
* ],
* },
* },
* });
* ```
*
* ## Import
*
* Containers can be imported using the container id (the last part of the container reference), e.g.:
*
* ```sh
* $ pulumi import openstack:keymanager/containerV1:ContainerV1 container_1 0c6cd26a-c012-4d7b-8034-057c0f1c2953
* ```
*/
export declare class ContainerV1 extends pulumi.CustomResource {
/**
* Get an existing ContainerV1 resource's state with the given name, ID, and optional extra
* properties used to qualify the lookup.
*
* @param name The _unique_ name of the resulting resource.
* @param id The _unique_ provider ID of the resource to lookup.
* @param state Any extra arguments used during the lookup.
* @param opts Optional settings to control the behavior of the CustomResource.
*/
static get(name: string, id: pulumi.Input<pulumi.ID>, state?: ContainerV1State, opts?: pulumi.CustomResourceOptions): ContainerV1;
/**
* Returns true if the given object is an instance of ContainerV1. This is designed to work even
* when multiple copies of the Pulumi SDK have been loaded into the same process.
*/
static isInstance(obj: any): obj is ContainerV1;
/**
* Allows to control an access to a container. Currently only
* the `read` operation is supported. If not specified, the container is
* accessible project wide. The `read` structure is described below.
*/
readonly acl: pulumi.Output<outputs.keymanager.ContainerV1Acl>;
/**
* The list of the container consumers. The structure is described below.
*/
readonly consumers: pulumi.Output<outputs.keymanager.ContainerV1Consumer[]>;
/**
* The container reference / where to find the container.
*/
readonly containerRef: pulumi.Output<string>;
/**
* The date the container was created.
*/
readonly createdAt: pulumi.Output<string>;
/**
* The creator of the container.
*/
readonly creatorId: pulumi.Output<string>;
/**
* Human-readable name for the Container. Does not have
* to be unique.
*/
readonly name: pulumi.Output<string>;
/**
* The region in which to obtain the V1 KeyManager client.
* A KeyManager client is needed to create a container. If omitted, the
* `region` argument of the provider is used. Changing this creates a new
* V1 container.
*/
readonly region: pulumi.Output<string>;
/**
* A set of dictionaries containing references to secrets. The structure is described
* below.
*/
readonly secretRefs: pulumi.Output<outputs.keymanager.ContainerV1SecretRef[] | undefined>;
/**
* The status of the container.
*/
readonly status: pulumi.Output<string>;
/**
* Used to indicate the type of container. Must be one of `generic`, `rsa` or `certificate`.
*/
readonly type: pulumi.Output<string>;
/**
* The date the container was last updated.
*/
readonly updatedAt: pulumi.Output<string>;
/**
* Create a ContainerV1 resource with the given unique name, arguments, and options.
*
* @param name The _unique_ name of the resource.
* @param args The arguments to use to populate this resource's properties.
* @param opts A bag of options that control this resource's behavior.
*/
constructor(name: string, args: ContainerV1Args, opts?: pulumi.CustomResourceOptions);
}
/**
* Input properties used for looking up and filtering ContainerV1 resources.
*/
export interface ContainerV1State {
/**
* Allows to control an access to a container. Currently only
* the `read` operation is supported. If not specified, the container is
* accessible project wide. The `read` structure is described below.
*/
acl?: pulumi.Input<inputs.keymanager.ContainerV1Acl>;
/**
* The list of the container consumers. The structure is described below.
*/
consumers?: pulumi.Input<pulumi.Input<inputs.keymanager.ContainerV1Consumer>[]>;
/**
* The container reference / where to find the container.
*/
containerRef?: pulumi.Input<string>;
/**
* The date the container was created.
*/
createdAt?: pulumi.Input<string>;
/**
* The creator of the container.
*/
creatorId?: pulumi.Input<string>;
/**
* Human-readable name for the Container. Does not have
* to be unique.
*/
name?: pulumi.Input<string>;
/**
* The region in which to obtain the V1 KeyManager client.
* A KeyManager client is needed to create a container. If omitted, the
* `region` argument of the provider is used. Changing this creates a new
* V1 container.
*/
region?: pulumi.Input<string>;
/**
* A set of dictionaries containing references to secrets. The structure is described
* below.
*/
secretRefs?: pulumi.Input<pulumi.Input<inputs.keymanager.ContainerV1SecretRef>[]>;
/**
* The status of the container.
*/
status?: pulumi.Input<string>;
/**
* Used to indicate the type of container. Must be one of `generic`, `rsa` or `certificate`.
*/
type?: pulumi.Input<string>;
/**
* The date the container was last updated.
*/
updatedAt?: pulumi.Input<string>;
}
/**
* The set of arguments for constructing a ContainerV1 resource.
*/
export interface ContainerV1Args {
/**
* Allows to control an access to a container. Currently only
* the `read` operation is supported. If not specified, the container is
* accessible project wide. The `read` structure is described below.
*/
acl?: pulumi.Input<inputs.keymanager.ContainerV1Acl>;
/**
* Human-readable name for the Container. Does not have
* to be unique.
*/
name?: pulumi.Input<string>;
/**
* The region in which to obtain the V1 KeyManager client.
* A KeyManager client is needed to create a container. If omitted, the
* `region` argument of the provider is used. Changing this creates a new
* V1 container.
*/
region?: pulumi.Input<string>;
/**
* A set of dictionaries containing references to secrets. The structure is described
* below.
*/
secretRefs?: pulumi.Input<pulumi.Input<inputs.keymanager.ContainerV1SecretRef>[]>;
/**
* Used to indicate the type of container. Must be one of `generic`, `rsa` or `certificate`.
*/
type: pulumi.Input<string>;
}