Share via


az guestconfig guest-configuration-hcrp-assignment

Note

This reference is part of the guestconfig extension for the Azure CLI (version 2.3.1 or higher). The extension will automatically install the first time you run an az guestconfig guest-configuration-hcrp-assignment command. Learn more about extensions.

This command group is experimental and under development. Reference and support levels: https://aka.ms/CLI_refstatus

Guestconfig guest-configuration-hcrp-assignment.

Commands

Name Description Type Status
az guestconfig guest-configuration-hcrp-assignment create

Creates an association between a ARC machine and guest configuration.

Extension Experimental
az guestconfig guest-configuration-hcrp-assignment delete

Delete a guest configuration assignment.

Extension Experimental
az guestconfig guest-configuration-hcrp-assignment list

List all guest configuration assignments for an ARC machine.

Extension Experimental
az guestconfig guest-configuration-hcrp-assignment show

Get information about a guest configuration assignment.

Extension Experimental
az guestconfig guest-configuration-hcrp-assignment update

Creates an association between a ARC machine and guest configuration.

Extension Experimental
az guestconfig guest-configuration-hcrp-assignment wait

Place the CLI in a waiting state until a condition of the guestconfig guest-configuration-hcrp-assignment is met.

Extension Experimental

az guestconfig guest-configuration-hcrp-assignment create

Experimental

Command group 'guestconfig guest-configuration-hcrp-assignment' is experimental and under development. Reference and support levels: https://aka.ms/CLI_refstatus

Creates an association between a ARC machine and guest configuration.

az guestconfig guest-configuration-hcrp-assignment create --guest-configuration-assignment-name
                                                          --machine-name
                                                          --resource-group
                                                          [--context]
                                                          [--guest-configuration-configuration-parameter]
                                                          [--guest-configuration-configuration-setting]
                                                          [--guest-configuration-name]
                                                          [--guest-configuration-version]
                                                          [--latest-assignment-report-assignment]
                                                          [--location]
                                                          [--name]
                                                          [--no-wait]

Examples

Create or update guest configuration assignment

az guestconfig guest-configuration-hcrp-assignment create --guest-configuration-assignment-name "WhitelistedApplication" --machine-name "myMachineName" --guest-configuration-name "WhitelistedApplication" --location "westcentralus" --context "Azure policy" --guest-configuration-name "WhitelistedApplication" --guest-configuration-configuration-parameter name="[InstalledApplication]bwhitelistedapp;Name" value="NotePad,sql" --guest-configuration-configuration-setting action-after-reboot="ContinueConfiguration" configuration-mode="MonitorOnly" configuration-mode-frequency-mins=15 reboot-if-needed="False" --guest-configuration-version "1.*" --resource-group "myResourceGroupName"

Required Parameters

--guest-configuration-assignment-name

Name of the guest configuration assignment.

--machine-name

The name of the ARC machine.

--resource-group -g

Name of resource group. You can configure the default group using az configure --defaults group=<name>.

Optional Parameters

The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.

--context

The source which initiated the guest configuration assignment. Ex: Azure Policy.

--guest-configuration-configuration-parameter

The configuration parameters for the guest configuration.

Usage: --guest-configuration-configuration-parameter name=XX value=XX

name: Name of the configuration parameter. value: Value of the configuration parameter.

Multiple actions can be specified by using more than one --guest-configuration-configuration-parameter argument.

--guest-configuration-configuration-setting

The configuration setting for the guest configuration.

Usage: --guest-configuration-configuration-setting configuration-mode=XX allow-module-overwrite=XX action-after-reboot=XX refresh-frequency-mins=XX reboot-if-needed=XX configuration-mode-frequency-mins=XX

configuration-mode: Specifies how the LCM(Local Configuration Manager) actually applies the configuration to the target nodes. Possible values are ApplyOnly, ApplyAndMonitor, and ApplyAndAutoCorrect. allow-module-overwrite: If true - new configurations downloaded from the pull service are allowed to overwrite the old ones on the target node. Otherwise, false action-after-reboot: Specifies what happens after a reboot during the application of a configuration. The possible values are ContinueConfiguration and StopConfiguration refresh-frequency-mins: The time interval, in minutes, at which the LCM checks a pull service to get updated configurations. This value is ignored if the LCM is not configured in pull mode. The default value is 30. reboot-if-needed: Set this to true to automatically reboot the node after a configuration that requires reboot is applied. Otherwise, you will have to manually reboot the node for any configuration that requires it. The default value is false. To use this setting when a reboot condition is enacted by something other than DSC (such as Windows Installer), combine this setting with the xPendingReboot module. configuration-mode-frequency-mins: How often, in minutes, the current configuration is checked and applied. This property is ignored if the ConfigurationMode property is set to ApplyOnly. The default value is 15.

--guest-configuration-name

Name of the guest configuration.

--guest-configuration-version

Version of the guest configuration.

--latest-assignment-report-assignment

Configuration details of the guest configuration assignment. Expected value: json-string/@json-file.

--location -l

Location. Values from: az account list-locations. You can configure the default location using az configure --defaults location=<location>.

--name

Name of the guest configuration assignment.

--no-wait

Do not wait for the long-running operation to finish.

Property Value
Default value: False
Global Parameters
--debug

Increase logging verbosity to show all debug logs.

Property Value
Default value: False
--help -h

Show this help message and exit.

--only-show-errors

Only show errors, suppressing warnings.

Property Value
Default value: False
--output -o

Output format.

Property Value
Default value: json
Accepted values: json, jsonc, none, table, tsv, yaml, yamlc
--query

JMESPath query string. See http://jmespath.org/ for more information and examples.

--subscription

Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.

--verbose

Increase logging verbosity. Use --debug for full debug logs.

Property Value
Default value: False

az guestconfig guest-configuration-hcrp-assignment delete

Experimental

Command group 'guestconfig guest-configuration-hcrp-assignment' is experimental and under development. Reference and support levels: https://aka.ms/CLI_refstatus

Delete a guest configuration assignment.

az guestconfig guest-configuration-hcrp-assignment delete [--guest-configuration-assignment-name]
                                                          [--ids]
                                                          [--machine-name]
                                                          [--no-wait]
                                                          [--resource-group]
                                                          [--subscription]

Examples

Delete an guest configuration assignment

az guestconfig guest-configuration-hcrp-assignment delete --guest-configuration-assignment-name "SecureProtocol" --machine-name "myMachineName" --resource-group "myResourceGroupName"

Optional Parameters

The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.

--guest-configuration-assignment-name

Name of the guest configuration assignment.

Property Value
Parameter group: Resource Id Arguments
--ids

One or more resource IDs (space-delimited). It should be a complete resource ID containing all information of 'Resource Id' arguments. You should provide either --ids or other 'Resource Id' arguments.

Property Value
Parameter group: Resource Id Arguments
--machine-name

The name of the ARC machine.

Property Value
Parameter group: Resource Id Arguments
--no-wait

Do not wait for the long-running operation to finish.

Property Value
Default value: False
--resource-group -g

Name of resource group. You can configure the default group using az configure --defaults group=<name>.

Property Value
Parameter group: Resource Id Arguments
--subscription

Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.

Property Value
Parameter group: Resource Id Arguments
Global Parameters
--debug

Increase logging verbosity to show all debug logs.

Property Value
Default value: False
--help -h

Show this help message and exit.

--only-show-errors

Only show errors, suppressing warnings.

Property Value
Default value: False
--output -o

Output format.

Property Value
Default value: json
Accepted values: json, jsonc, none, table, tsv, yaml, yamlc
--query

JMESPath query string. See http://jmespath.org/ for more information and examples.

--verbose

Increase logging verbosity. Use --debug for full debug logs.

Property Value
Default value: False

az guestconfig guest-configuration-hcrp-assignment list

Experimental

Command group 'guestconfig guest-configuration-hcrp-assignment' is experimental and under development. Reference and support levels: https://aka.ms/CLI_refstatus

List all guest configuration assignments for an ARC machine.

az guestconfig guest-configuration-hcrp-assignment list --machine-name
                                                        --resource-group

Examples

List all guest configuration assignments for a virtual machine

az guestconfig guest-configuration-hcrp-assignment list --machine-name "myMachineName" --resource-group "myResourceGroupName"

Required Parameters

--machine-name

The name of the ARC machine.

--resource-group -g

Name of resource group. You can configure the default group using az configure --defaults group=<name>.

Global Parameters
--debug

Increase logging verbosity to show all debug logs.

Property Value
Default value: False
--help -h

Show this help message and exit.

--only-show-errors

Only show errors, suppressing warnings.

Property Value
Default value: False
--output -o

Output format.

Property Value
Default value: json
Accepted values: json, jsonc, none, table, tsv, yaml, yamlc
--query

JMESPath query string. See http://jmespath.org/ for more information and examples.

--subscription

Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.

--verbose

Increase logging verbosity. Use --debug for full debug logs.

Property Value
Default value: False

az guestconfig guest-configuration-hcrp-assignment show

Experimental

Command group 'guestconfig guest-configuration-hcrp-assignment' is experimental and under development. Reference and support levels: https://aka.ms/CLI_refstatus

Get information about a guest configuration assignment.

az guestconfig guest-configuration-hcrp-assignment show [--guest-configuration-assignment-name]
                                                        [--ids]
                                                        [--machine-name]
                                                        [--resource-group]
                                                        [--subscription]

Examples

Get a guest configuration assignment

az guestconfig guest-configuration-hcrp-assignment show --guest-configuration-assignment-name "SecureProtocol" --machine-name "myMachineName" --resource-group "myResourceGroupName"

Optional Parameters

The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.

--guest-configuration-assignment-name

The guest configuration assignment name.

Property Value
Parameter group: Resource Id Arguments
--ids

One or more resource IDs (space-delimited). It should be a complete resource ID containing all information of 'Resource Id' arguments. You should provide either --ids or other 'Resource Id' arguments.

Property Value
Parameter group: Resource Id Arguments
--machine-name

The name of the ARC machine.

Property Value
Parameter group: Resource Id Arguments
--resource-group -g

Name of resource group. You can configure the default group using az configure --defaults group=<name>.

Property Value
Parameter group: Resource Id Arguments
--subscription

Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.

Property Value
Parameter group: Resource Id Arguments
Global Parameters
--debug

Increase logging verbosity to show all debug logs.

Property Value
Default value: False
--help -h

Show this help message and exit.

--only-show-errors

Only show errors, suppressing warnings.

Property Value
Default value: False
--output -o

Output format.

Property Value
Default value: json
Accepted values: json, jsonc, none, table, tsv, yaml, yamlc
--query

JMESPath query string. See http://jmespath.org/ for more information and examples.

--verbose

Increase logging verbosity. Use --debug for full debug logs.

Property Value
Default value: False

az guestconfig guest-configuration-hcrp-assignment update

Experimental

Command group 'guestconfig guest-configuration-hcrp-assignment' is experimental and under development. Reference and support levels: https://aka.ms/CLI_refstatus

Creates an association between a ARC machine and guest configuration.

az guestconfig guest-configuration-hcrp-assignment update [--context]
                                                          [--guest-configuration-assignment-name]
                                                          [--guest-configuration-configuration-parameter]
                                                          [--guest-configuration-configuration-setting]
                                                          [--guest-configuration-name]
                                                          [--guest-configuration-version]
                                                          [--ids]
                                                          [--latest-assignment-report-assignment]
                                                          [--location]
                                                          [--machine-name]
                                                          [--name]
                                                          [--no-wait]
                                                          [--resource-group]
                                                          [--subscription]

Examples

Create or update guest configuration assignment

az guestconfig guest-configuration-hcrp-assignment update --guest-configuration-assignment-name "WhitelistedApplication" --machine-name "myMachineName" --guest-configuration-name "WhitelistedApplication" --location "westcentralus" --context "Azure policy" --guest-configuration-name "WhitelistedApplication" --guest-configuration-configuration-parameter name="[InstalledApplication]bwhitelistedapp;Name" value="NotePad,sql" --guest-configuration-configuration-setting action-after-reboot="ContinueConfiguration" configuration-mode="MonitorOnly" configuration-mode-frequency-mins=15 reboot-if-needed="False" --guest-configuration-version "1.*" --resource-group "myResourceGroupName"

Optional Parameters

The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.

--context

The source which initiated the guest configuration assignment. Ex: Azure Policy.

--guest-configuration-assignment-name

Name of the guest configuration assignment.

Property Value
Parameter group: Resource Id Arguments
--guest-configuration-configuration-parameter

The configuration parameters for the guest configuration.

Usage: --guest-configuration-configuration-parameter name=XX value=XX

name: Name of the configuration parameter. value: Value of the configuration parameter.

Multiple actions can be specified by using more than one --guest-configuration-configuration-parameter argument.

--guest-configuration-configuration-setting

The configuration setting for the guest configuration.

Usage: --guest-configuration-configuration-setting configuration-mode=XX allow-module-overwrite=XX action-after-reboot=XX refresh-frequency-mins=XX reboot-if-needed=XX configuration-mode-frequency-mins=XX

configuration-mode: Specifies how the LCM(Local Configuration Manager) actually applies the configuration to the target nodes. Possible values are ApplyOnly, ApplyAndMonitor, and ApplyAndAutoCorrect. allow-module-overwrite: If true - new configurations downloaded from the pull service are allowed to overwrite the old ones on the target node. Otherwise, false action-after-reboot: Specifies what happens after a reboot during the application of a configuration. The possible values are ContinueConfiguration and StopConfiguration refresh-frequency-mins: The time interval, in minutes, at which the LCM checks a pull service to get updated configurations. This value is ignored if the LCM is not configured in pull mode. The default value is 30. reboot-if-needed: Set this to true to automatically reboot the node after a configuration that requires reboot is applied. Otherwise, you will have to manually reboot the node for any configuration that requires it. The default value is false. To use this setting when a reboot condition is enacted by something other than DSC (such as Windows Installer), combine this setting with the xPendingReboot module. configuration-mode-frequency-mins: How often, in minutes, the current configuration is checked and applied. This property is ignored if the ConfigurationMode property is set to ApplyOnly. The default value is 15.

--guest-configuration-name

Name of the guest configuration.

--guest-configuration-version

Version of the guest configuration.

--ids

One or more resource IDs (space-delimited). It should be a complete resource ID containing all information of 'Resource Id' arguments. You should provide either --ids or other 'Resource Id' arguments.

Property Value
Parameter group: Resource Id Arguments
--latest-assignment-report-assignment

Configuration details of the guest configuration assignment. Expected value: json-string/@json-file.

--location -l

Location. Values from: az account list-locations. You can configure the default location using az configure --defaults location=<location>.

--machine-name

The name of the ARC machine.

Property Value
Parameter group: Resource Id Arguments
--name

Name of the guest configuration assignment.

--no-wait

Do not wait for the long-running operation to finish.

Property Value
Default value: False
--resource-group -g

Name of resource group. You can configure the default group using az configure --defaults group=<name>.

Property Value
Parameter group: Resource Id Arguments
--subscription

Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.

Property Value
Parameter group: Resource Id Arguments
Global Parameters
--debug

Increase logging verbosity to show all debug logs.

Property Value
Default value: False
--help -h

Show this help message and exit.

--only-show-errors

Only show errors, suppressing warnings.

Property Value
Default value: False
--output -o

Output format.

Property Value
Default value: json
Accepted values: json, jsonc, none, table, tsv, yaml, yamlc
--query

JMESPath query string. See http://jmespath.org/ for more information and examples.

--verbose

Increase logging verbosity. Use --debug for full debug logs.

Property Value
Default value: False

az guestconfig guest-configuration-hcrp-assignment wait

Experimental

Command group 'guestconfig guest-configuration-hcrp-assignment' is experimental and under development. Reference and support levels: https://aka.ms/CLI_refstatus

Place the CLI in a waiting state until a condition of the guestconfig guest-configuration-hcrp-assignment is met.

az guestconfig guest-configuration-hcrp-assignment wait [--created]
                                                        [--custom]
                                                        [--deleted]
                                                        [--exists]
                                                        [--guest-configuration-assignment-name]
                                                        [--ids]
                                                        [--interval]
                                                        [--machine-name]
                                                        [--resource-group]
                                                        [--subscription]
                                                        [--timeout]
                                                        [--updated]

Examples

Pause executing next line of CLI script until the guestconfig guest-configuration-hcrp-assignment is successfully created.

az guestconfig guest-configuration-hcrp-assignment wait --guest-configuration-assignment-name "SecureProtocol" --machine-name "myMachineName" --resource-group "myResourceGroupName" --created

Pause executing next line of CLI script until the guestconfig guest-configuration-hcrp-assignment is successfully deleted.

az guestconfig guest-configuration-hcrp-assignment wait --guest-configuration-assignment-name "SecureProtocol" --machine-name "myMachineName" --resource-group "myResourceGroupName" --deleted

Optional Parameters

The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.

--created

Wait until created with 'provisioningState' at 'Succeeded'.

Property Value
Parameter group: Wait Condition Arguments
Default value: False
--custom

Wait until the condition satisfies a custom JMESPath query. E.g. provisioningState!='InProgress', instanceView.statuses[?code=='PowerState/running'].

Property Value
Parameter group: Wait Condition Arguments
--deleted

Wait until deleted.

Property Value
Parameter group: Wait Condition Arguments
Default value: False
--exists

Wait until the resource exists.

Property Value
Parameter group: Wait Condition Arguments
Default value: False
--guest-configuration-assignment-name

The guest configuration assignment name.

Property Value
Parameter group: Resource Id Arguments
--ids

One or more resource IDs (space-delimited). It should be a complete resource ID containing all information of 'Resource Id' arguments. You should provide either --ids or other 'Resource Id' arguments.

Property Value
Parameter group: Resource Id Arguments
--interval

Polling interval in seconds.

Property Value
Parameter group: Wait Condition Arguments
Default value: 30
--machine-name

The name of the ARC machine.

Property Value
Parameter group: Resource Id Arguments
--resource-group -g

Name of resource group. You can configure the default group using az configure --defaults group=<name>.

Property Value
Parameter group: Resource Id Arguments
--subscription

Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.

Property Value
Parameter group: Resource Id Arguments
--timeout

Maximum wait in seconds.

Property Value
Parameter group: Wait Condition Arguments
Default value: 3600
--updated

Wait until updated with provisioningState at 'Succeeded'.

Property Value
Parameter group: Wait Condition Arguments
Default value: False
Global Parameters
--debug

Increase logging verbosity to show all debug logs.

Property Value
Default value: False
--help -h

Show this help message and exit.

--only-show-errors

Only show errors, suppressing warnings.

Property Value
Default value: False
--output -o

Output format.

Property Value
Default value: json
Accepted values: json, jsonc, none, table, tsv, yaml, yamlc
--query

JMESPath query string. See http://jmespath.org/ for more information and examples.

--verbose

Increase logging verbosity. Use --debug for full debug logs.

Property Value
Default value: False