vercel.Deployment
Explore with Pulumi AI
Create Deployment Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new Deployment(name: string, args: DeploymentArgs, opts?: CustomResourceOptions);
@overload
def Deployment(resource_name: str,
args: DeploymentArgs,
opts: Optional[ResourceOptions] = None)
@overload
def Deployment(resource_name: str,
opts: Optional[ResourceOptions] = None,
project_id: Optional[str] = None,
delete_on_destroy: Optional[bool] = None,
environment: Optional[Mapping[str, str]] = None,
files: Optional[Mapping[str, str]] = None,
path_prefix: Optional[str] = None,
production: Optional[bool] = None,
project_settings: Optional[DeploymentProjectSettingsArgs] = None,
ref: Optional[str] = None,
team_id: Optional[str] = None)
func NewDeployment(ctx *Context, name string, args DeploymentArgs, opts ...ResourceOption) (*Deployment, error)
public Deployment(string name, DeploymentArgs args, CustomResourceOptions? opts = null)
public Deployment(String name, DeploymentArgs args)
public Deployment(String name, DeploymentArgs args, CustomResourceOptions options)
type: vercel:Deployment
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args DeploymentArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args DeploymentArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args DeploymentArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args DeploymentArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args DeploymentArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Constructor example
The following reference example uses placeholder values for all input properties.
var deploymentResource = new Vercel.Deployment("deploymentResource", new()
{
ProjectId = "string",
DeleteOnDestroy = false,
Environment =
{
{ "string", "string" },
},
Files =
{
{ "string", "string" },
},
PathPrefix = "string",
Production = false,
ProjectSettings = new Vercel.Inputs.DeploymentProjectSettingsArgs
{
BuildCommand = "string",
Framework = "string",
InstallCommand = "string",
OutputDirectory = "string",
RootDirectory = "string",
},
Ref = "string",
TeamId = "string",
});
example, err := vercel.NewDeployment(ctx, "deploymentResource", &vercel.DeploymentArgs{
ProjectId: pulumi.String("string"),
DeleteOnDestroy: pulumi.Bool(false),
Environment: pulumi.StringMap{
"string": pulumi.String("string"),
},
Files: pulumi.StringMap{
"string": pulumi.String("string"),
},
PathPrefix: pulumi.String("string"),
Production: pulumi.Bool(false),
ProjectSettings: &vercel.DeploymentProjectSettingsArgs{
BuildCommand: pulumi.String("string"),
Framework: pulumi.String("string"),
InstallCommand: pulumi.String("string"),
OutputDirectory: pulumi.String("string"),
RootDirectory: pulumi.String("string"),
},
Ref: pulumi.String("string"),
TeamId: pulumi.String("string"),
})
var deploymentResource = new Deployment("deploymentResource", DeploymentArgs.builder()
.projectId("string")
.deleteOnDestroy(false)
.environment(Map.of("string", "string"))
.files(Map.of("string", "string"))
.pathPrefix("string")
.production(false)
.projectSettings(DeploymentProjectSettingsArgs.builder()
.buildCommand("string")
.framework("string")
.installCommand("string")
.outputDirectory("string")
.rootDirectory("string")
.build())
.ref("string")
.teamId("string")
.build());
deployment_resource = vercel.Deployment("deploymentResource",
project_id="string",
delete_on_destroy=False,
environment={
"string": "string",
},
files={
"string": "string",
},
path_prefix="string",
production=False,
project_settings={
"build_command": "string",
"framework": "string",
"install_command": "string",
"output_directory": "string",
"root_directory": "string",
},
ref="string",
team_id="string")
const deploymentResource = new vercel.Deployment("deploymentResource", {
projectId: "string",
deleteOnDestroy: false,
environment: {
string: "string",
},
files: {
string: "string",
},
pathPrefix: "string",
production: false,
projectSettings: {
buildCommand: "string",
framework: "string",
installCommand: "string",
outputDirectory: "string",
rootDirectory: "string",
},
ref: "string",
teamId: "string",
});
type: vercel:Deployment
properties:
deleteOnDestroy: false
environment:
string: string
files:
string: string
pathPrefix: string
production: false
projectId: string
projectSettings:
buildCommand: string
framework: string
installCommand: string
outputDirectory: string
rootDirectory: string
ref: string
teamId: string
Deployment Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The Deployment resource accepts the following input properties:
- Project
Id string - The project ID to add the deployment to.
- Delete
On boolDestroy - Environment Dictionary<string, string>
- A map of environment variable names to values. These are specific to a Deployment, and can also be configured on the
vercel.Project
resource. - Files Dictionary<string, string>
- A map of files to be uploaded for the deployment. This should be provided by a
vercel.getProjectDirectory
orvercel.getFile
data source. Required ifgit_source
is not set. - Path
Prefix string - If specified then the
path_prefix
will be stripped from the start of file paths as they are uploaded to Vercel. If this is omitted, then any leading../
s will be stripped. - Production bool
- true if the deployment is a production deployment, meaning production aliases will be assigned.
- Project
Settings Pulumiverse.Vercel. Inputs. Deployment Project Settings - Project settings that will be applied to the deployment.
- Ref string
- The branch or commit hash that should be deployed. Note this will only work if the project is configured to use a Git repository. Required if
files
is not set. - Team
Id string - The team ID to add the deployment to. Required when configuring a team resource if a default team has not been set in the provider.
- Project
Id string - The project ID to add the deployment to.
- Delete
On boolDestroy - Environment map[string]string
- A map of environment variable names to values. These are specific to a Deployment, and can also be configured on the
vercel.Project
resource. - Files map[string]string
- A map of files to be uploaded for the deployment. This should be provided by a
vercel.getProjectDirectory
orvercel.getFile
data source. Required ifgit_source
is not set. - Path
Prefix string - If specified then the
path_prefix
will be stripped from the start of file paths as they are uploaded to Vercel. If this is omitted, then any leading../
s will be stripped. - Production bool
- true if the deployment is a production deployment, meaning production aliases will be assigned.
- Project
Settings DeploymentProject Settings Args - Project settings that will be applied to the deployment.
- Ref string
- The branch or commit hash that should be deployed. Note this will only work if the project is configured to use a Git repository. Required if
files
is not set. - Team
Id string - The team ID to add the deployment to. Required when configuring a team resource if a default team has not been set in the provider.
- project
Id String - The project ID to add the deployment to.
- delete
On BooleanDestroy - environment Map<String,String>
- A map of environment variable names to values. These are specific to a Deployment, and can also be configured on the
vercel.Project
resource. - files Map<String,String>
- A map of files to be uploaded for the deployment. This should be provided by a
vercel.getProjectDirectory
orvercel.getFile
data source. Required ifgit_source
is not set. - path
Prefix String - If specified then the
path_prefix
will be stripped from the start of file paths as they are uploaded to Vercel. If this is omitted, then any leading../
s will be stripped. - production Boolean
- true if the deployment is a production deployment, meaning production aliases will be assigned.
- project
Settings DeploymentProject Settings - Project settings that will be applied to the deployment.
- ref String
- The branch or commit hash that should be deployed. Note this will only work if the project is configured to use a Git repository. Required if
files
is not set. - team
Id String - The team ID to add the deployment to. Required when configuring a team resource if a default team has not been set in the provider.
- project
Id string - The project ID to add the deployment to.
- delete
On booleanDestroy - environment {[key: string]: string}
- A map of environment variable names to values. These are specific to a Deployment, and can also be configured on the
vercel.Project
resource. - files {[key: string]: string}
- A map of files to be uploaded for the deployment. This should be provided by a
vercel.getProjectDirectory
orvercel.getFile
data source. Required ifgit_source
is not set. - path
Prefix string - If specified then the
path_prefix
will be stripped from the start of file paths as they are uploaded to Vercel. If this is omitted, then any leading../
s will be stripped. - production boolean
- true if the deployment is a production deployment, meaning production aliases will be assigned.
- project
Settings DeploymentProject Settings - Project settings that will be applied to the deployment.
- ref string
- The branch or commit hash that should be deployed. Note this will only work if the project is configured to use a Git repository. Required if
files
is not set. - team
Id string - The team ID to add the deployment to. Required when configuring a team resource if a default team has not been set in the provider.
- project_
id str - The project ID to add the deployment to.
- delete_
on_ booldestroy - environment Mapping[str, str]
- A map of environment variable names to values. These are specific to a Deployment, and can also be configured on the
vercel.Project
resource. - files Mapping[str, str]
- A map of files to be uploaded for the deployment. This should be provided by a
vercel.getProjectDirectory
orvercel.getFile
data source. Required ifgit_source
is not set. - path_
prefix str - If specified then the
path_prefix
will be stripped from the start of file paths as they are uploaded to Vercel. If this is omitted, then any leading../
s will be stripped. - production bool
- true if the deployment is a production deployment, meaning production aliases will be assigned.
- project_
settings DeploymentProject Settings Args - Project settings that will be applied to the deployment.
- ref str
- The branch or commit hash that should be deployed. Note this will only work if the project is configured to use a Git repository. Required if
files
is not set. - team_
id str - The team ID to add the deployment to. Required when configuring a team resource if a default team has not been set in the provider.
- project
Id String - The project ID to add the deployment to.
- delete
On BooleanDestroy - environment Map<String>
- A map of environment variable names to values. These are specific to a Deployment, and can also be configured on the
vercel.Project
resource. - files Map<String>
- A map of files to be uploaded for the deployment. This should be provided by a
vercel.getProjectDirectory
orvercel.getFile
data source. Required ifgit_source
is not set. - path
Prefix String - If specified then the
path_prefix
will be stripped from the start of file paths as they are uploaded to Vercel. If this is omitted, then any leading../
s will be stripped. - production Boolean
- true if the deployment is a production deployment, meaning production aliases will be assigned.
- project
Settings Property Map - Project settings that will be applied to the deployment.
- ref String
- The branch or commit hash that should be deployed. Note this will only work if the project is configured to use a Git repository. Required if
files
is not set. - team
Id String - The team ID to add the deployment to. Required when configuring a team resource if a default team has not been set in the provider.
Outputs
All input properties are implicitly available as output properties. Additionally, the Deployment resource produces the following output properties:
Look up Existing Deployment Resource
Get an existing Deployment resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: DeploymentState, opts?: CustomResourceOptions): Deployment
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
delete_on_destroy: Optional[bool] = None,
domains: Optional[Sequence[str]] = None,
environment: Optional[Mapping[str, str]] = None,
files: Optional[Mapping[str, str]] = None,
path_prefix: Optional[str] = None,
production: Optional[bool] = None,
project_id: Optional[str] = None,
project_settings: Optional[DeploymentProjectSettingsArgs] = None,
ref: Optional[str] = None,
team_id: Optional[str] = None,
url: Optional[str] = None) -> Deployment
func GetDeployment(ctx *Context, name string, id IDInput, state *DeploymentState, opts ...ResourceOption) (*Deployment, error)
public static Deployment Get(string name, Input<string> id, DeploymentState? state, CustomResourceOptions? opts = null)
public static Deployment get(String name, Output<String> id, DeploymentState state, CustomResourceOptions options)
Resource lookup is not supported in YAML
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- Delete
On boolDestroy - Domains List<string>
- A list of all the domains (default domains, staging domains and production domains) that were assigned upon deployment creation.
- Environment Dictionary<string, string>
- A map of environment variable names to values. These are specific to a Deployment, and can also be configured on the
vercel.Project
resource. - Files Dictionary<string, string>
- A map of files to be uploaded for the deployment. This should be provided by a
vercel.getProjectDirectory
orvercel.getFile
data source. Required ifgit_source
is not set. - Path
Prefix string - If specified then the
path_prefix
will be stripped from the start of file paths as they are uploaded to Vercel. If this is omitted, then any leading../
s will be stripped. - Production bool
- true if the deployment is a production deployment, meaning production aliases will be assigned.
- Project
Id string - The project ID to add the deployment to.
- Project
Settings Pulumiverse.Vercel. Inputs. Deployment Project Settings - Project settings that will be applied to the deployment.
- Ref string
- The branch or commit hash that should be deployed. Note this will only work if the project is configured to use a Git repository. Required if
files
is not set. - Team
Id string - The team ID to add the deployment to. Required when configuring a team resource if a default team has not been set in the provider.
- Url string
- A unique URL that is automatically generated for a deployment.
- Delete
On boolDestroy - Domains []string
- A list of all the domains (default domains, staging domains and production domains) that were assigned upon deployment creation.
- Environment map[string]string
- A map of environment variable names to values. These are specific to a Deployment, and can also be configured on the
vercel.Project
resource. - Files map[string]string
- A map of files to be uploaded for the deployment. This should be provided by a
vercel.getProjectDirectory
orvercel.getFile
data source. Required ifgit_source
is not set. - Path
Prefix string - If specified then the
path_prefix
will be stripped from the start of file paths as they are uploaded to Vercel. If this is omitted, then any leading../
s will be stripped. - Production bool
- true if the deployment is a production deployment, meaning production aliases will be assigned.
- Project
Id string - The project ID to add the deployment to.
- Project
Settings DeploymentProject Settings Args - Project settings that will be applied to the deployment.
- Ref string
- The branch or commit hash that should be deployed. Note this will only work if the project is configured to use a Git repository. Required if
files
is not set. - Team
Id string - The team ID to add the deployment to. Required when configuring a team resource if a default team has not been set in the provider.
- Url string
- A unique URL that is automatically generated for a deployment.
- delete
On BooleanDestroy - domains List<String>
- A list of all the domains (default domains, staging domains and production domains) that were assigned upon deployment creation.
- environment Map<String,String>
- A map of environment variable names to values. These are specific to a Deployment, and can also be configured on the
vercel.Project
resource. - files Map<String,String>
- A map of files to be uploaded for the deployment. This should be provided by a
vercel.getProjectDirectory
orvercel.getFile
data source. Required ifgit_source
is not set. - path
Prefix String - If specified then the
path_prefix
will be stripped from the start of file paths as they are uploaded to Vercel. If this is omitted, then any leading../
s will be stripped. - production Boolean
- true if the deployment is a production deployment, meaning production aliases will be assigned.
- project
Id String - The project ID to add the deployment to.
- project
Settings DeploymentProject Settings - Project settings that will be applied to the deployment.
- ref String
- The branch or commit hash that should be deployed. Note this will only work if the project is configured to use a Git repository. Required if
files
is not set. - team
Id String - The team ID to add the deployment to. Required when configuring a team resource if a default team has not been set in the provider.
- url String
- A unique URL that is automatically generated for a deployment.
- delete
On booleanDestroy - domains string[]
- A list of all the domains (default domains, staging domains and production domains) that were assigned upon deployment creation.
- environment {[key: string]: string}
- A map of environment variable names to values. These are specific to a Deployment, and can also be configured on the
vercel.Project
resource. - files {[key: string]: string}
- A map of files to be uploaded for the deployment. This should be provided by a
vercel.getProjectDirectory
orvercel.getFile
data source. Required ifgit_source
is not set. - path
Prefix string - If specified then the
path_prefix
will be stripped from the start of file paths as they are uploaded to Vercel. If this is omitted, then any leading../
s will be stripped. - production boolean
- true if the deployment is a production deployment, meaning production aliases will be assigned.
- project
Id string - The project ID to add the deployment to.
- project
Settings DeploymentProject Settings - Project settings that will be applied to the deployment.
- ref string
- The branch or commit hash that should be deployed. Note this will only work if the project is configured to use a Git repository. Required if
files
is not set. - team
Id string - The team ID to add the deployment to. Required when configuring a team resource if a default team has not been set in the provider.
- url string
- A unique URL that is automatically generated for a deployment.
- delete_
on_ booldestroy - domains Sequence[str]
- A list of all the domains (default domains, staging domains and production domains) that were assigned upon deployment creation.
- environment Mapping[str, str]
- A map of environment variable names to values. These are specific to a Deployment, and can also be configured on the
vercel.Project
resource. - files Mapping[str, str]
- A map of files to be uploaded for the deployment. This should be provided by a
vercel.getProjectDirectory
orvercel.getFile
data source. Required ifgit_source
is not set. - path_
prefix str - If specified then the
path_prefix
will be stripped from the start of file paths as they are uploaded to Vercel. If this is omitted, then any leading../
s will be stripped. - production bool
- true if the deployment is a production deployment, meaning production aliases will be assigned.
- project_
id str - The project ID to add the deployment to.
- project_
settings DeploymentProject Settings Args - Project settings that will be applied to the deployment.
- ref str
- The branch or commit hash that should be deployed. Note this will only work if the project is configured to use a Git repository. Required if
files
is not set. - team_
id str - The team ID to add the deployment to. Required when configuring a team resource if a default team has not been set in the provider.
- url str
- A unique URL that is automatically generated for a deployment.
- delete
On BooleanDestroy - domains List<String>
- A list of all the domains (default domains, staging domains and production domains) that were assigned upon deployment creation.
- environment Map<String>
- A map of environment variable names to values. These are specific to a Deployment, and can also be configured on the
vercel.Project
resource. - files Map<String>
- A map of files to be uploaded for the deployment. This should be provided by a
vercel.getProjectDirectory
orvercel.getFile
data source. Required ifgit_source
is not set. - path
Prefix String - If specified then the
path_prefix
will be stripped from the start of file paths as they are uploaded to Vercel. If this is omitted, then any leading../
s will be stripped. - production Boolean
- true if the deployment is a production deployment, meaning production aliases will be assigned.
- project
Id String - The project ID to add the deployment to.
- project
Settings Property Map - Project settings that will be applied to the deployment.
- ref String
- The branch or commit hash that should be deployed. Note this will only work if the project is configured to use a Git repository. Required if
files
is not set. - team
Id String - The team ID to add the deployment to. Required when configuring a team resource if a default team has not been set in the provider.
- url String
- A unique URL that is automatically generated for a deployment.
Supporting Types
DeploymentProjectSettings, DeploymentProjectSettingsArgs
- Build
Command string - The build command for this deployment. If omitted, this value will be taken from the project or automatically detected.
- Framework string
- The framework that is being used for this deployment. If omitted, no framework is selected.
- Install
Command string - The install command for this deployment. If omitted, this value will be taken from the project or automatically detected.
- Output
Directory string - The output directory of the deployment. If omitted, this value will be taken from the project or automatically detected.
- Root
Directory string - The name of a directory or relative path to the source code of your project. When null is used it will default to the project root.
- Build
Command string - The build command for this deployment. If omitted, this value will be taken from the project or automatically detected.
- Framework string
- The framework that is being used for this deployment. If omitted, no framework is selected.
- Install
Command string - The install command for this deployment. If omitted, this value will be taken from the project or automatically detected.
- Output
Directory string - The output directory of the deployment. If omitted, this value will be taken from the project or automatically detected.
- Root
Directory string - The name of a directory or relative path to the source code of your project. When null is used it will default to the project root.
- build
Command String - The build command for this deployment. If omitted, this value will be taken from the project or automatically detected.
- framework String
- The framework that is being used for this deployment. If omitted, no framework is selected.
- install
Command String - The install command for this deployment. If omitted, this value will be taken from the project or automatically detected.
- output
Directory String - The output directory of the deployment. If omitted, this value will be taken from the project or automatically detected.
- root
Directory String - The name of a directory or relative path to the source code of your project. When null is used it will default to the project root.
- build
Command string - The build command for this deployment. If omitted, this value will be taken from the project or automatically detected.
- framework string
- The framework that is being used for this deployment. If omitted, no framework is selected.
- install
Command string - The install command for this deployment. If omitted, this value will be taken from the project or automatically detected.
- output
Directory string - The output directory of the deployment. If omitted, this value will be taken from the project or automatically detected.
- root
Directory string - The name of a directory or relative path to the source code of your project. When null is used it will default to the project root.
- build_
command str - The build command for this deployment. If omitted, this value will be taken from the project or automatically detected.
- framework str
- The framework that is being used for this deployment. If omitted, no framework is selected.
- install_
command str - The install command for this deployment. If omitted, this value will be taken from the project or automatically detected.
- output_
directory str - The output directory of the deployment. If omitted, this value will be taken from the project or automatically detected.
- root_
directory str - The name of a directory or relative path to the source code of your project. When null is used it will default to the project root.
- build
Command String - The build command for this deployment. If omitted, this value will be taken from the project or automatically detected.
- framework String
- The framework that is being used for this deployment. If omitted, no framework is selected.
- install
Command String - The install command for this deployment. If omitted, this value will be taken from the project or automatically detected.
- output
Directory String - The output directory of the deployment. If omitted, this value will be taken from the project or automatically detected.
- root
Directory String - The name of a directory or relative path to the source code of your project. When null is used it will default to the project root.
Package Details
- Repository
- vercel pulumiverse/pulumi-vercel
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
vercel
Terraform Provider.