@spacelift-io/pulumi-spacelift
Version:
A Pulumi package for creating and managing Spacelift resources.
129 lines (128 loc) • 4.11 kB
TypeScript
import * as pulumi from "@pulumi/pulumi";
/**
* `spacelift.Mountedfile` represents a file mounted in each Run's workspace that is part of a configuration of a context (`spacelift.Context`), stack (`spacelift.Stack`) or a module (`spacelift.Module`). In principle, it's very similar to an environment variable (`spacelift.EnvironmentVariable`) except that the value is written to the filesystem rather than passed to the environment.
*
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as spacelift from "@pulumi/spacelift";
*
* const ireland-kubeconfig = spacelift.getMountedfile({
* contextId: "prod-k8s-ie",
* relativePath: "kubeconfig",
* });
* const module-kubeconfig = spacelift.getMountedfile({
* moduleId: "k8s-module",
* relativePath: "kubeconfig",
* });
* const core-kubeconfig = spacelift.getMountedfile({
* relativePath: "kubeconfig",
* stackId: "k8s-core",
* });
* ```
*/
export declare function getMountedfile(args: GetMountedfileArgs, opts?: pulumi.InvokeOptions): Promise<GetMountedfileResult>;
/**
* A collection of arguments for invoking getMountedfile.
*/
export interface GetMountedfileArgs {
/**
* ID of the context where the mounted file is stored
*/
contextId?: string;
/**
* ID of the module where the mounted file is stored
*/
moduleId?: string;
/**
* relative path to the mounted file
*/
relativePath: string;
/**
* ID of the stack where the mounted file is stored
*/
stackId?: string;
}
/**
* A collection of values returned by getMountedfile.
*/
export interface GetMountedfileResult {
/**
* SHA-256 checksum of the value
*/
readonly checksum: string;
/**
* content of the mounted file encoded using Base-64
*/
readonly content: string;
/**
* ID of the context where the mounted file is stored
*/
readonly contextId?: string;
/**
* The provider-assigned unique ID for this managed resource.
*/
readonly id: string;
/**
* ID of the module where the mounted file is stored
*/
readonly moduleId?: string;
/**
* relative path to the mounted file
*/
readonly relativePath: string;
/**
* ID of the stack where the mounted file is stored
*/
readonly stackId?: string;
/**
* indicates whether the value can be read back outside a Run
*/
readonly writeOnly: boolean;
}
/**
* `spacelift.Mountedfile` represents a file mounted in each Run's workspace that is part of a configuration of a context (`spacelift.Context`), stack (`spacelift.Stack`) or a module (`spacelift.Module`). In principle, it's very similar to an environment variable (`spacelift.EnvironmentVariable`) except that the value is written to the filesystem rather than passed to the environment.
*
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as spacelift from "@pulumi/spacelift";
*
* const ireland-kubeconfig = spacelift.getMountedfile({
* contextId: "prod-k8s-ie",
* relativePath: "kubeconfig",
* });
* const module-kubeconfig = spacelift.getMountedfile({
* moduleId: "k8s-module",
* relativePath: "kubeconfig",
* });
* const core-kubeconfig = spacelift.getMountedfile({
* relativePath: "kubeconfig",
* stackId: "k8s-core",
* });
* ```
*/
export declare function getMountedfileOutput(args: GetMountedfileOutputArgs, opts?: pulumi.InvokeOptions): pulumi.Output<GetMountedfileResult>;
/**
* A collection of arguments for invoking getMountedfile.
*/
export interface GetMountedfileOutputArgs {
/**
* ID of the context where the mounted file is stored
*/
contextId?: pulumi.Input<string>;
/**
* ID of the module where the mounted file is stored
*/
moduleId?: pulumi.Input<string>;
/**
* relative path to the mounted file
*/
relativePath: pulumi.Input<string>;
/**
* ID of the stack where the mounted file is stored
*/
stackId?: pulumi.Input<string>;
}