Six new resources from terraform-provider-dokploy v0.2.0 -- Network, DnsProvider, VaultProvider, Schedule, VolumeBackup and Libsql -- plus the new properties on Domain (`enabled`), Compose (`serviceNetworks`, `createEnvFile`, `icon`) and Application. Verified with `pulumi up` against a live v0.30.2 instance: create, preview-clean, and destroy. The upstream provider also now refuses a volume Mount with no `volumeName`, which Dokploy would otherwise turn into an anonymous Docker volume recreated on every deploy. That surfaces here at preview time, before anything exists. Two things made that fix nearly invisible to Pulumi users, so this commit fixes the second one: the bridge resolves the upstream `docs/` through the Go module cache, where a locally `replace`d dependency never lands, so tfgen was emitting every resource with no description at all. UpstreamRepoPath now points at the checkout and all 445 inputs carry documentation -- with names rendered per language, so Python readers see `volume_name` where TypeScript readers see `volumeName`.
201 lines
8.1 KiB
TypeScript
Generated
201 lines
8.1 KiB
TypeScript
Generated
// *** WARNING: this file was generated by pulumi-language-nodejs. ***
|
|
// *** Do not edit by hand unless you're certain you know what you are doing! ***
|
|
|
|
import * as pulumi from "@pulumi/pulumi";
|
|
import * as utilities from "./utilities";
|
|
|
|
/**
|
|
* A volume, bind mount, or config file attached to a Dokploy service.
|
|
*
|
|
* * `type = "volume"` — a named Docker volume; set `volumeName`.
|
|
* * `type = "bind"` — a path on the host; set `hostPath`.
|
|
* * `type = "file"` — a file rendered from `content`; set `filePath`.
|
|
*
|
|
* > **A `volume` mount must set `volumeName`.** Dokploy hands an unset name to Docker as an empty source, which creates a fresh anonymous volume on every deploy and orphans the previous one — the data never survives a redeploy. The provider rejects that combination at plan time.
|
|
*/
|
|
export class Mount extends pulumi.CustomResource {
|
|
/**
|
|
* Get an existing Mount 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.
|
|
*/
|
|
public static get(name: string, id: pulumi.Input<pulumi.ID>, state?: MountState, opts?: pulumi.CustomResourceOptions): Mount {
|
|
return new Mount(name, <any>state, { ...opts, id: id });
|
|
}
|
|
|
|
/** @internal */
|
|
public static readonly __pulumiType = 'dokploy:index/mount:Mount';
|
|
|
|
/**
|
|
* Returns true if the given object is an instance of Mount. This is designed to work even
|
|
* when multiple copies of the Pulumi SDK have been loaded into the same process.
|
|
*/
|
|
public static isInstance(obj: any): obj is Mount {
|
|
if (obj === undefined || obj === null) {
|
|
return false;
|
|
}
|
|
return obj['__pulumiType'] === Mount.__pulumiType;
|
|
}
|
|
|
|
/**
|
|
* Contents of the generated file, when `type` is `file`.
|
|
*/
|
|
declare public readonly content: pulumi.Output<string | undefined>;
|
|
/**
|
|
* Path of the generated file, when `type` is `file`.
|
|
*/
|
|
declare public readonly filePath: pulumi.Output<string | undefined>;
|
|
/**
|
|
* Path on the host, when `type` is `bind`.
|
|
*/
|
|
declare public readonly hostPath: pulumi.Output<string | undefined>;
|
|
/**
|
|
* Path inside the container where the mount appears.
|
|
*/
|
|
declare public readonly mountPath: pulumi.Output<string>;
|
|
/**
|
|
* ID of the service this mount attaches to. Must match `serviceType` — an application ID, a compose ID, a postgres ID, and so on.
|
|
*/
|
|
declare public readonly serviceId: pulumi.Output<string>;
|
|
/**
|
|
* The kind of service this mount attaches to. Valid values: `application`, `postgres`, `mysql`, `mariadb`, `mongo`, `redis`, `compose`, `libsql`.
|
|
*/
|
|
declare public readonly serviceType: pulumi.Output<string>;
|
|
/**
|
|
* The kind of mount to create. Valid values: `bind`, `volume`, `file`.
|
|
*/
|
|
declare public readonly type: pulumi.Output<string>;
|
|
/**
|
|
* Name of the Docker volume, when `type` is `volume`.
|
|
*/
|
|
declare public readonly volumeName: pulumi.Output<string | undefined>;
|
|
|
|
/**
|
|
* Create a Mount 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: MountArgs, opts?: pulumi.CustomResourceOptions)
|
|
constructor(name: string, argsOrState?: MountArgs | MountState, opts?: pulumi.CustomResourceOptions) {
|
|
let resourceInputs: pulumi.Inputs = {};
|
|
opts = opts || {};
|
|
if (opts.id) {
|
|
const state = argsOrState as MountState | undefined;
|
|
resourceInputs["content"] = state?.content;
|
|
resourceInputs["filePath"] = state?.filePath;
|
|
resourceInputs["hostPath"] = state?.hostPath;
|
|
resourceInputs["mountPath"] = state?.mountPath;
|
|
resourceInputs["serviceId"] = state?.serviceId;
|
|
resourceInputs["serviceType"] = state?.serviceType;
|
|
resourceInputs["type"] = state?.type;
|
|
resourceInputs["volumeName"] = state?.volumeName;
|
|
} else {
|
|
const args = argsOrState as MountArgs | undefined;
|
|
if (args?.mountPath === undefined && !opts.urn) {
|
|
throw new Error("Missing required property 'mountPath'");
|
|
}
|
|
if (args?.serviceId === undefined && !opts.urn) {
|
|
throw new Error("Missing required property 'serviceId'");
|
|
}
|
|
if (args?.serviceType === undefined && !opts.urn) {
|
|
throw new Error("Missing required property 'serviceType'");
|
|
}
|
|
if (args?.type === undefined && !opts.urn) {
|
|
throw new Error("Missing required property 'type'");
|
|
}
|
|
resourceInputs["content"] = args?.content;
|
|
resourceInputs["filePath"] = args?.filePath;
|
|
resourceInputs["hostPath"] = args?.hostPath;
|
|
resourceInputs["mountPath"] = args?.mountPath;
|
|
resourceInputs["serviceId"] = args?.serviceId;
|
|
resourceInputs["serviceType"] = args?.serviceType;
|
|
resourceInputs["type"] = args?.type;
|
|
resourceInputs["volumeName"] = args?.volumeName;
|
|
}
|
|
opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
|
|
super(Mount.__pulumiType, name, resourceInputs, opts);
|
|
}
|
|
}
|
|
|
|
/**
|
|
* Input properties used for looking up and filtering Mount resources.
|
|
*/
|
|
export interface MountState {
|
|
/**
|
|
* Contents of the generated file, when `type` is `file`.
|
|
*/
|
|
content?: pulumi.Input<string | undefined>;
|
|
/**
|
|
* Path of the generated file, when `type` is `file`.
|
|
*/
|
|
filePath?: pulumi.Input<string | undefined>;
|
|
/**
|
|
* Path on the host, when `type` is `bind`.
|
|
*/
|
|
hostPath?: pulumi.Input<string | undefined>;
|
|
/**
|
|
* Path inside the container where the mount appears.
|
|
*/
|
|
mountPath?: pulumi.Input<string | undefined>;
|
|
/**
|
|
* ID of the service this mount attaches to. Must match `serviceType` — an application ID, a compose ID, a postgres ID, and so on.
|
|
*/
|
|
serviceId?: pulumi.Input<string | undefined>;
|
|
/**
|
|
* The kind of service this mount attaches to. Valid values: `application`, `postgres`, `mysql`, `mariadb`, `mongo`, `redis`, `compose`, `libsql`.
|
|
*/
|
|
serviceType?: pulumi.Input<string | undefined>;
|
|
/**
|
|
* The kind of mount to create. Valid values: `bind`, `volume`, `file`.
|
|
*/
|
|
type?: pulumi.Input<string | undefined>;
|
|
/**
|
|
* Name of the Docker volume, when `type` is `volume`.
|
|
*/
|
|
volumeName?: pulumi.Input<string | undefined>;
|
|
}
|
|
|
|
/**
|
|
* The set of arguments for constructing a Mount resource.
|
|
*/
|
|
export interface MountArgs {
|
|
/**
|
|
* Contents of the generated file, when `type` is `file`.
|
|
*/
|
|
content?: pulumi.Input<string | undefined>;
|
|
/**
|
|
* Path of the generated file, when `type` is `file`.
|
|
*/
|
|
filePath?: pulumi.Input<string | undefined>;
|
|
/**
|
|
* Path on the host, when `type` is `bind`.
|
|
*/
|
|
hostPath?: pulumi.Input<string | undefined>;
|
|
/**
|
|
* Path inside the container where the mount appears.
|
|
*/
|
|
mountPath: pulumi.Input<string>;
|
|
/**
|
|
* ID of the service this mount attaches to. Must match `serviceType` — an application ID, a compose ID, a postgres ID, and so on.
|
|
*/
|
|
serviceId: pulumi.Input<string>;
|
|
/**
|
|
* The kind of service this mount attaches to. Valid values: `application`, `postgres`, `mysql`, `mariadb`, `mongo`, `redis`, `compose`, `libsql`.
|
|
*/
|
|
serviceType: pulumi.Input<string>;
|
|
/**
|
|
* The kind of mount to create. Valid values: `bind`, `volume`, `file`.
|
|
*/
|
|
type: pulumi.Input<string>;
|
|
/**
|
|
* Name of the Docker volume, when `type` is `volume`.
|
|
*/
|
|
volumeName?: pulumi.Input<string | undefined>;
|
|
}
|