< Back
New-AzureRmContainerService
Post
NAME New-AzureRmContainerService
SYNOPSIS
Creates a container service.
SYNTAX
New-AzureRmContainerService [-ResourceGroupName] <String> [-Name] <String> [-ContainerService] <PSContainerService> [-AsJob] [-DefaultProfile
<IAzureContextContainer>] [-Confirm] [-WhatIf] [<CommonParameters>]
DESCRIPTION
The New-AzureRmContainerService cmdlet creates a container service. Specify a container service object that you can create by using the
New-AzureRmContainerServiceConfig cmdlet.
PARAMETERS
-AsJob [<SwitchParameter>]
RRun cmdlet in the background and return a Job to track progress.
Required? false
Position? named
Default value False
Accept pipeline input? False
Accept wildcard characters? false
-ContainerService <PSContainerService>
Specifies a container service object that contains the properties for the new service. To obtain a ContainerService object, use the
New-AzureRmContainerServiceConfig cmdlet.
Required? true
Position? 3
Default value None
Accept pipeline input? True (ByValue)
Accept wildcard characters? false
-DefaultProfile <IAzureContextContainer>
The credentials, account, tenant, and subscription used for communication with azure.
Required? false
Position? named
Default value None
Accept pipeline input? False
Accept wildcard characters? false
-Name <String>
Specifies the name of the container service that this cmdlet creates.
Required? true
Position? 2
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-ResourceGroupName <String>
Specifies the resource group in which this cmdlet deploys the container service.
Required? true
Position? 1
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-Confirm [<SwitchParameter>]
Prompts you for confirmation before running the cmdlet.
Required? false
Position? named
Default value False
Accept pipeline input? False
Accept wildcard characters? false
-WhatIf [<SwitchParameter>]
Shows what would happen if the cmdlet runs.
The cmdlet is not run.
Required? false
Position? named
Default value False
Accept pipeline input? False
Accept wildcard characters? false
<CommonParameters>
This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, WarningAction, WarningVariable,
OutBuffer, PipelineVariable, and OutVariable. For more information, see
about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).
INPUTS
ContainerService
Parameter 'ContainerService' accepts value of type 'ContainerService' from the pipeline
OUTPUTS
Microsoft.Azure.Commands.Compute.Automation.Models.PSContainerService
NOTES
Example 1: Create a container service
PS C:\\> New-AzureRMResourceGroup -Name "ResourceGroup17" -Location "Australia Southeast" -Force
PS C:\\> $Container = New-AzureRmContainerServiceConfig -Location "Australia Southeast" -OrchestratorType "DCOS" -MasterDnsPrefix
"MasterResourceGroup17" -AdminUsername "AcsLinuxAdmin" -SshPublicKey "<ssh-key>" | Add-AzureRmContainerServiceAgentPoolProfile -Name "AgentPool01"
-VmSize "Standard_A1" -DnsPrefix "APResourceGroup17"
PS C:\\> New-AzureRmContainerService -ResourceGroupName "ResourceGroup17" -Name "CSResourceGroup17" -ContainerService $Container
The first command creates a resource group named ResourceGroup17 at the specified location. For more information, see the New-AzureRmResourceGroup
cmdlet.
The second command creates a container, and then stores it in the $Container variable. For more information, see the
New-AzureRmContainerServiceConfig cmdlet.
The final command creates a container service for the container stored in $Container. The service is named csResourceGroup17.
RELATED LINKS
Online Version: https://docs.microsoft.com/en-us/powers ... nerservice
Get-AzureRmContainerService
New-AzureRmContainerServiceConfig
Remove-AzureRmContainerService
Update-AzureRmContainerService
SYNOPSIS
Creates a container service.
SYNTAX
New-AzureRmContainerService [-ResourceGroupName] <String> [-Name] <String> [-ContainerService] <PSContainerService> [-AsJob] [-DefaultProfile
<IAzureContextContainer>] [-Confirm] [-WhatIf] [<CommonParameters>]
DESCRIPTION
The New-AzureRmContainerService cmdlet creates a container service. Specify a container service object that you can create by using the
New-AzureRmContainerServiceConfig cmdlet.
PARAMETERS
-AsJob [<SwitchParameter>]
RRun cmdlet in the background and return a Job to track progress.
Required? false
Position? named
Default value False
Accept pipeline input? False
Accept wildcard characters? false
-ContainerService <PSContainerService>
Specifies a container service object that contains the properties for the new service. To obtain a ContainerService object, use the
New-AzureRmContainerServiceConfig cmdlet.
Required? true
Position? 3
Default value None
Accept pipeline input? True (ByValue)
Accept wildcard characters? false
-DefaultProfile <IAzureContextContainer>
The credentials, account, tenant, and subscription used for communication with azure.
Required? false
Position? named
Default value None
Accept pipeline input? False
Accept wildcard characters? false
-Name <String>
Specifies the name of the container service that this cmdlet creates.
Required? true
Position? 2
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-ResourceGroupName <String>
Specifies the resource group in which this cmdlet deploys the container service.
Required? true
Position? 1
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-Confirm [<SwitchParameter>]
Prompts you for confirmation before running the cmdlet.
Required? false
Position? named
Default value False
Accept pipeline input? False
Accept wildcard characters? false
-WhatIf [<SwitchParameter>]
Shows what would happen if the cmdlet runs.
The cmdlet is not run.
Required? false
Position? named
Default value False
Accept pipeline input? False
Accept wildcard characters? false
<CommonParameters>
This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, WarningAction, WarningVariable,
OutBuffer, PipelineVariable, and OutVariable. For more information, see
about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).
INPUTS
ContainerService
Parameter 'ContainerService' accepts value of type 'ContainerService' from the pipeline
OUTPUTS
Microsoft.Azure.Commands.Compute.Automation.Models.PSContainerService
NOTES
Example 1: Create a container service
PS C:\\> New-AzureRMResourceGroup -Name "ResourceGroup17" -Location "Australia Southeast" -Force
PS C:\\> $Container = New-AzureRmContainerServiceConfig -Location "Australia Southeast" -OrchestratorType "DCOS" -MasterDnsPrefix
"MasterResourceGroup17" -AdminUsername "AcsLinuxAdmin" -SshPublicKey "<ssh-key>" | Add-AzureRmContainerServiceAgentPoolProfile -Name "AgentPool01"
-VmSize "Standard_A1" -DnsPrefix "APResourceGroup17"
PS C:\\> New-AzureRmContainerService -ResourceGroupName "ResourceGroup17" -Name "CSResourceGroup17" -ContainerService $Container
The first command creates a resource group named ResourceGroup17 at the specified location. For more information, see the New-AzureRmResourceGroup
cmdlet.
The second command creates a container, and then stores it in the $Container variable. For more information, see the
New-AzureRmContainerServiceConfig cmdlet.
The final command creates a container service for the container stored in $Container. The service is named csResourceGroup17.
RELATED LINKS
Online Version: https://docs.microsoft.com/en-us/powers ... nerservice
Get-AzureRmContainerService
New-AzureRmContainerServiceConfig
Remove-AzureRmContainerService
Update-AzureRmContainerService