Set-AzDevCenterUserDevBoxActiveHour
Lets a user set their own active hours for their Dev Box, overriding the defaults set at the pool level.
Syntax
SetExpanded (Default)
Set-AzDevCenterUserDevBoxActiveHour
-Endpoint <String>
-DevBoxName <String>
-ProjectName <String>
-EndTimeHour <Int32>
-StartTimeHour <Int32>
-TimeZone <String>
[-UserId <String>]
[-DefaultProfile <PSObject>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Set
Set-AzDevCenterUserDevBoxActiveHour
-Endpoint <String>
-DevBoxName <String>
-ProjectName <String>
-Body <IUserActiveHoursConfiguration>
[-UserId <String>]
[-DefaultProfile <PSObject>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
SetByDevCenter
Set-AzDevCenterUserDevBoxActiveHour
-DevCenterName <String>
-DevBoxName <String>
-ProjectName <String>
-Body <IUserActiveHoursConfiguration>
[-UserId <String>]
[-DefaultProfile <PSObject>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
SetExpandedByDevCenter
Set-AzDevCenterUserDevBoxActiveHour
-DevCenterName <String>
-DevBoxName <String>
-ProjectName <String>
-EndTimeHour <Int32>
-StartTimeHour <Int32>
-TimeZone <String>
[-UserId <String>]
[-DefaultProfile <PSObject>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Description
Lets a user set their own active hours for their Dev Box, overriding the defaults set at the pool level.
Examples
Example 1: Set active hours for a Dev Box by endpoint and user ID
Set-AzDevCenterUserDevBoxActiveHour `
-Endpoint "https://8a40af38-3b4c-4672-a6a4-5e964b1870ed-contosodevcenter.centralus.devcenter.azure.com/" `
-ProjectName "DevProject" `
-DevBoxName "myDevBox" `
-UserId "786a823c-8037-48ab-89b8-8599901e67d0" `
-StartTimeHour 9 `
-EndTimeHour 17 `
-TimeZone "America/Los_Angeles"
This command sets the active hours for the dev box "myDevBox" assigned to user "786a823c-8037-48ab-89b8-8599901e67d0" from 9 AM to 5 PM in the "America/Los_Angeles" time zone using the endpoint.
Example 2: Set active hours for a Dev Box by dev center name and current user
Set-AzDevCenterUserDevBoxActiveHour `
-DevCenterName "ContosoDevCenter" `
-ProjectName "DevProject" `
-DevBoxName "myDevBox" `
-UserId "me" `
-StartTimeHour 8 `
-EndTimeHour 16 `
-TimeZone "America/New_York"
This command sets the active hours for the dev box "myDevBox" assigned to the current signed-in user from 8 AM to 4 PM in the "America/New_York" time zone using the dev center name.
Example 3: Set active hours for a Dev Box using Body parameter and endpoint
$activeHours = @{
StartTimeHour = 10
EndTimeHour = 18
TimeZone = "America/Chicago"
}
Set-AzDevCenterUserDevBoxActiveHour `
-Endpoint "https://8a40af38-3b4c-4672-a6a4-5e964b1870ed-contosodevcenter.centralus.devcenter.azure.com/" `
-ProjectName "DevProject" `
-DevBoxName "myDevBox" `
-UserId "me" `
-Body $activeHours
This command sets the active hours for the dev box "myDevBox" assigned to the current signed-in user from 10 AM to 6 PM in the "America/Chicago" time zone using the endpoint and a body object.
Example 4: Set active hours for a Dev Box using Body parameter and dev center name
$activeHours = @{
StartTimeHour = 7
EndTimeHour = 15
TimeZone = "America/Los_Angeles"
}
Set-AzDevCenterUserDevBoxActiveHour `
-DevCenterName "ContosoDevCenter" `
-ProjectName "DevProject" `
-DevBoxName "myDevBox" `
-UserId "786a823c-8037-48ab-89b8-8599901e67d0" `
-Body $activeHours
This command sets the active hours for the dev box "myDevBox" assigned to user "786a823c-8037-48ab-89b8-8599901e67d0" from 7 AM to 3 PM in the "UTC" time zone using the dev center name and a body object.
Parameters
-Body
Manual user set active hours configuration.
To construct, see NOTES section for BODY properties and create a hash table.
Parameter properties
Parameter sets
Set
Position: Named
Mandatory: True
Value from pipeline: True
Value from pipeline by property name: False
Value from remaining arguments: False
SetByDevCenter
Position: Named
Mandatory: True
Value from pipeline: True
Value from pipeline by property name: False
Value from remaining arguments: False
-Confirm
Prompts you for confirmation before running the cmdlet.
Parameter properties
Type: SwitchParameter
Default value: None
Supports wildcards: False
DontShow: False
Aliases: cf
Parameter sets
(All)
Position: Named
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
-DefaultProfile
The DefaultProfile parameter is not functional.
Use the SubscriptionId parameter when available if executing the cmdlet against a different subscription.
Parameter properties
Type: PSObject
Default value: None
Supports wildcards: False
DontShow: False
Aliases: AzureRMContext, AzureCredential
Parameter sets
(All)
Position: Named
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
-DevBoxName
Display name for the Dev Box.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
(All)
Position: Named
Mandatory: True
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
-DevCenterName
The DevCenter upon which to execute operations.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Aliases: DevCenter
Parameter sets
SetByDevCenter
Position: Named
Mandatory: True
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
SetExpandedByDevCenter
Position: Named
Mandatory: True
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
-Endpoint
The DevCenter-specific URI to operate on.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
SetExpanded
Position: Named
Mandatory: True
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
Set
Position: Named
Mandatory: True
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
-EndTimeHour
The end time of the active hours.
Parameter properties
Type: Int32
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
SetExpanded
Position: Named
Mandatory: True
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
SetExpandedByDevCenter
Position: Named
Mandatory: True
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
-ProjectName
Name of the project.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
(All)
Position: Named
Mandatory: True
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
-StartTimeHour
The start time of the active hours.
Parameter properties
Type: Int32
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
SetExpanded
Position: Named
Mandatory: True
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
SetExpandedByDevCenter
Position: Named
Mandatory: True
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
-TimeZone
The timezone of the active hours.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
SetExpanded
Position: Named
Mandatory: True
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
SetExpandedByDevCenter
Position: Named
Mandatory: True
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
-UserId
The AAD object id of the user.
If value is 'me', the identity is taken from the authentication context.
Parameter properties
Type: String
Default value: me
Supports wildcards: False
DontShow: False
Parameter sets
(All)
Position: Named
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
-WhatIf
Shows what would happen if the cmdlet runs.
The cmdlet is not run.
Parameter properties
Type: SwitchParameter
Default value: None
Supports wildcards: False
DontShow: False
Aliases: wi
Parameter sets
(All)
Position: Named
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
CommonParameters
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable,
-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable,
-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see
about_CommonParameters .
Outputs