octopusdeploy.DeploymentFreeze
Explore with Pulumi AI
Example Usage
Coming soon!
Coming soon!
Coming soon!
Coming soon!
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.octopusdeploy.DeploymentFreeze;
import com.pulumi.octopusdeploy.DeploymentFreezeArgs;
import com.pulumi.octopusdeploy.inputs.DeploymentFreezeRecurringScheduleArgs;
import com.pulumi.octopusdeploy.DeploymentFreezeProject;
import com.pulumi.octopusdeploy.DeploymentFreezeProjectArgs;
import com.pulumi.octopusdeploy.DeploymentFreezeTenant;
import com.pulumi.octopusdeploy.DeploymentFreezeTenantArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
// basic freeze with no project scopes
var freezeDeploymentFreeze = new DeploymentFreeze("freezeDeploymentFreeze", DeploymentFreezeArgs.builder()
.start("2024-12-25T00:00:00+10:00")
.end("2024-12-27T00:00:00+08:00")
.build());
// Freeze with different timezones and single project/environment scope
var freezeIndex_deploymentFreezeDeploymentFreeze = new DeploymentFreeze("freezeIndex/deploymentFreezeDeploymentFreeze", DeploymentFreezeArgs.builder()
.start("2024-12-25T00:00:00+10:00")
.end("2024-12-27T00:00:00+08:00")
.build());
// Freeze recurring freeze yearly on Xmas
var freezeOctopusdeployIndex_deploymentFreezeDeploymentFreeze = new DeploymentFreeze("freezeOctopusdeployIndex/deploymentFreezeDeploymentFreeze", DeploymentFreezeArgs.builder()
.start("2024-12-25T00:00:00+10:00")
.end("2024-12-27T00:00:00+08:00")
.recurringSchedule(DeploymentFreezeRecurringScheduleArgs.builder()
.type("Annually")
.unit(1)
.end_type("Never")
.build())
.build());
var projectFreezeDeploymentFreezeProject = new DeploymentFreezeProject("projectFreezeDeploymentFreezeProject", DeploymentFreezeProjectArgs.builder()
.deploymentfreezeId(freezeDeploymentFreeze.id())
.projectId("Projects-123")
.environmentIds(
"Environments-123",
"Environments-456")
.build());
// Freeze with ids sourced from resources and datasources. Projects can be sourced from different spaces, a single scope can only reference projects and environments from the same space.
var freezeOctopusdeployIndex_deploymentFreezeDeploymentFreeze1 = new DeploymentFreeze("freezeOctopusdeployIndex/deploymentFreezeDeploymentFreeze1", DeploymentFreezeArgs.builder()
.start("2025-06-30T00:00:00+10:00")
.end("2025-07-02T00:00:00+10:00")
.build());
var projectFreezeIndex_deploymentFreezeProjectDeploymentFreezeProject = new DeploymentFreezeProject("projectFreezeIndex/deploymentFreezeProjectDeploymentFreezeProject", DeploymentFreezeProjectArgs.builder()
.deploymentfreezeId(freezeDeploymentFreeze.id())
.projectId(resource.octopusdeploy_project().project1().id())
.environmentIds(resource.octopusdeploy_environment().production().id())
.build());
var projectFreezeOctopusdeployIndex_deploymentFreezeProjectDeploymentFreezeProject = new DeploymentFreezeProject("projectFreezeOctopusdeployIndex/deploymentFreezeProjectDeploymentFreezeProject", DeploymentFreezeProjectArgs.builder()
.deploymentfreezeId(freezeDeploymentFreeze.id())
.projectId(data.octopusdeploy_projects().second_project().projects()[0].id())
.environmentIds(data.octopusdeploy_environments().default_environment().environments()[0].id())
.build());
var tenantFreeze = new DeploymentFreezeTenant("tenantFreeze", DeploymentFreezeTenantArgs.builder()
.deploymentfreezeId(freezeDeploymentFreeze.id())
.tenantId("Tenants-1")
.projectId("Projects-1")
.environmentId("Environments-1")
.build());
}
}
resources:
# basic freeze with no project scopes
freezeDeploymentFreeze:
type: octopusdeploy:DeploymentFreeze
properties:
start: 2024-12-25T00:00:00+10:00
end: 2024-12-27T00:00:00+08:00
# Freeze with different timezones and single project/environment scope
freezeIndex/deploymentFreezeDeploymentFreeze:
type: octopusdeploy:DeploymentFreeze
properties:
start: 2024-12-25T00:00:00+10:00
end: 2024-12-27T00:00:00+08:00
# Freeze recurring freeze yearly on Xmas
freezeOctopusdeployIndex/deploymentFreezeDeploymentFreeze:
type: octopusdeploy:DeploymentFreeze
properties:
start: 2024-12-25T00:00:00+10:00
end: 2024-12-27T00:00:00+08:00
recurringSchedule:
type: Annually
unit: 1
end_type: Never
projectFreezeDeploymentFreezeProject:
type: octopusdeploy:DeploymentFreezeProject
properties:
deploymentfreezeId: ${freezeDeploymentFreeze.id}
projectId: Projects-123
environmentIds:
- Environments-123
- Environments-456
# Freeze with ids sourced from resources and datasources. Projects can be sourced from different spaces, a single scope can only reference projects and environments from the same space.
freezeOctopusdeployIndex/deploymentFreezeDeploymentFreeze1:
type: octopusdeploy:DeploymentFreeze
properties:
start: 2025-06-30T00:00:00+10:00
end: 2025-07-02T00:00:00+10:00
projectFreezeIndex/deploymentFreezeProjectDeploymentFreezeProject:
type: octopusdeploy:DeploymentFreezeProject
properties:
deploymentfreezeId: ${freezeDeploymentFreeze.id}
projectId: ${resource.octopusdeploy_project.project1.id}
environmentIds:
- ${resource.octopusdeploy_environment.production.id}
projectFreezeOctopusdeployIndex/deploymentFreezeProjectDeploymentFreezeProject:
type: octopusdeploy:DeploymentFreezeProject
properties:
deploymentfreezeId: ${freezeDeploymentFreeze.id}
projectId: ${data.octopusdeploy_projects.second_project.projects[0].id}
environmentIds:
- ${data.octopusdeploy_environments.default_environment.environments[0].id}
tenantFreeze:
type: octopusdeploy:DeploymentFreezeTenant
properties:
deploymentfreezeId: ${freezeDeploymentFreeze.id}
tenantId: Tenants-1
projectId: Projects-1
environmentId: Environments-1
Create DeploymentFreeze Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new DeploymentFreeze(name: string, args: DeploymentFreezeArgs, opts?: CustomResourceOptions);
@overload
def DeploymentFreeze(resource_name: str,
args: DeploymentFreezeArgs,
opts: Optional[ResourceOptions] = None)
@overload
def DeploymentFreeze(resource_name: str,
opts: Optional[ResourceOptions] = None,
end: Optional[str] = None,
start: Optional[str] = None,
name: Optional[str] = None,
recurring_schedule: Optional[DeploymentFreezeRecurringScheduleArgs] = None)
func NewDeploymentFreeze(ctx *Context, name string, args DeploymentFreezeArgs, opts ...ResourceOption) (*DeploymentFreeze, error)
public DeploymentFreeze(string name, DeploymentFreezeArgs args, CustomResourceOptions? opts = null)
public DeploymentFreeze(String name, DeploymentFreezeArgs args)
public DeploymentFreeze(String name, DeploymentFreezeArgs args, CustomResourceOptions options)
type: octopusdeploy:DeploymentFreeze
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 DeploymentFreezeArgs
- 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 DeploymentFreezeArgs
- 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 DeploymentFreezeArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args DeploymentFreezeArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args DeploymentFreezeArgs
- 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 deploymentFreezeResource = new Octopusdeploy.DeploymentFreeze("deploymentFreezeResource", new()
{
End = "string",
Start = "string",
Name = "string",
RecurringSchedule = new Octopusdeploy.Inputs.DeploymentFreezeRecurringScheduleArgs
{
EndType = "string",
Type = "string",
Unit = 0,
DateOfMonth = "string",
DayNumberOfMonth = "string",
DayOfWeek = "string",
DaysOfWeeks = new[]
{
"string",
},
EndAfterOccurrences = 0,
EndOnDate = "string",
MonthlyScheduleType = "string",
},
});
example, err := octopusdeploy.NewDeploymentFreeze(ctx, "deploymentFreezeResource", &octopusdeploy.DeploymentFreezeArgs{
End: pulumi.String("string"),
Start: pulumi.String("string"),
Name: pulumi.String("string"),
RecurringSchedule: &octopusdeploy.DeploymentFreezeRecurringScheduleArgs{
EndType: pulumi.String("string"),
Type: pulumi.String("string"),
Unit: pulumi.Float64(0),
DateOfMonth: pulumi.String("string"),
DayNumberOfMonth: pulumi.String("string"),
DayOfWeek: pulumi.String("string"),
DaysOfWeeks: pulumi.StringArray{
pulumi.String("string"),
},
EndAfterOccurrences: pulumi.Float64(0),
EndOnDate: pulumi.String("string"),
MonthlyScheduleType: pulumi.String("string"),
},
})
var deploymentFreezeResource = new DeploymentFreeze("deploymentFreezeResource", DeploymentFreezeArgs.builder()
.end("string")
.start("string")
.name("string")
.recurringSchedule(DeploymentFreezeRecurringScheduleArgs.builder()
.endType("string")
.type("string")
.unit(0)
.dateOfMonth("string")
.dayNumberOfMonth("string")
.dayOfWeek("string")
.daysOfWeeks("string")
.endAfterOccurrences(0)
.endOnDate("string")
.monthlyScheduleType("string")
.build())
.build());
deployment_freeze_resource = octopusdeploy.DeploymentFreeze("deploymentFreezeResource",
end="string",
start="string",
name="string",
recurring_schedule={
"end_type": "string",
"type": "string",
"unit": 0,
"date_of_month": "string",
"day_number_of_month": "string",
"day_of_week": "string",
"days_of_weeks": ["string"],
"end_after_occurrences": 0,
"end_on_date": "string",
"monthly_schedule_type": "string",
})
const deploymentFreezeResource = new octopusdeploy.DeploymentFreeze("deploymentFreezeResource", {
end: "string",
start: "string",
name: "string",
recurringSchedule: {
endType: "string",
type: "string",
unit: 0,
dateOfMonth: "string",
dayNumberOfMonth: "string",
dayOfWeek: "string",
daysOfWeeks: ["string"],
endAfterOccurrences: 0,
endOnDate: "string",
monthlyScheduleType: "string",
},
});
type: octopusdeploy:DeploymentFreeze
properties:
end: string
name: string
recurringSchedule:
dateOfMonth: string
dayNumberOfMonth: string
dayOfWeek: string
daysOfWeeks:
- string
endAfterOccurrences: 0
endOnDate: string
endType: string
monthlyScheduleType: string
type: string
unit: 0
start: string
DeploymentFreeze 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 DeploymentFreeze resource accepts the following input properties:
- End string
- The end time of the freeze, must be RFC3339 format
- Start string
- The start time of the freeze, must be RFC3339 format
- Name string
- The name of this resource.
- Recurring
Schedule DeploymentFreeze Recurring Schedule
- End string
- The end time of the freeze, must be RFC3339 format
- Start string
- The start time of the freeze, must be RFC3339 format
- Name string
- The name of this resource.
- Recurring
Schedule DeploymentFreeze Recurring Schedule Args
- end String
- The end time of the freeze, must be RFC3339 format
- start String
- The start time of the freeze, must be RFC3339 format
- name String
- The name of this resource.
- recurring
Schedule DeploymentFreeze Recurring Schedule
- end string
- The end time of the freeze, must be RFC3339 format
- start string
- The start time of the freeze, must be RFC3339 format
- name string
- The name of this resource.
- recurring
Schedule DeploymentFreeze Recurring Schedule
- end str
- The end time of the freeze, must be RFC3339 format
- start str
- The start time of the freeze, must be RFC3339 format
- name str
- The name of this resource.
- recurring_
schedule DeploymentFreeze Recurring Schedule Args
- end String
- The end time of the freeze, must be RFC3339 format
- start String
- The start time of the freeze, must be RFC3339 format
- name String
- The name of this resource.
- recurring
Schedule Property Map
Outputs
All input properties are implicitly available as output properties. Additionally, the DeploymentFreeze resource produces the following output properties:
- Id string
- The provider-assigned unique ID for this managed resource.
- Id string
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
- id string
- The provider-assigned unique ID for this managed resource.
- id str
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
Look up Existing DeploymentFreeze Resource
Get an existing DeploymentFreeze 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?: DeploymentFreezeState, opts?: CustomResourceOptions): DeploymentFreeze
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
end: Optional[str] = None,
name: Optional[str] = None,
recurring_schedule: Optional[DeploymentFreezeRecurringScheduleArgs] = None,
start: Optional[str] = None) -> DeploymentFreeze
func GetDeploymentFreeze(ctx *Context, name string, id IDInput, state *DeploymentFreezeState, opts ...ResourceOption) (*DeploymentFreeze, error)
public static DeploymentFreeze Get(string name, Input<string> id, DeploymentFreezeState? state, CustomResourceOptions? opts = null)
public static DeploymentFreeze get(String name, Output<String> id, DeploymentFreezeState state, CustomResourceOptions options)
resources: _: type: octopusdeploy:DeploymentFreeze get: id: ${id}
- 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.
- End string
- The end time of the freeze, must be RFC3339 format
- Name string
- The name of this resource.
- Recurring
Schedule DeploymentFreeze Recurring Schedule - Start string
- The start time of the freeze, must be RFC3339 format
- End string
- The end time of the freeze, must be RFC3339 format
- Name string
- The name of this resource.
- Recurring
Schedule DeploymentFreeze Recurring Schedule Args - Start string
- The start time of the freeze, must be RFC3339 format
- end String
- The end time of the freeze, must be RFC3339 format
- name String
- The name of this resource.
- recurring
Schedule DeploymentFreeze Recurring Schedule - start String
- The start time of the freeze, must be RFC3339 format
- end string
- The end time of the freeze, must be RFC3339 format
- name string
- The name of this resource.
- recurring
Schedule DeploymentFreeze Recurring Schedule - start string
- The start time of the freeze, must be RFC3339 format
- end str
- The end time of the freeze, must be RFC3339 format
- name str
- The name of this resource.
- recurring_
schedule DeploymentFreeze Recurring Schedule Args - start str
- The start time of the freeze, must be RFC3339 format
- end String
- The end time of the freeze, must be RFC3339 format
- name String
- The name of this resource.
- recurring
Schedule Property Map - start String
- The start time of the freeze, must be RFC3339 format
Supporting Types
DeploymentFreezeRecurringSchedule, DeploymentFreezeRecurringScheduleArgs
- End
Type string - When the recurring schedule should end (Never, OnDate, AfterOccurrences)
- Type string
- Type of recurring schedule (Daily, Weekly, Monthly, Annually)
- Unit double
- The unit value for the schedule
- Date
Of stringMonth - The date of the month for monthly schedules
- Day
Number stringOf Month - Specifies which weekday position in the month. Valid values: 1 (First), 2 (Second), 3 (Third), 4 (Fourth), L (Last). Used with dayofweek
- Day
Of stringWeek - The day of the week for monthly schedules when using DayOfMonth type
- Days
Of List<string>Weeks - List of days of the week for weekly schedules. Must follow order: Sunday, Monday, Tuesday, Wednesday, Thursday, Friday, Saturday
- End
After doubleOccurrences - Number of occurrences after which the schedule should end
- End
On stringDate - The date when the recurring schedule should end
- Monthly
Schedule stringType - Type of monthly schedule (DayOfMonth, DateOfMonth)
- End
Type string - When the recurring schedule should end (Never, OnDate, AfterOccurrences)
- Type string
- Type of recurring schedule (Daily, Weekly, Monthly, Annually)
- Unit float64
- The unit value for the schedule
- Date
Of stringMonth - The date of the month for monthly schedules
- Day
Number stringOf Month - Specifies which weekday position in the month. Valid values: 1 (First), 2 (Second), 3 (Third), 4 (Fourth), L (Last). Used with dayofweek
- Day
Of stringWeek - The day of the week for monthly schedules when using DayOfMonth type
- Days
Of []stringWeeks - List of days of the week for weekly schedules. Must follow order: Sunday, Monday, Tuesday, Wednesday, Thursday, Friday, Saturday
- End
After float64Occurrences - Number of occurrences after which the schedule should end
- End
On stringDate - The date when the recurring schedule should end
- Monthly
Schedule stringType - Type of monthly schedule (DayOfMonth, DateOfMonth)
- end
Type String - When the recurring schedule should end (Never, OnDate, AfterOccurrences)
- type String
- Type of recurring schedule (Daily, Weekly, Monthly, Annually)
- unit Double
- The unit value for the schedule
- date
Of StringMonth - The date of the month for monthly schedules
- day
Number StringOf Month - Specifies which weekday position in the month. Valid values: 1 (First), 2 (Second), 3 (Third), 4 (Fourth), L (Last). Used with dayofweek
- day
Of StringWeek - The day of the week for monthly schedules when using DayOfMonth type
- days
Of List<String>Weeks - List of days of the week for weekly schedules. Must follow order: Sunday, Monday, Tuesday, Wednesday, Thursday, Friday, Saturday
- end
After DoubleOccurrences - Number of occurrences after which the schedule should end
- end
On StringDate - The date when the recurring schedule should end
- monthly
Schedule StringType - Type of monthly schedule (DayOfMonth, DateOfMonth)
- end
Type string - When the recurring schedule should end (Never, OnDate, AfterOccurrences)
- type string
- Type of recurring schedule (Daily, Weekly, Monthly, Annually)
- unit number
- The unit value for the schedule
- date
Of stringMonth - The date of the month for monthly schedules
- day
Number stringOf Month - Specifies which weekday position in the month. Valid values: 1 (First), 2 (Second), 3 (Third), 4 (Fourth), L (Last). Used with dayofweek
- day
Of stringWeek - The day of the week for monthly schedules when using DayOfMonth type
- days
Of string[]Weeks - List of days of the week for weekly schedules. Must follow order: Sunday, Monday, Tuesday, Wednesday, Thursday, Friday, Saturday
- end
After numberOccurrences - Number of occurrences after which the schedule should end
- end
On stringDate - The date when the recurring schedule should end
- monthly
Schedule stringType - Type of monthly schedule (DayOfMonth, DateOfMonth)
- end_
type str - When the recurring schedule should end (Never, OnDate, AfterOccurrences)
- type str
- Type of recurring schedule (Daily, Weekly, Monthly, Annually)
- unit float
- The unit value for the schedule
- date_
of_ strmonth - The date of the month for monthly schedules
- day_
number_ strof_ month - Specifies which weekday position in the month. Valid values: 1 (First), 2 (Second), 3 (Third), 4 (Fourth), L (Last). Used with dayofweek
- day_
of_ strweek - The day of the week for monthly schedules when using DayOfMonth type
- days_
of_ Sequence[str]weeks - List of days of the week for weekly schedules. Must follow order: Sunday, Monday, Tuesday, Wednesday, Thursday, Friday, Saturday
- end_
after_ floatoccurrences - Number of occurrences after which the schedule should end
- end_
on_ strdate - The date when the recurring schedule should end
- monthly_
schedule_ strtype - Type of monthly schedule (DayOfMonth, DateOfMonth)
- end
Type String - When the recurring schedule should end (Never, OnDate, AfterOccurrences)
- type String
- Type of recurring schedule (Daily, Weekly, Monthly, Annually)
- unit Number
- The unit value for the schedule
- date
Of StringMonth - The date of the month for monthly schedules
- day
Number StringOf Month - Specifies which weekday position in the month. Valid values: 1 (First), 2 (Second), 3 (Third), 4 (Fourth), L (Last). Used with dayofweek
- day
Of StringWeek - The day of the week for monthly schedules when using DayOfMonth type
- days
Of List<String>Weeks - List of days of the week for weekly schedules. Must follow order: Sunday, Monday, Tuesday, Wednesday, Thursday, Friday, Saturday
- end
After NumberOccurrences - Number of occurrences after which the schedule should end
- end
On StringDate - The date when the recurring schedule should end
- monthly
Schedule StringType - Type of monthly schedule (DayOfMonth, DateOfMonth)
Package Details
- Repository
- octopusdeploy octopusdeploylabs/terraform-provider-octopusdeploy
- License
- Notes
- This Pulumi package is based on the
octopusdeploy
Terraform Provider.