< Back
New-AzureBatchComputeNodeUser
Post
NAME New-AzureBatchComputeNodeUser
SYNOPSIS
Creates a user account on a Batch compute node.
SYNTAX
New-AzureBatchComputeNodeUser [[-ComputeNode] <PSComputeNode>] -BatchContext <BatchAccountContext> [-DefaultProfile <IAzureContextContainer>]
[-ExpiryTime <DateTime>] [-IsAdmin] -Name <String> -Password <SecureString> [<CommonParameters>]
New-AzureBatchComputeNodeUser [-PoolId] <String> [-ComputeNodeId] <String> -BatchContext <BatchAccountContext> [-DefaultProfile
<IAzureContextContainer>] [-ExpiryTime <DateTime>] [-IsAdmin] -Name <String> -Password <SecureString> [<CommonParameters>]
DESCRIPTION
The New-AzureBatchComputeNodeUser cmdlet creates a user account on an Azure Batch compute node.
PARAMETERS
-BatchContext <BatchAccountContext>
Specifies the BatchAccountContext instance that this cmdlet uses to interact with the Batch service. If you use the Get-AzureRmBatchAccount
cmdlet to get your BatchAccountContext, then Azure Active Directory authentication will be used when interacting with the Batch service. To
use shared key authentication instead, use the Get-AzureRmBatchAccountKeys cmdlet to get a BatchAccountContext object with its access keys
populated. When using shared key authentication, the primary access key is used by default. To change the key to use, set the
BatchAccountContext.KeyInUse property.
Required? true
Position? named
Default value None
Accept pipeline input? True (ByValue)
Accept wildcard characters? false
-ComputeNode <PSComputeNode>
Specifies the compute node, as a PSComputeNode object, on which this cmdlet creates a user account.
Required? false
Position? 0
Default value None
Accept pipeline input? True (ByValue)
Accept wildcard characters? false
-ComputeNodeId <String>
Specifies the ID of the compute node on which this cmdlet creates a user account.
Required? true
Position? 1
Default value None
Accept pipeline input? False
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
-ExpiryTime <DateTime>
Specifies the expiry time for the new user account.
Required? false
Position? named
Default value None
Accept pipeline input? False
Accept wildcard characters? false
-IsAdmin [<SwitchParameter>]
Indicates that the cmdlet creates a user account that has administrative credentials.
Required? false
Position? named
Default value False
Accept pipeline input? False
Accept wildcard characters? false
-Name <String>
Specifies the name of the new local Windows account.
Required? true
Position? named
Default value None
Accept pipeline input? False
Accept wildcard characters? false
-Password <SecureString>
Specifies the user account password.
Required? true
Position? named
Default value None
Accept pipeline input? False
Accept wildcard characters? false
-PoolId <String>
Specifies the ID of the pool that contains the compute node on which to create the user account.
Required? true
Position? 0
Default value None
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
BatchAccountContext
Parameter 'BatchContext' accepts value of type 'BatchAccountContext' from the pipeline
PSComputeNode
Parameter 'ComputeNode' accepts value of type 'PSComputeNode' from the pipeline
OUTPUTS
NOTES
Example 1: Create a user account that has administrative credentials
PS C:\\>New-AzureBatchComputeNodeUser -PoolId "MyPool01" -ComputeNodeId "ComputeNode01" -Name "TestUser" -Password "Password" -ExpiryTime
([DateTime]::Now.AddDays(7)) -IsAdmin -BatchContext $Context
This command creates a user account on the compute node that has the ID ComputeNode01. The node is in the pool that has the ID MyPool01. The user
name is TestUser, the password is Password, the account expires in seven days, and the account is has administrative credentials.
Example 2: Create a user account on a compute node by using the pipeline
PS C:\\>Get-AzureBatchComputeNode "MyPool01" -ComputeNodeId "ComputeNode01" -BatchContext $Context | New-AzureBatchComputeNodeUser -Name "TestUser"
-Password "Password" -BatchContext $Context
This command gets the compute node named ComputeNode01 by using the Get-AzureBatchComputeNode cmdlet. That node is in the pool that has the ID
MyPool01. The command passes that compute node to the current cmdlet by using the pipeline operator. The command creates a user account that has
the user name TestUserand the password Password.
RELATED LINKS
Online Version: https://docs.microsoft.com/en-us/powers ... tenodeuser
Get-AzureRmBatchAccountKeys
Get-AzureBatchComputeNode
Remove-AzureBatchComputeNodeUser
Azure Batch Cmdlets
SYNOPSIS
Creates a user account on a Batch compute node.
SYNTAX
New-AzureBatchComputeNodeUser [[-ComputeNode] <PSComputeNode>] -BatchContext <BatchAccountContext> [-DefaultProfile <IAzureContextContainer>]
[-ExpiryTime <DateTime>] [-IsAdmin] -Name <String> -Password <SecureString> [<CommonParameters>]
New-AzureBatchComputeNodeUser [-PoolId] <String> [-ComputeNodeId] <String> -BatchContext <BatchAccountContext> [-DefaultProfile
<IAzureContextContainer>] [-ExpiryTime <DateTime>] [-IsAdmin] -Name <String> -Password <SecureString> [<CommonParameters>]
DESCRIPTION
The New-AzureBatchComputeNodeUser cmdlet creates a user account on an Azure Batch compute node.
PARAMETERS
-BatchContext <BatchAccountContext>
Specifies the BatchAccountContext instance that this cmdlet uses to interact with the Batch service. If you use the Get-AzureRmBatchAccount
cmdlet to get your BatchAccountContext, then Azure Active Directory authentication will be used when interacting with the Batch service. To
use shared key authentication instead, use the Get-AzureRmBatchAccountKeys cmdlet to get a BatchAccountContext object with its access keys
populated. When using shared key authentication, the primary access key is used by default. To change the key to use, set the
BatchAccountContext.KeyInUse property.
Required? true
Position? named
Default value None
Accept pipeline input? True (ByValue)
Accept wildcard characters? false
-ComputeNode <PSComputeNode>
Specifies the compute node, as a PSComputeNode object, on which this cmdlet creates a user account.
Required? false
Position? 0
Default value None
Accept pipeline input? True (ByValue)
Accept wildcard characters? false
-ComputeNodeId <String>
Specifies the ID of the compute node on which this cmdlet creates a user account.
Required? true
Position? 1
Default value None
Accept pipeline input? False
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
-ExpiryTime <DateTime>
Specifies the expiry time for the new user account.
Required? false
Position? named
Default value None
Accept pipeline input? False
Accept wildcard characters? false
-IsAdmin [<SwitchParameter>]
Indicates that the cmdlet creates a user account that has administrative credentials.
Required? false
Position? named
Default value False
Accept pipeline input? False
Accept wildcard characters? false
-Name <String>
Specifies the name of the new local Windows account.
Required? true
Position? named
Default value None
Accept pipeline input? False
Accept wildcard characters? false
-Password <SecureString>
Specifies the user account password.
Required? true
Position? named
Default value None
Accept pipeline input? False
Accept wildcard characters? false
-PoolId <String>
Specifies the ID of the pool that contains the compute node on which to create the user account.
Required? true
Position? 0
Default value None
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
BatchAccountContext
Parameter 'BatchContext' accepts value of type 'BatchAccountContext' from the pipeline
PSComputeNode
Parameter 'ComputeNode' accepts value of type 'PSComputeNode' from the pipeline
OUTPUTS
NOTES
Example 1: Create a user account that has administrative credentials
PS C:\\>New-AzureBatchComputeNodeUser -PoolId "MyPool01" -ComputeNodeId "ComputeNode01" -Name "TestUser" -Password "Password" -ExpiryTime
([DateTime]::Now.AddDays(7)) -IsAdmin -BatchContext $Context
This command creates a user account on the compute node that has the ID ComputeNode01. The node is in the pool that has the ID MyPool01. The user
name is TestUser, the password is Password, the account expires in seven days, and the account is has administrative credentials.
Example 2: Create a user account on a compute node by using the pipeline
PS C:\\>Get-AzureBatchComputeNode "MyPool01" -ComputeNodeId "ComputeNode01" -BatchContext $Context | New-AzureBatchComputeNodeUser -Name "TestUser"
-Password "Password" -BatchContext $Context
This command gets the compute node named ComputeNode01 by using the Get-AzureBatchComputeNode cmdlet. That node is in the pool that has the ID
MyPool01. The command passes that compute node to the current cmdlet by using the pipeline operator. The command creates a user account that has
the user name TestUserand the password Password.
RELATED LINKS
Online Version: https://docs.microsoft.com/en-us/powers ... tenodeuser
Get-AzureRmBatchAccountKeys
Get-AzureBatchComputeNode
Remove-AzureBatchComputeNodeUser
Azure Batch Cmdlets