Documentation
¶
Index ¶
- type ActionAfterReboot
- type Assignment
- type AssignmentInfo
- type AssignmentList
- type AssignmentProperties
- type AssignmentReport
- type AssignmentReportDetails
- type AssignmentReportList
- type AssignmentReportProperties
- type AssignmentReportResource
- type AssignmentReportResourceComplianceReason
- type AssignmentReportsClient
- type AssignmentReportsClientGetOptions
- type AssignmentReportsClientGetResponse
- type AssignmentReportsClientListOptions
- type AssignmentReportsClientListResponse
- type AssignmentReportsVMSSClient
- func (client *AssignmentReportsVMSSClient) Get(ctx context.Context, resourceGroupName string, vmssName string, name string, ...) (AssignmentReportsVMSSClientGetResponse, error)
- func (client *AssignmentReportsVMSSClient) NewListPager(resourceGroupName string, vmssName string, name string, ...) *runtime.Pager[AssignmentReportsVMSSClientListResponse]
- type AssignmentReportsVMSSClientGetOptions
- type AssignmentReportsVMSSClientGetResponse
- type AssignmentReportsVMSSClientListOptions
- type AssignmentReportsVMSSClientListResponse
- type AssignmentType
- type AssignmentsClient
- func (client *AssignmentsClient) CreateOrUpdate(ctx context.Context, guestConfigurationAssignmentName string, ...) (AssignmentsClientCreateOrUpdateResponse, error)
- func (client *AssignmentsClient) Delete(ctx context.Context, resourceGroupName string, ...) (AssignmentsClientDeleteResponse, error)
- func (client *AssignmentsClient) Get(ctx context.Context, resourceGroupName string, ...) (AssignmentsClientGetResponse, error)
- func (client *AssignmentsClient) NewListPager(resourceGroupName string, vmName string, options *AssignmentsClientListOptions) *runtime.Pager[AssignmentsClientListResponse]
- func (client *AssignmentsClient) NewRGListPager(resourceGroupName string, options *AssignmentsClientRGListOptions) *runtime.Pager[AssignmentsClientRGListResponse]
- func (client *AssignmentsClient) NewSubscriptionListPager(options *AssignmentsClientSubscriptionListOptions) *runtime.Pager[AssignmentsClientSubscriptionListResponse]
- type AssignmentsClientCreateOrUpdateOptions
- type AssignmentsClientCreateOrUpdateResponse
- type AssignmentsClientDeleteOptions
- type AssignmentsClientDeleteResponse
- type AssignmentsClientGetOptions
- type AssignmentsClientGetResponse
- type AssignmentsClientListOptions
- type AssignmentsClientListResponse
- type AssignmentsClientRGListOptions
- type AssignmentsClientRGListResponse
- type AssignmentsClientSubscriptionListOptions
- type AssignmentsClientSubscriptionListResponse
- type AssignmentsVMSSClient
- func (client *AssignmentsVMSSClient) Delete(ctx context.Context, resourceGroupName string, vmssName string, name string, ...) (AssignmentsVMSSClientDeleteResponse, error)
- func (client *AssignmentsVMSSClient) Get(ctx context.Context, resourceGroupName string, vmssName string, name string, ...) (AssignmentsVMSSClientGetResponse, error)
- func (client *AssignmentsVMSSClient) NewListPager(resourceGroupName string, vmssName string, ...) *runtime.Pager[AssignmentsVMSSClientListResponse]
- type AssignmentsVMSSClientDeleteOptions
- type AssignmentsVMSSClientDeleteResponse
- type AssignmentsVMSSClientGetOptions
- type AssignmentsVMSSClientGetResponse
- type AssignmentsVMSSClientListOptions
- type AssignmentsVMSSClientListResponse
- type ClientFactory
- func (c *ClientFactory) NewAssignmentReportsClient() *AssignmentReportsClient
- func (c *ClientFactory) NewAssignmentReportsVMSSClient() *AssignmentReportsVMSSClient
- func (c *ClientFactory) NewAssignmentsClient() *AssignmentsClient
- func (c *ClientFactory) NewAssignmentsVMSSClient() *AssignmentsVMSSClient
- func (c *ClientFactory) NewHCRPAssignmentReportsClient() *HCRPAssignmentReportsClient
- func (c *ClientFactory) NewHCRPAssignmentsClient() *HCRPAssignmentsClient
- func (c *ClientFactory) NewOperationsClient() *OperationsClient
- type CommonAssignmentReport
- type ComplianceStatus
- type ConfigurationInfo
- type ConfigurationMode
- type ConfigurationParameter
- type ConfigurationSetting
- type CreatedByType
- type ErrorResponse
- type ErrorResponseError
- type HCRPAssignmentReportsClient
- type HCRPAssignmentReportsClientGetOptions
- type HCRPAssignmentReportsClientGetResponse
- type HCRPAssignmentReportsClientListOptions
- type HCRPAssignmentReportsClientListResponse
- type HCRPAssignmentsClient
- func (client *HCRPAssignmentsClient) CreateOrUpdate(ctx context.Context, guestConfigurationAssignmentName string, ...) (HCRPAssignmentsClientCreateOrUpdateResponse, error)
- func (client *HCRPAssignmentsClient) Delete(ctx context.Context, resourceGroupName string, ...) (HCRPAssignmentsClientDeleteResponse, error)
- func (client *HCRPAssignmentsClient) Get(ctx context.Context, resourceGroupName string, ...) (HCRPAssignmentsClientGetResponse, error)
- func (client *HCRPAssignmentsClient) NewListPager(resourceGroupName string, machineName string, ...) *runtime.Pager[HCRPAssignmentsClientListResponse]
- type HCRPAssignmentsClientCreateOrUpdateOptions
- type HCRPAssignmentsClientCreateOrUpdateResponse
- type HCRPAssignmentsClientDeleteOptions
- type HCRPAssignmentsClientDeleteResponse
- type HCRPAssignmentsClientGetOptions
- type HCRPAssignmentsClientGetResponse
- type HCRPAssignmentsClientListOptions
- type HCRPAssignmentsClientListResponse
- type Kind
- type Navigation
- type Operation
- type OperationDisplay
- type OperationList
- type OperationProperties
- type OperationsClient
- type OperationsClientListOptions
- type OperationsClientListResponse
- type ProvisioningState
- type ProxyResource
- type Resource
- type SystemData
- type Type
- type VMInfo
- type VMSSVMInfo
Examples ¶
- AssignmentReportsClient.Get
- AssignmentReportsClient.List
- AssignmentReportsVMSSClient.Get
- AssignmentReportsVMSSClient.NewListPager
- AssignmentsClient.CreateOrUpdate
- AssignmentsClient.Delete
- AssignmentsClient.Get
- AssignmentsClient.NewListPager
- AssignmentsClient.NewRGListPager
- AssignmentsClient.NewSubscriptionListPager
- AssignmentsVMSSClient.Delete
- AssignmentsVMSSClient.Get
- AssignmentsVMSSClient.NewListPager
- HCRPAssignmentReportsClient.Get
- HCRPAssignmentReportsClient.List
- HCRPAssignmentsClient.CreateOrUpdate
- HCRPAssignmentsClient.Delete
- HCRPAssignmentsClient.Get
- HCRPAssignmentsClient.NewListPager
- OperationsClient.NewListPager
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ActionAfterReboot ¶
type ActionAfterReboot string
ActionAfterReboot - Specifies what happens after a reboot during the application of a configuration. The possible values are ContinueConfiguration and StopConfiguration
const ( ActionAfterRebootContinueConfiguration ActionAfterReboot = "ContinueConfiguration" ActionAfterRebootStopConfiguration ActionAfterReboot = "StopConfiguration" )
func PossibleActionAfterRebootValues ¶
func PossibleActionAfterRebootValues() []ActionAfterReboot
PossibleActionAfterRebootValues returns the possible values for the ActionAfterReboot const type.
type Assignment ¶
type Assignment struct {
// Region where the VM is located.
Location *string
// Name of the guest configuration assignment.
Name *string
// Properties of the Guest configuration assignment.
Properties *AssignmentProperties
// READ-ONLY; ARM resource id of the guest configuration assignment.
ID *string
// READ-ONLY; Azure Resource Manager metadata containing createdBy and modifiedBy information.
SystemData *SystemData
// READ-ONLY; The type of the resource.
Type *string
}
Assignment - Guest configuration assignment is an association between a machine and guest configuration.
func (Assignment) MarshalJSON ¶
func (a Assignment) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type Assignment.
func (*Assignment) UnmarshalJSON ¶
func (a *Assignment) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type Assignment.
type AssignmentInfo ¶
type AssignmentInfo struct {
// Information about the configuration.
Configuration *ConfigurationInfo
// READ-ONLY; Name of the guest configuration assignment.
Name *string
}
AssignmentInfo - Information about the guest configuration assignment.
func (AssignmentInfo) MarshalJSON ¶
func (a AssignmentInfo) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type AssignmentInfo.
func (*AssignmentInfo) UnmarshalJSON ¶
func (a *AssignmentInfo) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type AssignmentInfo.
type AssignmentList ¶
type AssignmentList struct {
// Result of the list guest configuration assignment operation.
Value []*Assignment
}
AssignmentList - The response of the list guest configuration assignment operation.
func (AssignmentList) MarshalJSON ¶
func (a AssignmentList) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type AssignmentList.
func (*AssignmentList) UnmarshalJSON ¶
func (a *AssignmentList) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type AssignmentList.
type AssignmentProperties ¶
type AssignmentProperties struct {
// The source which initiated the guest configuration assignment. Ex: Azure Policy
Context *string
// The guest configuration to assign.
GuestConfiguration *Navigation
// Last reported guest configuration assignment report.
LatestAssignmentReport *CommonAssignmentReport
// The list of VM Compliance data for VMSS
VmssVMList []*VMSSVMInfo
// READ-ONLY; Combined hash of the configuration package and parameters.
AssignmentHash *string
// READ-ONLY; A value indicating compliance status of the machine for the assigned guest configuration.
ComplianceStatus *ComplianceStatus
// READ-ONLY; Date and time when last compliance status was checked.
LastComplianceStatusChecked *time.Time
// READ-ONLY; Id of the latest report for the guest configuration assignment.
LatestReportID *string
// READ-ONLY; parameter hash for the guest configuration assignment.
ParameterHash *string
// READ-ONLY; The provisioning state, which only appears in the response.
ProvisioningState *ProvisioningState
// READ-ONLY; Type of the resource - VMSS / VM
ResourceType *string
// READ-ONLY; VM resource Id.
TargetResourceID *string
}
AssignmentProperties - Guest configuration assignment properties.
func (AssignmentProperties) MarshalJSON ¶
func (a AssignmentProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type AssignmentProperties.
func (*AssignmentProperties) UnmarshalJSON ¶
func (a *AssignmentProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type AssignmentProperties.
type AssignmentReport ¶
type AssignmentReport struct {
// Properties of the guest configuration report.
Properties *AssignmentReportProperties
// READ-ONLY; ARM resource id of the report for the guest configuration assignment.
ID *string
// READ-ONLY; GUID that identifies the guest configuration assignment report under a subscription, resource group.
Name *string
}
AssignmentReport - Report for the guest configuration assignment. Report contains information such as compliance status, reason, and more.
func (AssignmentReport) MarshalJSON ¶
func (a AssignmentReport) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type AssignmentReport.
func (*AssignmentReport) UnmarshalJSON ¶
func (a *AssignmentReport) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type AssignmentReport.
type AssignmentReportDetails ¶
type AssignmentReportDetails struct {
// The list of resources for which guest configuration assignment compliance is checked.
Resources []*AssignmentReportResource
// READ-ONLY; A value indicating compliance status of the machine for the assigned guest configuration.
ComplianceStatus *ComplianceStatus
// READ-ONLY; End date and time of the guest configuration assignment compliance status check.
EndTime *time.Time
// READ-ONLY; GUID of the report.
JobID *string
// READ-ONLY; Type of report, Consistency or Initial
OperationType *Type
// READ-ONLY; Start date and time of the guest configuration assignment compliance status check.
StartTime *time.Time
}
AssignmentReportDetails - Details of the guest configuration assignment report.
func (AssignmentReportDetails) MarshalJSON ¶
func (a AssignmentReportDetails) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type AssignmentReportDetails.
func (*AssignmentReportDetails) UnmarshalJSON ¶
func (a *AssignmentReportDetails) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type AssignmentReportDetails.
type AssignmentReportList ¶
type AssignmentReportList struct {
// List of reports for the guest configuration. Report contains information such as compliance status, reason and more.
Value []*AssignmentReport
}
AssignmentReportList - List of guest configuration assignment reports.
func (AssignmentReportList) MarshalJSON ¶
func (a AssignmentReportList) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type AssignmentReportList.
func (*AssignmentReportList) UnmarshalJSON ¶
func (a *AssignmentReportList) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type AssignmentReportList.
type AssignmentReportProperties ¶
type AssignmentReportProperties struct {
// Configuration details of the guest configuration assignment.
Assignment *AssignmentInfo
// Details of the assignment report.
Details *AssignmentReportDetails
// Information about the VM.
VM *VMInfo
// READ-ONLY; A value indicating compliance status of the machine for the assigned guest configuration.
ComplianceStatus *ComplianceStatus
// READ-ONLY; End date and time of the guest configuration assignment compliance status check.
EndTime *time.Time
// READ-ONLY; GUID that identifies the guest configuration assignment report under a subscription, resource group.
ReportID *string
// READ-ONLY; Start date and time of the guest configuration assignment compliance status check.
StartTime *time.Time
// READ-ONLY; Azure resource Id of the VMSS.
VmssResourceID *string
}
AssignmentReportProperties - Report for the guest configuration assignment. Report contains information such as compliance status, reason, and more.
func (AssignmentReportProperties) MarshalJSON ¶
func (a AssignmentReportProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type AssignmentReportProperties.
func (*AssignmentReportProperties) UnmarshalJSON ¶
func (a *AssignmentReportProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type AssignmentReportProperties.
type AssignmentReportResource ¶
type AssignmentReportResource struct {
// Compliance reason and reason code for a resource.
Reasons []*AssignmentReportResourceComplianceReason
// READ-ONLY; A value indicating compliance status of the machine for the assigned guest configuration.
ComplianceStatus *ComplianceStatus
// READ-ONLY; Properties of a guest configuration assignment resource.
Properties any
// READ-ONLY; Name of the guest configuration assignment resource setting.
ResourceID *string
}
AssignmentReportResource - The guest configuration assignment resource.
func (AssignmentReportResource) MarshalJSON ¶
func (a AssignmentReportResource) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type AssignmentReportResource.
func (*AssignmentReportResource) UnmarshalJSON ¶
func (a *AssignmentReportResource) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type AssignmentReportResource.
type AssignmentReportResourceComplianceReason ¶
type AssignmentReportResourceComplianceReason struct {
// READ-ONLY; Code for the compliance of the guest configuration assignment resource.
Code *string
// READ-ONLY; Reason for the compliance of the guest configuration assignment resource.
Phrase *string
}
AssignmentReportResourceComplianceReason - Reason and code for the compliance of the guest configuration assignment resource.
func (AssignmentReportResourceComplianceReason) MarshalJSON ¶
func (a AssignmentReportResourceComplianceReason) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type AssignmentReportResourceComplianceReason.
func (*AssignmentReportResourceComplianceReason) UnmarshalJSON ¶
func (a *AssignmentReportResourceComplianceReason) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type AssignmentReportResourceComplianceReason.
type AssignmentReportsClient ¶
type AssignmentReportsClient struct {
// contains filtered or unexported fields
}
AssignmentReportsClient contains the methods for the GuestConfigurationAssignmentReports group. Don't use this type directly, use NewAssignmentReportsClient() instead.
func NewAssignmentReportsClient ¶
func NewAssignmentReportsClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*AssignmentReportsClient, error)
NewAssignmentReportsClient creates a new instance of AssignmentReportsClient with the specified values.
- subscriptionID - Subscription ID which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call.
- credential - used to authorize requests. Usually a credential from azidentity.
- options - pass nil to accept the default values.
func (*AssignmentReportsClient) Get ¶
func (client *AssignmentReportsClient) Get(ctx context.Context, resourceGroupName string, guestConfigurationAssignmentName string, reportID string, vmName string, options *AssignmentReportsClientGetOptions) (AssignmentReportsClientGetResponse, error)
Get - Get a report for the guest configuration assignment, by reportId. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2022-01-25
- resourceGroupName - The resource group name.
- guestConfigurationAssignmentName - The guest configuration assignment name.
- reportID - The GUID for the guest configuration assignment report.
- vmName - The name of the virtual machine.
- options - AssignmentReportsClientGetOptions contains the optional parameters for the AssignmentReportsClient.Get method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/guestconfiguration/resource-manager/Microsoft.GuestConfiguration/stable/2022-01-25/examples/getGuestConfigurationAssignmentReportById.json
package main
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/guestconfiguration/armguestconfiguration"
)
func main() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armguestconfiguration.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
res, err := clientFactory.NewAssignmentReportsClient().Get(ctx, "myResourceGroupName", "AuditSecureProtocol", "7367cbb8-ae99-47d0-a33b-a283564d2cb1", "myvm", nil)
if err != nil {
log.Fatalf("failed to finish the request: %v", err)
}
// You could use response here. We use blank identifier for just demo purposes.
_ = res
// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// res.AssignmentReport = armguestconfiguration.AssignmentReport{
// Name: to.Ptr("7367cbb8-ae99-47d0-a33b-a283564d2cb1"),
// ID: to.Ptr("/subscriptions/mysubscriptionid/resourceGroups/myResourceGroupName/providers/Microsoft.Compute/virtualMachines/myvm/providers/Microsoft.GuestConfiguration/guestConfigurationAssignments/AuditSecureProtocol/reports/7367cbb8-ae99-47d0-a33b-a283564d2cb1"),
// Properties: &armguestconfiguration.AssignmentReportProperties{
// Assignment: &armguestconfiguration.AssignmentInfo{
// Name: to.Ptr("AuditSecureProtocol"),
// Configuration: &armguestconfiguration.ConfigurationInfo{
// Name: to.Ptr("AuditSecureProtocol"),
// Version: to.Ptr("1.0.0.0"),
// },
// },
// ComplianceStatus: to.Ptr(armguestconfiguration.ComplianceStatusCompliant),
// EndTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-29T22:14:13.000Z"); return t}()),
// ReportID: to.Ptr("7367cbb8-ae99-47d0-a33b-a283564d2cb1"),
// StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-29T22:13:53.000Z"); return t}()),
// VM: &armguestconfiguration.VMInfo{
// ID: to.Ptr("/subscriptions/mysubscriptionid/resourceGroups/myResourceGroupName/providers/Microsoft.Compute/virtualMachines/myvm"),
// UUID: to.Ptr("vmuuid"),
// },
// Details: &armguestconfiguration.AssignmentReportDetails{
// ComplianceStatus: to.Ptr(armguestconfiguration.ComplianceStatusCompliant),
// EndTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-29T22:14:13.000Z"); return t}()),
// JobID: to.Ptr("7367cbb8-ae99-47d0-a33b-a283564d2cb1"),
// OperationType: to.Ptr(armguestconfiguration.TypeConsistency),
// Resources: []*armguestconfiguration.AssignmentReportResource{
// {
// ComplianceStatus: to.Ptr(armguestconfiguration.ComplianceStatusCompliant),
// Properties: map[string]any{
// "ConfigurationName": "IsWebServerSecure",
// "DependsOn": nil,
// "IsSingleInstance": "Yes",
// "ModuleName": "SecureProtocolWebServer",
// "ModuleVersion": "1.0.0.3",
// "Protocols":[]any{
// map[string]any{
// "Ensure": "Absent",
// "Protocol": "SSL 2.0",
// },
// map[string]any{
// "Ensure": "Absent",
// "Protocol": "SSL 3.0",
// },
// map[string]any{
// "Ensure": "Absent",
// "Protocol": "TLS 1.0",
// },
// map[string]any{
// "Ensure": "Absent",
// "Protocol": "PCT 1.0",
// },
// map[string]any{
// "Ensure": "Absent",
// "Protocol": "Multi-Protocol Unified Hello",
// },
// map[string]any{
// "Ensure": "Absent",
// "Protocol": "TLS 1.1",
// },
// map[string]any{
// "Ensure": "Absent",
// "Protocol": "TLS 1.2",
// },
// },
// "PsDscRunAsCredential": nil,
// "Reasons": nil,
// "ResourceId": "[SecureWebServer]s1",
// "SourceInfo": nil,
// },
// Reasons: []*armguestconfiguration.AssignmentReportResourceComplianceReason{
// {
// Code: to.Ptr("DSC::RESOURCE::SUCCESS"),
// Phrase: to.Ptr("Operation successful."),
// }},
// }},
// StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-29T22:13:53.000Z"); return t}()),
// },
// },
// }
}
func (*AssignmentReportsClient) List ¶
func (client *AssignmentReportsClient) List(ctx context.Context, resourceGroupName string, guestConfigurationAssignmentName string, vmName string, options *AssignmentReportsClientListOptions) (AssignmentReportsClientListResponse, error)
List - List all reports for the guest configuration assignment, latest report first. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2022-01-25
- resourceGroupName - The resource group name.
- guestConfigurationAssignmentName - The guest configuration assignment name.
- vmName - The name of the virtual machine.
- options - AssignmentReportsClientListOptions contains the optional parameters for the AssignmentReportsClient.List method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/guestconfiguration/resource-manager/Microsoft.GuestConfiguration/stable/2022-01-25/examples/listAllGuestConfigurationAssignmentReports.json
package main
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/guestconfiguration/armguestconfiguration"
)
func main() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armguestconfiguration.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
res, err := clientFactory.NewAssignmentReportsClient().List(ctx, "myResourceGroupName", "AuditSecureProtocol", "myVMName", nil)
if err != nil {
log.Fatalf("failed to finish the request: %v", err)
}
// You could use response here. We use blank identifier for just demo purposes.
_ = res
// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// res.AssignmentReportList = armguestconfiguration.AssignmentReportList{
// Value: []*armguestconfiguration.AssignmentReport{
// {
// Name: to.Ptr("7367cbb8-ae99-47d0-a33b-a283564d2cb1"),
// ID: to.Ptr("/subscriptions/mysubscriptionid/resourceGroups/myResourceGroupName/providers/Microsoft.Compute/virtualMachines/myvm/providers/Microsoft.GuestConfiguration/guestConfigurationAssignments/AuditSecureProtocol/reports/7367cbb8-ae99-47d0-a33b-a283564d2cb1"),
// Properties: &armguestconfiguration.AssignmentReportProperties{
// Assignment: &armguestconfiguration.AssignmentInfo{
// Name: to.Ptr("AuditSecureProtocol"),
// Configuration: &armguestconfiguration.ConfigurationInfo{
// Name: to.Ptr("AuditSecureProtocol"),
// },
// },
// ComplianceStatus: to.Ptr(armguestconfiguration.ComplianceStatusCompliant),
// EndTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-29T22:14:13.000Z"); return t}()),
// ReportID: to.Ptr("7367cbb8-ae99-47d0-a33b-a283564d2cb1"),
// StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-29T22:13:53.000Z"); return t}()),
// VM: &armguestconfiguration.VMInfo{
// ID: to.Ptr("/subscriptions/mysubscriptionid/resourceGroups/myResourceGroupName/providers/Microsoft.Compute/virtualMachines/myvm"),
// UUID: to.Ptr("vmuuid"),
// },
// },
// },
// {
// Name: to.Ptr("41ee2caf-48f9-4999-a793-82ec7c6beb2c"),
// ID: to.Ptr("/subscriptions/mysubscriptionid/resourceGroups/myResourceGroupName/providers/Microsoft.Compute/virtualMachines/myvm/providers/Microsoft.GuestConfiguration/guestConfigurationAssignments/AuditSecureProtocol/reports/41ee2caf-48f9-4999-a793-82ec7c6beb2c"),
// Properties: &armguestconfiguration.AssignmentReportProperties{
// Assignment: &armguestconfiguration.AssignmentInfo{
// Name: to.Ptr("AuditSecureProtocol"),
// Configuration: &armguestconfiguration.ConfigurationInfo{
// Name: to.Ptr("AuditSecureProtocol"),
// },
// },
// ComplianceStatus: to.Ptr(armguestconfiguration.ComplianceStatusCompliant),
// EndTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-29T20:14:13.000Z"); return t}()),
// ReportID: to.Ptr("41ee2caf-48f9-4999-a793-82ec7c6beb2c"),
// StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-29T20:13:53.000Z"); return t}()),
// VM: &armguestconfiguration.VMInfo{
// ID: to.Ptr("/subscriptions/mysubscriptionid/resourceGroups/myResourceGroupName/providers/Microsoft.Compute/virtualMachines/myvm"),
// UUID: to.Ptr("vmuuid"),
// },
// },
// }},
// }
}
type AssignmentReportsClientGetOptions ¶
type AssignmentReportsClientGetOptions struct {
}
AssignmentReportsClientGetOptions contains the optional parameters for the AssignmentReportsClient.Get method.
type AssignmentReportsClientGetResponse ¶
type AssignmentReportsClientGetResponse struct {
// Report for the guest configuration assignment. Report contains information such as compliance status, reason, and more.
AssignmentReport
}
AssignmentReportsClientGetResponse contains the response from method AssignmentReportsClient.Get.
type AssignmentReportsClientListOptions ¶
type AssignmentReportsClientListOptions struct {
}
AssignmentReportsClientListOptions contains the optional parameters for the AssignmentReportsClient.List method.
type AssignmentReportsClientListResponse ¶
type AssignmentReportsClientListResponse struct {
// List of guest configuration assignment reports.
AssignmentReportList
}
AssignmentReportsClientListResponse contains the response from method AssignmentReportsClient.List.
type AssignmentReportsVMSSClient ¶
type AssignmentReportsVMSSClient struct {
// contains filtered or unexported fields
}
AssignmentReportsVMSSClient contains the methods for the GuestConfigurationAssignmentReportsVMSS group. Don't use this type directly, use NewAssignmentReportsVMSSClient() instead.
func NewAssignmentReportsVMSSClient ¶
func NewAssignmentReportsVMSSClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*AssignmentReportsVMSSClient, error)
NewAssignmentReportsVMSSClient creates a new instance of AssignmentReportsVMSSClient with the specified values.
- subscriptionID - Subscription ID which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call.
- credential - used to authorize requests. Usually a credential from azidentity.
- options - pass nil to accept the default values.
func (*AssignmentReportsVMSSClient) Get ¶
func (client *AssignmentReportsVMSSClient) Get(ctx context.Context, resourceGroupName string, vmssName string, name string, id string, options *AssignmentReportsVMSSClientGetOptions) (AssignmentReportsVMSSClientGetResponse, error)
Get - Get a report for the VMSS guest configuration assignment, by reportId. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2022-01-25
- resourceGroupName - The resource group name.
- vmssName - The name of the virtual machine scale set.
- name - The guest configuration assignment name.
- id - The GUID for the guest configuration assignment report.
- options - AssignmentReportsVMSSClientGetOptions contains the optional parameters for the AssignmentReportsVMSSClient.Get method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/guestconfiguration/resource-manager/Microsoft.GuestConfiguration/stable/2022-01-25/examples/getVMSSGuestConfigurationAssignmentReportById.json
package main
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/guestconfiguration/armguestconfiguration"
)
func main() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armguestconfiguration.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
res, err := clientFactory.NewAssignmentReportsVMSSClient().Get(ctx, "myResourceGroupName", "myvmss", "AuditSecureProtocol", "7367cbb8-ae99-47d0-a33b-a283564d2cb1", nil)
if err != nil {
log.Fatalf("failed to finish the request: %v", err)
}
// You could use response here. We use blank identifier for just demo purposes.
_ = res
// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// res.AssignmentReport = armguestconfiguration.AssignmentReport{
// Name: to.Ptr("7367cbb8-ae99-47d0-a33b-a283564d2cb1"),
// ID: to.Ptr("/subscriptions/mysubscriptionid/resourceGroups/myResourceGroupName/providers/Microsoft.Compute/virtualMachineScaleSets/myvmss/providers/Microsoft.GuestConfiguration/guestConfigurationAssignments/AuditSecureProtocol/reports/7367cbb8-ae99-47d0-a33b-a283564d2cb1"),
// Properties: &armguestconfiguration.AssignmentReportProperties{
// Assignment: &armguestconfiguration.AssignmentInfo{
// Name: to.Ptr("AuditSecureProtocol"),
// Configuration: &armguestconfiguration.ConfigurationInfo{
// Name: to.Ptr("AuditSecureProtocol"),
// Version: to.Ptr("1.0.0.0"),
// },
// },
// ComplianceStatus: to.Ptr(armguestconfiguration.ComplianceStatusCompliant),
// EndTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-29T22:14:13.000Z"); return t}()),
// ReportID: to.Ptr("7367cbb8-ae99-47d0-a33b-a283564d2cb1"),
// StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-29T22:13:53.000Z"); return t}()),
// VM: &armguestconfiguration.VMInfo{
// ID: to.Ptr("/subscriptions/mySubscriptionid/resourceGroups/myResourceGroupName/providers/Microsoft.Compute/virtualMachineScaleSets/myvmss/virtualMachines/1"),
// UUID: to.Ptr("vmuuid"),
// },
// Details: &armguestconfiguration.AssignmentReportDetails{
// ComplianceStatus: to.Ptr(armguestconfiguration.ComplianceStatusCompliant),
// EndTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-29T22:14:13.000Z"); return t}()),
// JobID: to.Ptr("7367cbb8-ae99-47d0-a33b-a283564d2cb1"),
// OperationType: to.Ptr(armguestconfiguration.TypeConsistency),
// Resources: []*armguestconfiguration.AssignmentReportResource{
// {
// ComplianceStatus: to.Ptr(armguestconfiguration.ComplianceStatusCompliant),
// Properties: map[string]any{
// "ConfigurationName": "IsWebServerSecure",
// "DependsOn": nil,
// "IsSingleInstance": "Yes",
// "ModuleName": "SecureProtocolWebServer",
// "ModuleVersion": "1.0.0.3",
// "Protocols":[]any{
// map[string]any{
// "Ensure": "Absent",
// "Protocol": "SSL 2.0",
// },
// map[string]any{
// "Ensure": "Absent",
// "Protocol": "SSL 3.0",
// },
// map[string]any{
// "Ensure": "Absent",
// "Protocol": "TLS 1.0",
// },
// map[string]any{
// "Ensure": "Absent",
// "Protocol": "PCT 1.0",
// },
// map[string]any{
// "Ensure": "Absent",
// "Protocol": "Multi-Protocol Unified Hello",
// },
// map[string]any{
// "Ensure": "Absent",
// "Protocol": "TLS 1.1",
// },
// map[string]any{
// "Ensure": "Absent",
// "Protocol": "TLS 1.2",
// },
// },
// "PsDscRunAsCredential": nil,
// "Reasons": nil,
// "ResourceId": "[SecureWebServer]s1",
// "SourceInfo": nil,
// },
// Reasons: []*armguestconfiguration.AssignmentReportResourceComplianceReason{
// {
// Code: to.Ptr("DSC::RESOURCE::SUCCESS"),
// Phrase: to.Ptr("Operation successful."),
// }},
// }},
// StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-29T22:13:53.000Z"); return t}()),
// },
// },
// }
}
func (*AssignmentReportsVMSSClient) NewListPager ¶
func (client *AssignmentReportsVMSSClient) NewListPager(resourceGroupName string, vmssName string, name string, options *AssignmentReportsVMSSClientListOptions) *runtime.Pager[AssignmentReportsVMSSClientListResponse]
NewListPager - List all reports for the VMSS guest configuration assignment, latest report first.
Generated from API version 2022-01-25
- resourceGroupName - The resource group name.
- vmssName - The name of the virtual machine scale set.
- name - The guest configuration assignment name.
- options - AssignmentReportsVMSSClientListOptions contains the optional parameters for the AssignmentReportsVMSSClient.NewListPager method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/guestconfiguration/resource-manager/Microsoft.GuestConfiguration/stable/2022-01-25/examples/listAllVMSSGuestConfigurationAssignmentReports.json
package main
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/guestconfiguration/armguestconfiguration"
)
func main() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armguestconfiguration.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
pager := clientFactory.NewAssignmentReportsVMSSClient().NewListPager("myResourceGroupName", "myVMSSName", "AuditSecureProtocol", nil)
for pager.More() {
page, err := pager.NextPage(ctx)
if err != nil {
log.Fatalf("failed to advance page: %v", err)
}
for _, v := range page.Value {
// You could use page here. We use blank identifier for just demo purposes.
_ = v
}
// If the HTTP response code is 200 as defined in example definition, your page structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// page.AssignmentReportList = armguestconfiguration.AssignmentReportList{
// Value: []*armguestconfiguration.AssignmentReport{
// {
// Name: to.Ptr("7367cbb8-ae99-47d0-a33b-a283564d2cb1"),
// ID: to.Ptr("/subscriptions/mysubscriptionid/resourceGroups/myResourceGroupName/providers/Microsoft.Compute/virtualMachineScaleSets/myVMSSName/providers/Microsoft.GuestConfiguration/guestConfigurationAssignments/AuditSecureProtocol/reports/7367cbb8-ae99-47d0-a33b-a283564d2cb1"),
// Properties: &armguestconfiguration.AssignmentReportProperties{
// Assignment: &armguestconfiguration.AssignmentInfo{
// Name: to.Ptr("AuditSecureProtocol"),
// Configuration: &armguestconfiguration.ConfigurationInfo{
// Name: to.Ptr("AuditSecureProtocol"),
// },
// },
// ComplianceStatus: to.Ptr(armguestconfiguration.ComplianceStatusCompliant),
// EndTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-29T22:14:13.000Z"); return t}()),
// ReportID: to.Ptr("7367cbb8-ae99-47d0-a33b-a283564d2cb1"),
// StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-29T22:13:53.000Z"); return t}()),
// VM: &armguestconfiguration.VMInfo{
// ID: to.Ptr("/subscriptions/mysubscriptionid/resourceGroups/myResourceGroupName/providers/Microsoft.Compute/virtualMachineScaleSets/myVMSSName/virtualMachines/1"),
// UUID: to.Ptr("vmuuid"),
// },
// },
// },
// {
// Name: to.Ptr("41ee2caf-48f9-4999-a793-82ec7c6beb2c"),
// ID: to.Ptr("/subscriptions/mysubscriptionid/resourceGroups/myResourceGroupName/providers/Microsoft.Compute/virtualMachineScaleSets/myVMSSName/providers/Microsoft.GuestConfiguration/guestConfigurationAssignments/AuditSecureProtocol/reports/41ee2caf-48f9-4999-a793-82ec7c6beb2c"),
// Properties: &armguestconfiguration.AssignmentReportProperties{
// Assignment: &armguestconfiguration.AssignmentInfo{
// Name: to.Ptr("AuditSecureProtocol"),
// Configuration: &armguestconfiguration.ConfigurationInfo{
// Name: to.Ptr("AuditSecureProtocol"),
// },
// },
// ComplianceStatus: to.Ptr(armguestconfiguration.ComplianceStatusCompliant),
// EndTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-29T20:14:13.000Z"); return t}()),
// ReportID: to.Ptr("41ee2caf-48f9-4999-a793-82ec7c6beb2c"),
// StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-29T20:13:53.000Z"); return t}()),
// VM: &armguestconfiguration.VMInfo{
// ID: to.Ptr("/subscriptions/mysubscriptionid/resourceGroups/myResourceGroupName/providers/Microsoft.Compute/virtualMachineScaleSets/myVMSSName/virtualMachines/1"),
// UUID: to.Ptr("vmuuid"),
// },
// },
// }},
// }
}
}
type AssignmentReportsVMSSClientGetOptions ¶
type AssignmentReportsVMSSClientGetOptions struct {
}
AssignmentReportsVMSSClientGetOptions contains the optional parameters for the AssignmentReportsVMSSClient.Get method.
type AssignmentReportsVMSSClientGetResponse ¶
type AssignmentReportsVMSSClientGetResponse struct {
// Report for the guest configuration assignment. Report contains information such as compliance status, reason, and more.
AssignmentReport
}
AssignmentReportsVMSSClientGetResponse contains the response from method AssignmentReportsVMSSClient.Get.
type AssignmentReportsVMSSClientListOptions ¶
type AssignmentReportsVMSSClientListOptions struct {
}
AssignmentReportsVMSSClientListOptions contains the optional parameters for the AssignmentReportsVMSSClient.NewListPager method.
type AssignmentReportsVMSSClientListResponse ¶
type AssignmentReportsVMSSClientListResponse struct {
// List of guest configuration assignment reports.
AssignmentReportList
}
AssignmentReportsVMSSClientListResponse contains the response from method AssignmentReportsVMSSClient.NewListPager.
type AssignmentType ¶
type AssignmentType string
AssignmentType - Specifies the assignment type and execution of the configuration. Possible values are Audit, DeployAndAutoCorrect, ApplyAndAutoCorrect and ApplyAndMonitor.
const ( AssignmentTypeApplyAndAutoCorrect AssignmentType = "ApplyAndAutoCorrect" AssignmentTypeApplyAndMonitor AssignmentType = "ApplyAndMonitor" AssignmentTypeAudit AssignmentType = "Audit" AssignmentTypeDeployAndAutoCorrect AssignmentType = "DeployAndAutoCorrect" )
func PossibleAssignmentTypeValues ¶
func PossibleAssignmentTypeValues() []AssignmentType
PossibleAssignmentTypeValues returns the possible values for the AssignmentType const type.
type AssignmentsClient ¶
type AssignmentsClient struct {
// contains filtered or unexported fields
}
AssignmentsClient contains the methods for the GuestConfigurationAssignments group. Don't use this type directly, use NewAssignmentsClient() instead.
func NewAssignmentsClient ¶
func NewAssignmentsClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*AssignmentsClient, error)
NewAssignmentsClient creates a new instance of AssignmentsClient with the specified values.
- subscriptionID - Subscription ID which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call.
- credential - used to authorize requests. Usually a credential from azidentity.
- options - pass nil to accept the default values.
func (*AssignmentsClient) CreateOrUpdate ¶
func (client *AssignmentsClient) CreateOrUpdate(ctx context.Context, guestConfigurationAssignmentName string, resourceGroupName string, vmName string, parameters Assignment, options *AssignmentsClientCreateOrUpdateOptions) (AssignmentsClientCreateOrUpdateResponse, error)
CreateOrUpdate - Creates an association between a VM and guest configuration If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2022-01-25
- guestConfigurationAssignmentName - Name of the guest configuration assignment.
- resourceGroupName - The resource group name.
- vmName - The name of the virtual machine.
- parameters - Parameters supplied to the create or update guest configuration assignment.
- options - AssignmentsClientCreateOrUpdateOptions contains the optional parameters for the AssignmentsClient.CreateOrUpdate method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/guestconfiguration/resource-manager/Microsoft.GuestConfiguration/stable/2022-01-25/examples/createOrUpdateGuestConfigurationAssignment.json
package main
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/guestconfiguration/armguestconfiguration"
)
func main() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armguestconfiguration.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
res, err := clientFactory.NewAssignmentsClient().CreateOrUpdate(ctx, "NotInstalledApplicationForWindows", "myResourceGroupName", "myVMName", armguestconfiguration.Assignment{
Name: to.Ptr("NotInstalledApplicationForWindows"),
Location: to.Ptr("westcentralus"),
Properties: &armguestconfiguration.AssignmentProperties{
Context: to.Ptr("Azure policy"),
GuestConfiguration: &armguestconfiguration.Navigation{
Name: to.Ptr("NotInstalledApplicationForWindows"),
AssignmentType: to.Ptr(armguestconfiguration.AssignmentTypeApplyAndAutoCorrect),
ConfigurationParameter: []*armguestconfiguration.ConfigurationParameter{
{
Name: to.Ptr("[InstalledApplication]NotInstalledApplicationResource1;Name"),
Value: to.Ptr("NotePad,sql"),
}},
ContentHash: to.Ptr("123contenthash"),
ContentURI: to.Ptr("https://thisisfake/pacakge"),
Version: to.Ptr("1.*"),
},
},
}, nil)
if err != nil {
log.Fatalf("failed to finish the request: %v", err)
}
// You could use response here. We use blank identifier for just demo purposes.
_ = res
// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// res.Assignment = armguestconfiguration.Assignment{
// Name: to.Ptr("NotInstalledApplicationForWindows"),
// ID: to.Ptr("/subscriptions/mysubscriptionid/resourceGroups/myResourceGroupName/providers/Microsoft.Compute/virtualMachines/myvm/providers/Microsoft.GuestConfiguration/guestConfigurationAssignments/NotInstalledApplicationForWindows"),
// Location: to.Ptr("westcentralus"),
// Properties: &armguestconfiguration.AssignmentProperties{
// ComplianceStatus: to.Ptr(armguestconfiguration.ComplianceStatusPending),
// Context: to.Ptr("Azure policy"),
// GuestConfiguration: &armguestconfiguration.Navigation{
// Name: to.Ptr("NotInstalledApplicationForWindows"),
// AssignmentSource: to.Ptr("AzurePolicy"),
// ConfigurationParameter: []*armguestconfiguration.ConfigurationParameter{
// {
// Name: to.Ptr("[InstalledApplication]NotInstalledApplicationResource1;Name"),
// Value: to.Ptr("NotePad,sql"),
// }},
// Version: to.Ptr("1.0.0.3"),
// },
// ProvisioningState: to.Ptr(armguestconfiguration.ProvisioningStateSucceeded),
// },
// }
}
func (*AssignmentsClient) Delete ¶
func (client *AssignmentsClient) Delete(ctx context.Context, resourceGroupName string, guestConfigurationAssignmentName string, vmName string, options *AssignmentsClientDeleteOptions) (AssignmentsClientDeleteResponse, error)
Delete - Delete a guest configuration assignment If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2022-01-25
- resourceGroupName - The resource group name.
- guestConfigurationAssignmentName - Name of the guest configuration assignment
- vmName - The name of the virtual machine.
- options - AssignmentsClientDeleteOptions contains the optional parameters for the AssignmentsClient.Delete method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/guestconfiguration/resource-manager/Microsoft.GuestConfiguration/stable/2022-01-25/examples/deleteGuestConfigurationAssignment.json
package main
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/guestconfiguration/armguestconfiguration"
)
func main() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armguestconfiguration.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
_, err = clientFactory.NewAssignmentsClient().Delete(ctx, "myResourceGroupName", "SecureProtocol", "myVMName", nil)
if err != nil {
log.Fatalf("failed to finish the request: %v", err)
}
}
func (*AssignmentsClient) Get ¶
func (client *AssignmentsClient) Get(ctx context.Context, resourceGroupName string, guestConfigurationAssignmentName string, vmName string, options *AssignmentsClientGetOptions) (AssignmentsClientGetResponse, error)
Get - Get information about a guest configuration assignment If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2022-01-25
- resourceGroupName - The resource group name.
- guestConfigurationAssignmentName - The guest configuration assignment name.
- vmName - The name of the virtual machine.
- options - AssignmentsClientGetOptions contains the optional parameters for the AssignmentsClient.Get method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/guestconfiguration/resource-manager/Microsoft.GuestConfiguration/stable/2022-01-25/examples/getGuestConfigurationAssignment.json
package main
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/guestconfiguration/armguestconfiguration"
)
func main() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armguestconfiguration.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
res, err := clientFactory.NewAssignmentsClient().Get(ctx, "myResourceGroupName", "SecureProtocol", "myVMName", nil)
if err != nil {
log.Fatalf("failed to finish the request: %v", err)
}
// You could use response here. We use blank identifier for just demo purposes.
_ = res
// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// res.Assignment = armguestconfiguration.Assignment{
// Name: to.Ptr("AuditSecureProtocol"),
// ID: to.Ptr("/subscriptions/subscriptionId/resourceGroups/myResourceGroupName/providers/Microsoft.Compute/virtualMachines/myvm/providers/Microsoft.GuestConfiguration/guestConfigurationAssignments/AuditSecureProtocol"),
// Location: to.Ptr("centraluseuap"),
// Properties: &armguestconfiguration.AssignmentProperties{
// AssignmentHash: to.Ptr("E0D8941DD713F284284561648C00C18FA76C8602943C7CD38AFD73B56AE4C35F.E3B0C44298FC1C149AFBF4C8996FB92427AE41E4649B934CA495991B7852B855"),
// ComplianceStatus: to.Ptr(armguestconfiguration.ComplianceStatusCompliant),
// GuestConfiguration: &armguestconfiguration.Navigation{
// Name: to.Ptr("AuditSecureProtocol"),
// ConfigurationParameter: []*armguestconfiguration.ConfigurationParameter{
// },
// ContentHash: to.Ptr("content hash"),
// ContentURI: to.Ptr("https://mystorageaccount.blob.core.windows.net/builtinconfig/AuditSecureProtocol/AuditSecureProtocol_1.0.0.3.zip"),
// Version: to.Ptr("1.0.0.3"),
// },
// LastComplianceStatusChecked: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-29T22:14:13.000Z"); return t}()),
// LatestReportID: to.Ptr("/subscriptions/subscriptionId/resourceGroups/myResourceGroupName/providers/Microsoft.Compute/virtualMachines/myvm/providers/Microsoft.GuestConfiguration/guestConfigurationAssignments/AuditSecureProtocol/reports/7367cbb8-ae99-47d0-a33b-a283564d2cb1"),
// ProvisioningState: to.Ptr(armguestconfiguration.ProvisioningStateSucceeded),
// },
// }
}
func (*AssignmentsClient) NewListPager ¶
func (client *AssignmentsClient) NewListPager(resourceGroupName string, vmName string, options *AssignmentsClientListOptions) *runtime.Pager[AssignmentsClientListResponse]
NewListPager - List all guest configuration assignments for a virtual machine.
Generated from API version 2022-01-25
- resourceGroupName - The resource group name.
- vmName - The name of the virtual machine.
- options - AssignmentsClientListOptions contains the optional parameters for the AssignmentsClient.NewListPager method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/guestconfiguration/resource-manager/Microsoft.GuestConfiguration/stable/2022-01-25/examples/listGuestConfigurationAssignments.json
package main
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/guestconfiguration/armguestconfiguration"
)
func main() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armguestconfiguration.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
pager := clientFactory.NewAssignmentsClient().NewListPager("myResourceGroupName", "myVMName", nil)
for pager.More() {
page, err := pager.NextPage(ctx)
if err != nil {
log.Fatalf("failed to advance page: %v", err)
}
for _, v := range page.Value {
// You could use page here. We use blank identifier for just demo purposes.
_ = v
}
// If the HTTP response code is 200 as defined in example definition, your page structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// page.AssignmentList = armguestconfiguration.AssignmentList{
// }
}
}
func (*AssignmentsClient) NewRGListPager ¶
func (client *AssignmentsClient) NewRGListPager(resourceGroupName string, options *AssignmentsClientRGListOptions) *runtime.Pager[AssignmentsClientRGListResponse]
NewRGListPager - List all guest configuration assignments for a resource group.
Generated from API version 2022-01-25
- resourceGroupName - The resource group name.
- options - AssignmentsClientRGListOptions contains the optional parameters for the AssignmentsClient.NewRGListPager method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/guestconfiguration/resource-manager/Microsoft.GuestConfiguration/stable/2022-01-25/examples/listRGGuestConfigurationAssignments.json
package main
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/guestconfiguration/armguestconfiguration"
)
func main() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armguestconfiguration.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
pager := clientFactory.NewAssignmentsClient().NewRGListPager("myResourceGroupName", nil)
for pager.More() {
page, err := pager.NextPage(ctx)
if err != nil {
log.Fatalf("failed to advance page: %v", err)
}
for _, v := range page.Value {
// You could use page here. We use blank identifier for just demo purposes.
_ = v
}
// If the HTTP response code is 200 as defined in example definition, your page structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// page.AssignmentList = armguestconfiguration.AssignmentList{
// }
}
}
func (*AssignmentsClient) NewSubscriptionListPager ¶
func (client *AssignmentsClient) NewSubscriptionListPager(options *AssignmentsClientSubscriptionListOptions) *runtime.Pager[AssignmentsClientSubscriptionListResponse]
NewSubscriptionListPager - List all guest configuration assignments for a subscription.
Generated from API version 2022-01-25
- options - AssignmentsClientSubscriptionListOptions contains the optional parameters for the AssignmentsClient.NewSubscriptionListPager method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/guestconfiguration/resource-manager/Microsoft.GuestConfiguration/stable/2022-01-25/examples/listSubGuestConfigurationAssignments.json
package main
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/guestconfiguration/armguestconfiguration"
)
func main() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armguestconfiguration.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
pager := clientFactory.NewAssignmentsClient().NewSubscriptionListPager(nil)
for pager.More() {
page, err := pager.NextPage(ctx)
if err != nil {
log.Fatalf("failed to advance page: %v", err)
}
for _, v := range page.Value {
// You could use page here. We use blank identifier for just demo purposes.
_ = v
}
// If the HTTP response code is 200 as defined in example definition, your page structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// page.AssignmentList = armguestconfiguration.AssignmentList{
// }
}
}
type AssignmentsClientCreateOrUpdateOptions ¶
type AssignmentsClientCreateOrUpdateOptions struct {
}
AssignmentsClientCreateOrUpdateOptions contains the optional parameters for the AssignmentsClient.CreateOrUpdate method.
type AssignmentsClientCreateOrUpdateResponse ¶
type AssignmentsClientCreateOrUpdateResponse struct {
// Guest configuration assignment is an association between a machine and guest configuration.
Assignment
}
AssignmentsClientCreateOrUpdateResponse contains the response from method AssignmentsClient.CreateOrUpdate.
type AssignmentsClientDeleteOptions ¶
type AssignmentsClientDeleteOptions struct {
}
AssignmentsClientDeleteOptions contains the optional parameters for the AssignmentsClient.Delete method.
type AssignmentsClientDeleteResponse ¶
type AssignmentsClientDeleteResponse struct {
}
AssignmentsClientDeleteResponse contains the response from method AssignmentsClient.Delete.
type AssignmentsClientGetOptions ¶
type AssignmentsClientGetOptions struct {
}
AssignmentsClientGetOptions contains the optional parameters for the AssignmentsClient.Get method.
type AssignmentsClientGetResponse ¶
type AssignmentsClientGetResponse struct {
// Guest configuration assignment is an association between a machine and guest configuration.
Assignment
}
AssignmentsClientGetResponse contains the response from method AssignmentsClient.Get.
type AssignmentsClientListOptions ¶
type AssignmentsClientListOptions struct {
}
AssignmentsClientListOptions contains the optional parameters for the AssignmentsClient.NewListPager method.
type AssignmentsClientListResponse ¶
type AssignmentsClientListResponse struct {
// The response of the list guest configuration assignment operation.
AssignmentList
}
AssignmentsClientListResponse contains the response from method AssignmentsClient.NewListPager.
type AssignmentsClientRGListOptions ¶
type AssignmentsClientRGListOptions struct {
}
AssignmentsClientRGListOptions contains the optional parameters for the AssignmentsClient.NewRGListPager method.
type AssignmentsClientRGListResponse ¶
type AssignmentsClientRGListResponse struct {
// The response of the list guest configuration assignment operation.
AssignmentList
}
AssignmentsClientRGListResponse contains the response from method AssignmentsClient.NewRGListPager.
type AssignmentsClientSubscriptionListOptions ¶
type AssignmentsClientSubscriptionListOptions struct {
}
AssignmentsClientSubscriptionListOptions contains the optional parameters for the AssignmentsClient.NewSubscriptionListPager method.
type AssignmentsClientSubscriptionListResponse ¶
type AssignmentsClientSubscriptionListResponse struct {
// The response of the list guest configuration assignment operation.
AssignmentList
}
AssignmentsClientSubscriptionListResponse contains the response from method AssignmentsClient.NewSubscriptionListPager.
type AssignmentsVMSSClient ¶
type AssignmentsVMSSClient struct {
// contains filtered or unexported fields
}
AssignmentsVMSSClient contains the methods for the GuestConfigurationAssignmentsVMSS group. Don't use this type directly, use NewAssignmentsVMSSClient() instead.
func NewAssignmentsVMSSClient ¶
func NewAssignmentsVMSSClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*AssignmentsVMSSClient, error)
NewAssignmentsVMSSClient creates a new instance of AssignmentsVMSSClient with the specified values.
- subscriptionID - Subscription ID which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call.
- credential - used to authorize requests. Usually a credential from azidentity.
- options - pass nil to accept the default values.
func (*AssignmentsVMSSClient) Delete ¶
func (client *AssignmentsVMSSClient) Delete(ctx context.Context, resourceGroupName string, vmssName string, name string, options *AssignmentsVMSSClientDeleteOptions) (AssignmentsVMSSClientDeleteResponse, error)
Delete - Delete a guest configuration assignment for VMSS If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2022-01-25
- resourceGroupName - The resource group name.
- vmssName - The name of the virtual machine scale set.
- name - The guest configuration assignment name.
- options - AssignmentsVMSSClientDeleteOptions contains the optional parameters for the AssignmentsVMSSClient.Delete method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/guestconfiguration/resource-manager/Microsoft.GuestConfiguration/stable/2022-01-25/examples/deleteGuestConfigurationVMSSAssignment.json
package main
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/guestconfiguration/armguestconfiguration"
)
func main() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armguestconfiguration.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
res, err := clientFactory.NewAssignmentsVMSSClient().Delete(ctx, "myResourceGroupName", "myVMSSName", "SecureProtocol", nil)
if err != nil {
log.Fatalf("failed to finish the request: %v", err)
}
// You could use response here. We use blank identifier for just demo purposes.
_ = res
// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// res.Assignment = armguestconfiguration.Assignment{
// Name: to.Ptr("AuditSecureProtocol"),
// ID: to.Ptr("/subscriptions/subscriptionId/resourceGroups/myResourceGroupName/providers/Microsoft.Compute/virtualMachineScaleSets/myVMSSName/providers/Microsoft.GuestConfiguration/guestConfigurationAssignments/AuditSecureProtocol"),
// Location: to.Ptr("centraluseuap"),
// Properties: &armguestconfiguration.AssignmentProperties{
// AssignmentHash: to.Ptr("E0D8941DD713F284284561648C00C18FA76C8602943C7CD38AFD73B56AE4C35F.E3B0C44298FC1C149AFBF4C8996FB92427AE41E4649B934CA495991B7852B855"),
// ComplianceStatus: to.Ptr(armguestconfiguration.ComplianceStatusCompliant),
// GuestConfiguration: &armguestconfiguration.Navigation{
// Name: to.Ptr("AuditSecureProtocol"),
// ConfigurationParameter: []*armguestconfiguration.ConfigurationParameter{
// },
// ContentHash: to.Ptr("content hash"),
// ContentURI: to.Ptr("https://mystorageaccount.blob.core.windows.net/builtinconfig/AuditSecureProtocol/AuditSecureProtocol_1.0.0.3.zip"),
// Version: to.Ptr("1.0.0.3"),
// },
// LastComplianceStatusChecked: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-29T22:14:13.000Z"); return t}()),
// ProvisioningState: to.Ptr(armguestconfiguration.ProvisioningStateSucceeded),
// ResourceType: to.Ptr("VMSS"),
// },
// }
}
func (*AssignmentsVMSSClient) Get ¶
func (client *AssignmentsVMSSClient) Get(ctx context.Context, resourceGroupName string, vmssName string, name string, options *AssignmentsVMSSClientGetOptions) (AssignmentsVMSSClientGetResponse, error)
Get - Get information about a guest configuration assignment for VMSS If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2022-01-25
- resourceGroupName - The resource group name.
- vmssName - The name of the virtual machine scale set.
- name - The guest configuration assignment name.
- options - AssignmentsVMSSClientGetOptions contains the optional parameters for the AssignmentsVMSSClient.Get method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/guestconfiguration/resource-manager/Microsoft.GuestConfiguration/stable/2022-01-25/examples/getVMSSGuestConfigurationAssignment.json
package main
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/guestconfiguration/armguestconfiguration"
)
func main() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armguestconfiguration.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
res, err := clientFactory.NewAssignmentsVMSSClient().Get(ctx, "myResourceGroupName", "myVMSSName", "SecureProtocol", nil)
if err != nil {
log.Fatalf("failed to finish the request: %v", err)
}
// You could use response here. We use blank identifier for just demo purposes.
_ = res
// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// res.Assignment = armguestconfiguration.Assignment{
// Name: to.Ptr("AuditSecureProtocol"),
// ID: to.Ptr("/subscriptions/subscriptionId/resourceGroups/myResourceGroupName/providers/Microsoft.Compute/virtualMachineScaleSets/myVMSSName/providers/Microsoft.GuestConfiguration/guestConfigurationAssignments/AuditSecureProtocol"),
// Location: to.Ptr("centraluseuap"),
// Properties: &armguestconfiguration.AssignmentProperties{
// AssignmentHash: to.Ptr("E0D8941DD713F284284561648C00C18FA76C8602943C7CD38AFD73B56AE4C35F.E3B0C44298FC1C149AFBF4C8996FB92427AE41E4649B934CA495991B7852B855"),
// ComplianceStatus: to.Ptr(armguestconfiguration.ComplianceStatusCompliant),
// GuestConfiguration: &armguestconfiguration.Navigation{
// Name: to.Ptr("AuditSecureProtocol"),
// ConfigurationParameter: []*armguestconfiguration.ConfigurationParameter{
// },
// ContentHash: to.Ptr("content hash"),
// ContentURI: to.Ptr("https://mystorageaccount.blob.core.windows.net/builtinconfig/AuditSecureProtocol/AuditSecureProtocol_1.0.0.3.zip"),
// Version: to.Ptr("1.0.0.3"),
// },
// LastComplianceStatusChecked: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-29T22:14:13.000Z"); return t}()),
// ProvisioningState: to.Ptr(armguestconfiguration.ProvisioningStateSucceeded),
// ResourceType: to.Ptr("VMSS"),
// },
// }
}
func (*AssignmentsVMSSClient) NewListPager ¶
func (client *AssignmentsVMSSClient) NewListPager(resourceGroupName string, vmssName string, options *AssignmentsVMSSClientListOptions) *runtime.Pager[AssignmentsVMSSClientListResponse]
NewListPager - List all guest configuration assignments for VMSS.
Generated from API version 2022-01-25
- resourceGroupName - The resource group name.
- vmssName - The name of the virtual machine scale set.
- options - AssignmentsVMSSClientListOptions contains the optional parameters for the AssignmentsVMSSClient.NewListPager method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/guestconfiguration/resource-manager/Microsoft.GuestConfiguration/stable/2022-01-25/examples/listVMSSGuestConfigurationAssignments.json
package main
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/guestconfiguration/armguestconfiguration"
)
func main() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armguestconfiguration.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
pager := clientFactory.NewAssignmentsVMSSClient().NewListPager("myResourceGroupName", "myVMSSName", nil)
for pager.More() {
page, err := pager.NextPage(ctx)
if err != nil {
log.Fatalf("failed to advance page: %v", err)
}
for _, v := range page.Value {
// You could use page here. We use blank identifier for just demo purposes.
_ = v
}
// If the HTTP response code is 200 as defined in example definition, your page structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// page.AssignmentList = armguestconfiguration.AssignmentList{
// }
}
}
type AssignmentsVMSSClientDeleteOptions ¶
type AssignmentsVMSSClientDeleteOptions struct {
}
AssignmentsVMSSClientDeleteOptions contains the optional parameters for the AssignmentsVMSSClient.Delete method.
type AssignmentsVMSSClientDeleteResponse ¶
type AssignmentsVMSSClientDeleteResponse struct {
// Guest configuration assignment is an association between a machine and guest configuration.
Assignment
}
AssignmentsVMSSClientDeleteResponse contains the response from method AssignmentsVMSSClient.Delete.
type AssignmentsVMSSClientGetOptions ¶
type AssignmentsVMSSClientGetOptions struct {
}
AssignmentsVMSSClientGetOptions contains the optional parameters for the AssignmentsVMSSClient.Get method.
type AssignmentsVMSSClientGetResponse ¶
type AssignmentsVMSSClientGetResponse struct {
// Guest configuration assignment is an association between a machine and guest configuration.
Assignment
}
AssignmentsVMSSClientGetResponse contains the response from method AssignmentsVMSSClient.Get.
type AssignmentsVMSSClientListOptions ¶
type AssignmentsVMSSClientListOptions struct {
}
AssignmentsVMSSClientListOptions contains the optional parameters for the AssignmentsVMSSClient.NewListPager method.
type AssignmentsVMSSClientListResponse ¶
type AssignmentsVMSSClientListResponse struct {
// The response of the list guest configuration assignment operation.
AssignmentList
}
AssignmentsVMSSClientListResponse contains the response from method AssignmentsVMSSClient.NewListPager.
type ClientFactory ¶
type ClientFactory struct {
// contains filtered or unexported fields
}
ClientFactory is a client factory used to create any client in this module. Don't use this type directly, use NewClientFactory instead.
func NewClientFactory ¶
func NewClientFactory(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*ClientFactory, error)
NewClientFactory creates a new instance of ClientFactory with the specified values. The parameter values will be propagated to any client created from this factory.
- subscriptionID - Subscription ID which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call.
- credential - used to authorize requests. Usually a credential from azidentity.
- options - pass nil to accept the default values.
func (*ClientFactory) NewAssignmentReportsClient ¶
func (c *ClientFactory) NewAssignmentReportsClient() *AssignmentReportsClient
NewAssignmentReportsClient creates a new instance of AssignmentReportsClient.
func (*ClientFactory) NewAssignmentReportsVMSSClient ¶
func (c *ClientFactory) NewAssignmentReportsVMSSClient() *AssignmentReportsVMSSClient
NewAssignmentReportsVMSSClient creates a new instance of AssignmentReportsVMSSClient.
func (*ClientFactory) NewAssignmentsClient ¶
func (c *ClientFactory) NewAssignmentsClient() *AssignmentsClient
NewAssignmentsClient creates a new instance of AssignmentsClient.
func (*ClientFactory) NewAssignmentsVMSSClient ¶
func (c *ClientFactory) NewAssignmentsVMSSClient() *AssignmentsVMSSClient
NewAssignmentsVMSSClient creates a new instance of AssignmentsVMSSClient.
func (*ClientFactory) NewHCRPAssignmentReportsClient ¶
func (c *ClientFactory) NewHCRPAssignmentReportsClient() *HCRPAssignmentReportsClient
NewHCRPAssignmentReportsClient creates a new instance of HCRPAssignmentReportsClient.
func (*ClientFactory) NewHCRPAssignmentsClient ¶
func (c *ClientFactory) NewHCRPAssignmentsClient() *HCRPAssignmentsClient
NewHCRPAssignmentsClient creates a new instance of HCRPAssignmentsClient.
func (*ClientFactory) NewOperationsClient ¶
func (c *ClientFactory) NewOperationsClient() *OperationsClient
NewOperationsClient creates a new instance of OperationsClient.
type CommonAssignmentReport ¶
type CommonAssignmentReport struct {
// Configuration details of the guest configuration assignment.
Assignment *AssignmentInfo
// The list of resources for which guest configuration assignment compliance is checked.
Resources []*AssignmentReportResource
// Information about the VM.
VM *VMInfo
// READ-ONLY; A value indicating compliance status of the machine for the assigned guest configuration.
ComplianceStatus *ComplianceStatus
// READ-ONLY; End date and time of the guest configuration assignment compliance status check.
EndTime *time.Time
// READ-ONLY; ARM resource id of the report for the guest configuration assignment.
ID *string
// READ-ONLY; Type of report, Consistency or Initial
OperationType *Type
// READ-ONLY; GUID that identifies the guest configuration assignment report under a subscription, resource group.
ReportID *string
// READ-ONLY; Start date and time of the guest configuration assignment compliance status check.
StartTime *time.Time
}
func (CommonAssignmentReport) MarshalJSON ¶
func (c CommonAssignmentReport) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type CommonAssignmentReport.
func (*CommonAssignmentReport) UnmarshalJSON ¶
func (c *CommonAssignmentReport) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type CommonAssignmentReport.
type ComplianceStatus ¶
type ComplianceStatus string
ComplianceStatus - A value indicating compliance status of the machine for the assigned guest configuration.
const ( ComplianceStatusCompliant ComplianceStatus = "Compliant" ComplianceStatusNonCompliant ComplianceStatus = "NonCompliant" ComplianceStatusPending ComplianceStatus = "Pending" )
func PossibleComplianceStatusValues ¶
func PossibleComplianceStatusValues() []ComplianceStatus
PossibleComplianceStatusValues returns the possible values for the ComplianceStatus const type.
type ConfigurationInfo ¶
type ConfigurationInfo struct {
// READ-ONLY; Name of the configuration.
Name *string
// READ-ONLY; Version of the configuration.
Version *string
}
ConfigurationInfo - Information about the configuration.
func (ConfigurationInfo) MarshalJSON ¶
func (c ConfigurationInfo) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ConfigurationInfo.
func (*ConfigurationInfo) UnmarshalJSON ¶
func (c *ConfigurationInfo) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ConfigurationInfo.
type ConfigurationMode ¶
type ConfigurationMode string
ConfigurationMode - Specifies how the LCM(Local Configuration Manager) actually applies the configuration to the target nodes. Possible values are ApplyOnly, ApplyAndMonitor, and ApplyAndAutoCorrect.
const ( ConfigurationModeApplyAndAutoCorrect ConfigurationMode = "ApplyAndAutoCorrect" ConfigurationModeApplyAndMonitor ConfigurationMode = "ApplyAndMonitor" ConfigurationModeApplyOnly ConfigurationMode = "ApplyOnly" )
func PossibleConfigurationModeValues ¶
func PossibleConfigurationModeValues() []ConfigurationMode
PossibleConfigurationModeValues returns the possible values for the ConfigurationMode const type.
type ConfigurationParameter ¶
type ConfigurationParameter struct {
// Name of the configuration parameter.
Name *string
// Value of the configuration parameter.
Value *string
}
ConfigurationParameter - Represents a configuration parameter.
func (ConfigurationParameter) MarshalJSON ¶
func (c ConfigurationParameter) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ConfigurationParameter.
func (*ConfigurationParameter) UnmarshalJSON ¶
func (c *ConfigurationParameter) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ConfigurationParameter.
type ConfigurationSetting ¶
type ConfigurationSetting struct {
// READ-ONLY; Specifies what happens after a reboot during the application of a configuration. The possible values are ContinueConfiguration
// and StopConfiguration
ActionAfterReboot *ActionAfterReboot
// READ-ONLY; If true - new configurations downloaded from the pull service are allowed to overwrite the old ones on the target
// node. Otherwise, false
AllowModuleOverwrite *bool
// READ-ONLY; Specifies how the LCM(Local Configuration Manager) actually applies the configuration to the target nodes. Possible
// values are ApplyOnly, ApplyAndMonitor, and ApplyAndAutoCorrect.
ConfigurationMode *ConfigurationMode
// READ-ONLY; 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.
ConfigurationModeFrequencyMins *float32
// READ-ONLY; 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.
RebootIfNeeded *bool
// READ-ONLY; 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.
RefreshFrequencyMins *float32
}
ConfigurationSetting - Configuration setting of LCM (Local Configuration Manager).
func (ConfigurationSetting) MarshalJSON ¶
func (c ConfigurationSetting) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ConfigurationSetting.
func (*ConfigurationSetting) UnmarshalJSON ¶
func (c *ConfigurationSetting) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ConfigurationSetting.
type CreatedByType ¶
type CreatedByType string
CreatedByType - The type of identity that created the resource.
const ( CreatedByTypeApplication CreatedByType = "Application" CreatedByTypeKey CreatedByType = "Key" CreatedByTypeManagedIdentity CreatedByType = "ManagedIdentity" CreatedByTypeUser CreatedByType = "User" )
func PossibleCreatedByTypeValues ¶
func PossibleCreatedByTypeValues() []CreatedByType
PossibleCreatedByTypeValues returns the possible values for the CreatedByType const type.
type ErrorResponse ¶
type ErrorResponse struct {
Error *ErrorResponseError
}
ErrorResponse - Error response of an operation failure
func (ErrorResponse) MarshalJSON ¶
func (e ErrorResponse) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ErrorResponse.
func (*ErrorResponse) UnmarshalJSON ¶
func (e *ErrorResponse) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ErrorResponse.
type ErrorResponseError ¶
type ErrorResponseError struct {
// Error code.
Code *string
// Detail error message indicating why the operation failed.
Message *string
}
func (ErrorResponseError) MarshalJSON ¶
func (e ErrorResponseError) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ErrorResponseError.
func (*ErrorResponseError) UnmarshalJSON ¶
func (e *ErrorResponseError) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ErrorResponseError.
type HCRPAssignmentReportsClient ¶
type HCRPAssignmentReportsClient struct {
// contains filtered or unexported fields
}
HCRPAssignmentReportsClient contains the methods for the GuestConfigurationHCRPAssignmentReports group. Don't use this type directly, use NewHCRPAssignmentReportsClient() instead.
func NewHCRPAssignmentReportsClient ¶
func NewHCRPAssignmentReportsClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*HCRPAssignmentReportsClient, error)
NewHCRPAssignmentReportsClient creates a new instance of HCRPAssignmentReportsClient with the specified values.
- subscriptionID - Subscription ID which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call.
- credential - used to authorize requests. Usually a credential from azidentity.
- options - pass nil to accept the default values.
func (*HCRPAssignmentReportsClient) Get ¶
func (client *HCRPAssignmentReportsClient) Get(ctx context.Context, resourceGroupName string, guestConfigurationAssignmentName string, reportID string, machineName string, options *HCRPAssignmentReportsClientGetOptions) (HCRPAssignmentReportsClientGetResponse, error)
Get - Get a report for the guest configuration assignment, by reportId. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2022-01-25
- resourceGroupName - The resource group name.
- guestConfigurationAssignmentName - The guest configuration assignment name.
- reportID - The GUID for the guest configuration assignment report.
- machineName - The name of the ARC machine.
- options - HCRPAssignmentReportsClientGetOptions contains the optional parameters for the HCRPAssignmentReportsClient.Get method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/guestconfiguration/resource-manager/Microsoft.GuestConfiguration/stable/2022-01-25/examples/getGuestConfigurationHCRPAssignmentReportById.json
package main
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/guestconfiguration/armguestconfiguration"
)
func main() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armguestconfiguration.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
res, err := clientFactory.NewHCRPAssignmentReportsClient().Get(ctx, "myResourceGroupName", "AuditSecureProtocol", "7367cbb8-ae99-47d0-a33b-a283564d2cb1", "myMachineName", nil)
if err != nil {
log.Fatalf("failed to finish the request: %v", err)
}
// You could use response here. We use blank identifier for just demo purposes.
_ = res
// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// res.AssignmentReport = armguestconfiguration.AssignmentReport{
// Name: to.Ptr("7367cbb8-ae99-47d0-a33b-a283564d2cb1"),
// ID: to.Ptr("/subscriptions/mysubscriptionid/resourceGroups/myResourceGroupName/providers/Microsoft.HybridCompute/machines/myMachineName/providers/Microsoft.GuestConfiguration/guestConfigurationAssignments/AuditSecureProtocol/reports/7367cbb8-ae99-47d0-a33b-a283564d2cb1"),
// Properties: &armguestconfiguration.AssignmentReportProperties{
// Assignment: &armguestconfiguration.AssignmentInfo{
// Name: to.Ptr("AuditSecureProtocol"),
// Configuration: &armguestconfiguration.ConfigurationInfo{
// Name: to.Ptr("AuditSecureProtocol"),
// Version: to.Ptr("1.0.0.0"),
// },
// },
// ComplianceStatus: to.Ptr(armguestconfiguration.ComplianceStatusCompliant),
// EndTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-29T22:14:13.000Z"); return t}()),
// ReportID: to.Ptr("7367cbb8-ae99-47d0-a33b-a283564d2cb1"),
// StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-29T22:13:53.000Z"); return t}()),
// VM: &armguestconfiguration.VMInfo{
// ID: to.Ptr("/subscriptions/mysubscriptionid/resourceGroups/myResourceGroupName/providers/Microsoft.HybridCompute/machines/myMachineName"),
// UUID: to.Ptr("vmuuid"),
// },
// Details: &armguestconfiguration.AssignmentReportDetails{
// ComplianceStatus: to.Ptr(armguestconfiguration.ComplianceStatusCompliant),
// EndTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-29T22:14:13.000Z"); return t}()),
// JobID: to.Ptr("7367cbb8-ae99-47d0-a33b-a283564d2cb1"),
// OperationType: to.Ptr(armguestconfiguration.TypeConsistency),
// Resources: []*armguestconfiguration.AssignmentReportResource{
// {
// ComplianceStatus: to.Ptr(armguestconfiguration.ComplianceStatusCompliant),
// Properties: map[string]any{
// "ConfigurationName": "IsWebServerSecure",
// "DependsOn": nil,
// "IsSingleInstance": "Yes",
// "ModuleName": "SecureProtocolWebServer",
// "ModuleVersion": "1.0.0.3",
// "Protocols":[]any{
// map[string]any{
// "Ensure": "Absent",
// "Protocol": "SSL 2.0",
// },
// map[string]any{
// "Ensure": "Absent",
// "Protocol": "SSL 3.0",
// },
// map[string]any{
// "Ensure": "Absent",
// "Protocol": "TLS 1.0",
// },
// map[string]any{
// "Ensure": "Absent",
// "Protocol": "PCT 1.0",
// },
// map[string]any{
// "Ensure": "Absent",
// "Protocol": "Multi-Protocol Unified Hello",
// },
// map[string]any{
// "Ensure": "Absent",
// "Protocol": "TLS 1.1",
// },
// map[string]any{
// "Ensure": "Absent",
// "Protocol": "TLS 1.2",
// },
// },
// "PsDscRunAsCredential": nil,
// "Reasons": nil,
// "ResourceId": "[SecureWebServer]s1",
// "SourceInfo": nil,
// },
// Reasons: []*armguestconfiguration.AssignmentReportResourceComplianceReason{
// {
// Code: to.Ptr("DSC::RESOURCE::SUCCESS"),
// Phrase: to.Ptr("Operation successful."),
// }},
// }},
// StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-29T22:13:53.000Z"); return t}()),
// },
// },
// }
}
func (*HCRPAssignmentReportsClient) List ¶
func (client *HCRPAssignmentReportsClient) List(ctx context.Context, resourceGroupName string, guestConfigurationAssignmentName string, machineName string, options *HCRPAssignmentReportsClientListOptions) (HCRPAssignmentReportsClientListResponse, error)
List - List all reports for the guest configuration assignment, latest report first. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2022-01-25
- resourceGroupName - The resource group name.
- guestConfigurationAssignmentName - The guest configuration assignment name.
- machineName - The name of the ARC machine.
- options - HCRPAssignmentReportsClientListOptions contains the optional parameters for the HCRPAssignmentReportsClient.List method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/guestconfiguration/resource-manager/Microsoft.GuestConfiguration/stable/2022-01-25/examples/listAllGuestConfigurationHCRPAssignmentReports.json
package main
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/guestconfiguration/armguestconfiguration"
)
func main() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armguestconfiguration.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
res, err := clientFactory.NewHCRPAssignmentReportsClient().List(ctx, "myResourceGroupName", "AuditSecureProtocol", "myMachineName", nil)
if err != nil {
log.Fatalf("failed to finish the request: %v", err)
}
// You could use response here. We use blank identifier for just demo purposes.
_ = res
// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// res.AssignmentReportList = armguestconfiguration.AssignmentReportList{
// Value: []*armguestconfiguration.AssignmentReport{
// {
// Name: to.Ptr("7367cbb8-ae99-47d0-a33b-a283564d2cb1"),
// ID: to.Ptr("/subscriptions/mysubscriptionid/resourceGroups/myResourceGroupName/providers/Microsoft.HybridCompute/machines/myMachineName/providers/Microsoft.GuestConfiguration/guestConfigurationAssignments/AuditSecureProtocol/reports/7367cbb8-ae99-47d0-a33b-a283564d2cb1"),
// Properties: &armguestconfiguration.AssignmentReportProperties{
// Assignment: &armguestconfiguration.AssignmentInfo{
// Name: to.Ptr("AuditSecureProtocol"),
// Configuration: &armguestconfiguration.ConfigurationInfo{
// Name: to.Ptr("AuditSecureProtocol"),
// },
// },
// ComplianceStatus: to.Ptr(armguestconfiguration.ComplianceStatusCompliant),
// EndTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-29T22:14:13.000Z"); return t}()),
// ReportID: to.Ptr("7367cbb8-ae99-47d0-a33b-a283564d2cb1"),
// StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-29T22:13:53.000Z"); return t}()),
// VM: &armguestconfiguration.VMInfo{
// ID: to.Ptr("/subscriptions/mysubscriptionid/resourceGroups/myResourceGroupName/providers/Microsoft.HybridCompute/machines/myMachineName"),
// UUID: to.Ptr("vmuuid"),
// },
// },
// },
// {
// Name: to.Ptr("41ee2caf-48f9-4999-a793-82ec7c6beb2c"),
// ID: to.Ptr("/subscriptions/mysubscriptionid/resourceGroups/myResourceGroupName/providers/Microsoft.HybridCompute/machines/myMachineName/providers/Microsoft.GuestConfiguration/guestConfigurationAssignments/AuditSecureProtocol/reports/41ee2caf-48f9-4999-a793-82ec7c6beb2c"),
// Properties: &armguestconfiguration.AssignmentReportProperties{
// Assignment: &armguestconfiguration.AssignmentInfo{
// Name: to.Ptr("AuditSecureProtocol"),
// Configuration: &armguestconfiguration.ConfigurationInfo{
// Name: to.Ptr("AuditSecureProtocol"),
// },
// },
// ComplianceStatus: to.Ptr(armguestconfiguration.ComplianceStatusCompliant),
// EndTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-29T20:14:13.000Z"); return t}()),
// ReportID: to.Ptr("41ee2caf-48f9-4999-a793-82ec7c6beb2c"),
// StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-29T20:13:53.000Z"); return t}()),
// VM: &armguestconfiguration.VMInfo{
// ID: to.Ptr("/subscriptions/mysubscriptionid/resourceGroups/myResourceGroupName/providers/Microsoft.HybridCompute/machines/myMachineName"),
// UUID: to.Ptr("vmuuid"),
// },
// },
// }},
// }
}
type HCRPAssignmentReportsClientGetOptions ¶
type HCRPAssignmentReportsClientGetOptions struct {
}
HCRPAssignmentReportsClientGetOptions contains the optional parameters for the HCRPAssignmentReportsClient.Get method.
type HCRPAssignmentReportsClientGetResponse ¶
type HCRPAssignmentReportsClientGetResponse struct {
// Report for the guest configuration assignment. Report contains information such as compliance status, reason, and more.
AssignmentReport
}
HCRPAssignmentReportsClientGetResponse contains the response from method HCRPAssignmentReportsClient.Get.
type HCRPAssignmentReportsClientListOptions ¶
type HCRPAssignmentReportsClientListOptions struct {
}
HCRPAssignmentReportsClientListOptions contains the optional parameters for the HCRPAssignmentReportsClient.List method.
type HCRPAssignmentReportsClientListResponse ¶
type HCRPAssignmentReportsClientListResponse struct {
// List of guest configuration assignment reports.
AssignmentReportList
}
HCRPAssignmentReportsClientListResponse contains the response from method HCRPAssignmentReportsClient.List.
type HCRPAssignmentsClient ¶
type HCRPAssignmentsClient struct {
// contains filtered or unexported fields
}
HCRPAssignmentsClient contains the methods for the GuestConfigurationHCRPAssignments group. Don't use this type directly, use NewHCRPAssignmentsClient() instead.
func NewHCRPAssignmentsClient ¶
func NewHCRPAssignmentsClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*HCRPAssignmentsClient, error)
NewHCRPAssignmentsClient creates a new instance of HCRPAssignmentsClient with the specified values.
- subscriptionID - Subscription ID which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call.
- credential - used to authorize requests. Usually a credential from azidentity.
- options - pass nil to accept the default values.
func (*HCRPAssignmentsClient) CreateOrUpdate ¶
func (client *HCRPAssignmentsClient) CreateOrUpdate(ctx context.Context, guestConfigurationAssignmentName string, resourceGroupName string, machineName string, parameters Assignment, options *HCRPAssignmentsClientCreateOrUpdateOptions) (HCRPAssignmentsClientCreateOrUpdateResponse, error)
CreateOrUpdate - Creates an association between a ARC machine and guest configuration If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2022-01-25
- guestConfigurationAssignmentName - Name of the guest configuration assignment.
- resourceGroupName - The resource group name.
- machineName - The name of the ARC machine.
- parameters - Parameters supplied to the create or update guest configuration assignment.
- options - HCRPAssignmentsClientCreateOrUpdateOptions contains the optional parameters for the HCRPAssignmentsClient.CreateOrUpdate method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/guestconfiguration/resource-manager/Microsoft.GuestConfiguration/stable/2022-01-25/examples/createOrUpdateGuestConfigurationHCRPAssignment.json
package main
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/guestconfiguration/armguestconfiguration"
)
func main() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armguestconfiguration.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
res, err := clientFactory.NewHCRPAssignmentsClient().CreateOrUpdate(ctx, "NotInstalledApplicationForWindows", "myResourceGroupName", "myMachineName", armguestconfiguration.Assignment{
Name: to.Ptr("NotInstalledApplicationForWindows"),
Location: to.Ptr("westcentralus"),
Properties: &armguestconfiguration.AssignmentProperties{
Context: to.Ptr("Azure policy"),
GuestConfiguration: &armguestconfiguration.Navigation{
Name: to.Ptr("NotInstalledApplicationForWindows"),
AssignmentType: to.Ptr(armguestconfiguration.AssignmentTypeApplyAndAutoCorrect),
ConfigurationParameter: []*armguestconfiguration.ConfigurationParameter{
{
Name: to.Ptr("[InstalledApplication]NotInstalledApplicationResource1;Name"),
Value: to.Ptr("NotePad,sql"),
}},
ContentHash: to.Ptr("123contenthash"),
ContentURI: to.Ptr("https://thisisfake/pacakge"),
Version: to.Ptr("1.*"),
},
},
}, nil)
if err != nil {
log.Fatalf("failed to finish the request: %v", err)
}
// You could use response here. We use blank identifier for just demo purposes.
_ = res
// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// res.Assignment = armguestconfiguration.Assignment{
// Name: to.Ptr("NotInstalledApplicationForWindows"),
// ID: to.Ptr("/subscriptions/mysubscriptionid/resourceGroups/myResourceGroupName/providers/HybridRP.Compute/virtualMachines/myvm/providers/Microsoft.GuestConfiguration/guestConfigurationAssignments/NotInstalledApplicationForWindows"),
// Location: to.Ptr("westcentralus"),
// Properties: &armguestconfiguration.AssignmentProperties{
// AssignmentHash: to.Ptr("abcdr453g"),
// ComplianceStatus: to.Ptr(armguestconfiguration.ComplianceStatusPending),
// Context: to.Ptr("Azure policy"),
// GuestConfiguration: &armguestconfiguration.Navigation{
// Name: to.Ptr("NotInstalledApplicationForWindows"),
// ConfigurationParameter: []*armguestconfiguration.ConfigurationParameter{
// {
// Name: to.Ptr("[InstalledApplication]NotInstalledApplicationResource1;Name"),
// Value: to.Ptr("NotePad,sql"),
// }},
// Version: to.Ptr("1.0.0.3"),
// },
// LatestReportID: to.Ptr("a2a64e5d-a1a9-4344-a866-fb9e1541f723"),
// ProvisioningState: to.Ptr(armguestconfiguration.ProvisioningStateSucceeded),
// },
// }
}
func (*HCRPAssignmentsClient) Delete ¶
func (client *HCRPAssignmentsClient) Delete(ctx context.Context, resourceGroupName string, guestConfigurationAssignmentName string, machineName string, options *HCRPAssignmentsClientDeleteOptions) (HCRPAssignmentsClientDeleteResponse, error)
Delete - Delete a guest configuration assignment If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2022-01-25
- resourceGroupName - The resource group name.
- guestConfigurationAssignmentName - Name of the guest configuration assignment
- machineName - The name of the ARC machine.
- options - HCRPAssignmentsClientDeleteOptions contains the optional parameters for the HCRPAssignmentsClient.Delete method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/guestconfiguration/resource-manager/Microsoft.GuestConfiguration/stable/2022-01-25/examples/deleteGuestConfigurationHCRPAssignment.json
package main
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/guestconfiguration/armguestconfiguration"
)
func main() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armguestconfiguration.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
_, err = clientFactory.NewHCRPAssignmentsClient().Delete(ctx, "myResourceGroupName", "SecureProtocol", "myMachineName", nil)
if err != nil {
log.Fatalf("failed to finish the request: %v", err)
}
}
func (*HCRPAssignmentsClient) Get ¶
func (client *HCRPAssignmentsClient) Get(ctx context.Context, resourceGroupName string, guestConfigurationAssignmentName string, machineName string, options *HCRPAssignmentsClientGetOptions) (HCRPAssignmentsClientGetResponse, error)
Get - Get information about a guest configuration assignment If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2022-01-25
- resourceGroupName - The resource group name.
- guestConfigurationAssignmentName - The guest configuration assignment name.
- machineName - The name of the ARC machine.
- options - HCRPAssignmentsClientGetOptions contains the optional parameters for the HCRPAssignmentsClient.Get method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/guestconfiguration/resource-manager/Microsoft.GuestConfiguration/stable/2022-01-25/examples/getGuestConfigurationHCRPAssignment.json
package main
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/guestconfiguration/armguestconfiguration"
)
func main() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armguestconfiguration.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
res, err := clientFactory.NewHCRPAssignmentsClient().Get(ctx, "myResourceGroupName", "SecureProtocol", "myMachineName", nil)
if err != nil {
log.Fatalf("failed to finish the request: %v", err)
}
// You could use response here. We use blank identifier for just demo purposes.
_ = res
// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// res.Assignment = armguestconfiguration.Assignment{
// Name: to.Ptr("AuditSecureProtocol"),
// ID: to.Ptr("/subscriptions/subscriptionId/resourceGroups/myResourceGroupName/providers/Microsoft.HybridCompute/machines/myMachineName/providers/Microsoft.GuestConfiguration/guestConfigurationAssignments/AuditSecureProtocol"),
// Location: to.Ptr("centraluseuap"),
// Properties: &armguestconfiguration.AssignmentProperties{
// AssignmentHash: to.Ptr("E0D8941DD713F284284561648C00C18FA76C8602943C7CD38AFD73B56AE4C35F.E3B0C44298FC1C149AFBF4C8996FB92427AE41E4649B934CA495991B7852B855"),
// ComplianceStatus: to.Ptr(armguestconfiguration.ComplianceStatusCompliant),
// GuestConfiguration: &armguestconfiguration.Navigation{
// Name: to.Ptr("AuditSecureProtocol"),
// ConfigurationParameter: []*armguestconfiguration.ConfigurationParameter{
// },
// ContentHash: to.Ptr("content hash"),
// ContentURI: to.Ptr("https://mystorageaccount.blob.core.windows.net/builtinconfig/AuditSecureProtocol/AuditSecureProtocol_1.0.0.3.zip"),
// Version: to.Ptr("1.0.0.3"),
// },
// LastComplianceStatusChecked: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-29T22:14:13.000Z"); return t}()),
// LatestReportID: to.Ptr("/subscriptions/subscriptionId/resourceGroups/myResourceGroupName/providers/Microsoft.HybridCompute/machines/myMachineName/providers/Microsoft.GuestConfiguration/guestConfigurationAssignments/AuditSecureProtocol/reports/7367cbb8-ae99-47d0-a33b-a283564d2cb1"),
// ProvisioningState: to.Ptr(armguestconfiguration.ProvisioningStateSucceeded),
// },
// }
}
func (*HCRPAssignmentsClient) NewListPager ¶
func (client *HCRPAssignmentsClient) NewListPager(resourceGroupName string, machineName string, options *HCRPAssignmentsClientListOptions) *runtime.Pager[HCRPAssignmentsClientListResponse]
NewListPager - List all guest configuration assignments for an ARC machine.
Generated from API version 2022-01-25
- resourceGroupName - The resource group name.
- machineName - The name of the ARC machine.
- options - HCRPAssignmentsClientListOptions contains the optional parameters for the HCRPAssignmentsClient.NewListPager method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/guestconfiguration/resource-manager/Microsoft.GuestConfiguration/stable/2022-01-25/examples/listGuestConfigurationHCRPAssignments.json
package main
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/guestconfiguration/armguestconfiguration"
)
func main() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armguestconfiguration.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
pager := clientFactory.NewHCRPAssignmentsClient().NewListPager("myResourceGroupName", "myMachineName", nil)
for pager.More() {
page, err := pager.NextPage(ctx)
if err != nil {
log.Fatalf("failed to advance page: %v", err)
}
for _, v := range page.Value {
// You could use page here. We use blank identifier for just demo purposes.
_ = v
}
// If the HTTP response code is 200 as defined in example definition, your page structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// page.AssignmentList = armguestconfiguration.AssignmentList{
// }
}
}
type HCRPAssignmentsClientCreateOrUpdateOptions ¶
type HCRPAssignmentsClientCreateOrUpdateOptions struct {
}
HCRPAssignmentsClientCreateOrUpdateOptions contains the optional parameters for the HCRPAssignmentsClient.CreateOrUpdate method.
type HCRPAssignmentsClientCreateOrUpdateResponse ¶
type HCRPAssignmentsClientCreateOrUpdateResponse struct {
// Guest configuration assignment is an association between a machine and guest configuration.
Assignment
}
HCRPAssignmentsClientCreateOrUpdateResponse contains the response from method HCRPAssignmentsClient.CreateOrUpdate.
type HCRPAssignmentsClientDeleteOptions ¶
type HCRPAssignmentsClientDeleteOptions struct {
}
HCRPAssignmentsClientDeleteOptions contains the optional parameters for the HCRPAssignmentsClient.Delete method.
type HCRPAssignmentsClientDeleteResponse ¶
type HCRPAssignmentsClientDeleteResponse struct {
}
HCRPAssignmentsClientDeleteResponse contains the response from method HCRPAssignmentsClient.Delete.
type HCRPAssignmentsClientGetOptions ¶
type HCRPAssignmentsClientGetOptions struct {
}
HCRPAssignmentsClientGetOptions contains the optional parameters for the HCRPAssignmentsClient.Get method.
type HCRPAssignmentsClientGetResponse ¶
type HCRPAssignmentsClientGetResponse struct {
// Guest configuration assignment is an association between a machine and guest configuration.
Assignment
}
HCRPAssignmentsClientGetResponse contains the response from method HCRPAssignmentsClient.Get.
type HCRPAssignmentsClientListOptions ¶
type HCRPAssignmentsClientListOptions struct {
}
HCRPAssignmentsClientListOptions contains the optional parameters for the HCRPAssignmentsClient.NewListPager method.
type HCRPAssignmentsClientListResponse ¶
type HCRPAssignmentsClientListResponse struct {
// The response of the list guest configuration assignment operation.
AssignmentList
}
HCRPAssignmentsClientListResponse contains the response from method HCRPAssignmentsClient.NewListPager.
type Kind ¶
type Kind string
Kind - Kind of the guest configuration. For example:DSC
const (
KindDSC Kind = "DSC"
)
func PossibleKindValues ¶
func PossibleKindValues() []Kind
PossibleKindValues returns the possible values for the Kind const type.
type Navigation ¶
type Navigation struct {
// and ApplyAndMonitor.
AssignmentType *AssignmentType
ConfigurationParameter []*ConfigurationParameter
ConfigurationProtectedParameter []*ConfigurationParameter
ContentHash *string
ContentURI *string
Kind *Kind
Name *string
Version *string
AssignmentSource *string
ConfigurationSetting *ConfigurationSetting
ContentType *string
}
Navigation - Guest configuration is an artifact that encapsulates DSC configuration and its dependencies. The artifact is a zip file containing DSC configuration (as MOF) and dependent resources and other dependencies like modules.
func (Navigation) MarshalJSON ¶
func (n Navigation) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type Navigation.
func (*Navigation) UnmarshalJSON ¶
func (n *Navigation) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type Navigation.
type Operation ¶
type Operation struct {
// Provider, Resource, Operation and description values.
Display *OperationDisplay
// Operation name: For ex. providers/Microsoft.GuestConfiguration/guestConfigurationAssignments/write or read
Name *string
// Provider, Resource, Operation and description values.
Properties *OperationProperties
}
Operation - GuestConfiguration REST API operation
func (Operation) MarshalJSON ¶
MarshalJSON implements the json.Marshaller interface for type Operation.
func (*Operation) UnmarshalJSON ¶
UnmarshalJSON implements the json.Unmarshaller interface for type Operation.
type OperationDisplay ¶
type OperationDisplay struct {
// Description about operation.
Description *string
// Operation type: Read, write, delete, etc.
Operation *string
// Service provider: Microsoft.GuestConfiguration
Provider *string
// Resource on which the operation is performed: For ex.
Resource *string
}
OperationDisplay - Provider, Resource, Operation and description values.
func (OperationDisplay) MarshalJSON ¶
func (o OperationDisplay) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type OperationDisplay.
func (*OperationDisplay) UnmarshalJSON ¶
func (o *OperationDisplay) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type OperationDisplay.
type OperationList ¶
type OperationList struct {
// List of Automation operations supported by the Automation resource provider.
Value []*Operation
}
OperationList - The response model for the list of Automation operations
func (OperationList) MarshalJSON ¶
func (o OperationList) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type OperationList.
func (*OperationList) UnmarshalJSON ¶
func (o *OperationList) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type OperationList.
type OperationProperties ¶
type OperationProperties struct {
// Service provider: Microsoft.GuestConfiguration
StatusCode *string
}
OperationProperties - Provider, Resource, Operation and description values.
func (OperationProperties) MarshalJSON ¶
func (o OperationProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type OperationProperties.
func (*OperationProperties) UnmarshalJSON ¶
func (o *OperationProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type OperationProperties.
type OperationsClient ¶
type OperationsClient struct {
// contains filtered or unexported fields
}
OperationsClient contains the methods for the Operations group. Don't use this type directly, use NewOperationsClient() instead.
func NewOperationsClient ¶
func NewOperationsClient(credential azcore.TokenCredential, options *arm.ClientOptions) (*OperationsClient, error)
NewOperationsClient creates a new instance of OperationsClient with the specified values.
- credential - used to authorize requests. Usually a credential from azidentity.
- options - pass nil to accept the default values.
func (*OperationsClient) NewListPager ¶
func (client *OperationsClient) NewListPager(options *OperationsClientListOptions) *runtime.Pager[OperationsClientListResponse]
NewListPager - Lists all of the available GuestConfiguration REST API operations.
Generated from API version 2022-01-25
- options - OperationsClientListOptions contains the optional parameters for the OperationsClient.NewListPager method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/guestconfiguration/resource-manager/Microsoft.GuestConfiguration/stable/2022-01-25/examples/listOperations.json
package main
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/guestconfiguration/armguestconfiguration"
)
func main() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armguestconfiguration.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
pager := clientFactory.NewOperationsClient().NewListPager(nil)
for pager.More() {
page, err := pager.NextPage(ctx)
if err != nil {
log.Fatalf("failed to advance page: %v", err)
}
for _, v := range page.Value {
// You could use page here. We use blank identifier for just demo purposes.
_ = v
}
// If the HTTP response code is 200 as defined in example definition, your page structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// page.OperationList = armguestconfiguration.OperationList{
// Value: []*armguestconfiguration.Operation{
// {
// Name: to.Ptr("Microsoft.GuestConfiguration/guestConfigurationAssignments/write"),
// Display: &armguestconfiguration.OperationDisplay{
// Description: to.Ptr("Create new guest configuration assignment."),
// Operation: to.Ptr("Microsoft.GuestConfiguration/guestConfigurationAssignments/write"),
// Provider: to.Ptr("Microsoft Guest Configuration"),
// Resource: to.Ptr("Microsoft.GuestConfiguration/guestConfigurationAssignments"),
// },
// },
// {
// Name: to.Ptr("Microsoft.GuestConfiguration/register/action"),
// Display: &armguestconfiguration.OperationDisplay{
// Description: to.Ptr("Registers the subscription for the Microsoft.GuestConfiguration resource provider."),
// Operation: to.Ptr("Registers the feature for Microsoft.GuestConfiguration."),
// Provider: to.Ptr("Microsoft Guest Configuration"),
// Resource: to.Ptr("Register"),
// },
// },
// {
// Name: to.Ptr("Microsoft.GuestConfiguration/guestConfigurationAssignments/read"),
// Display: &armguestconfiguration.OperationDisplay{
// Description: to.Ptr("Get guest configuration assignment."),
// Operation: to.Ptr("Microsoft.GuestConfiguration/guestConfigurationAssignments/read"),
// Provider: to.Ptr("Microsoft Guest Configuration"),
// Resource: to.Ptr("Microsoft.GuestConfiguration/guestConfigurationAssignments"),
// },
// },
// {
// Name: to.Ptr("Microsoft.GuestConfiguration/guestConfigurationAssignments/reports/read"),
// Display: &armguestconfiguration.OperationDisplay{
// Description: to.Ptr("Get guest configuration assignment report."),
// Operation: to.Ptr("Microsoft.GuestConfiguration/guestConfigurationAssignments/reports/read"),
// Provider: to.Ptr("Microsoft Guest Configuration"),
// Resource: to.Ptr("Microsoft.GuestConfiguration/guestConfigurationAssignments"),
// },
// }},
// }
}
}
type OperationsClientListOptions ¶
type OperationsClientListOptions struct {
}
OperationsClientListOptions contains the optional parameters for the OperationsClient.NewListPager method.
type OperationsClientListResponse ¶
type OperationsClientListResponse struct {
// The response model for the list of Automation operations
OperationList
}
OperationsClientListResponse contains the response from method OperationsClient.NewListPager.
type ProvisioningState ¶
type ProvisioningState string
ProvisioningState - The provisioning state, which only appears in the response.
const ( ProvisioningStateCanceled ProvisioningState = "Canceled" ProvisioningStateCreated ProvisioningState = "Created" ProvisioningStateFailed ProvisioningState = "Failed" ProvisioningStateSucceeded ProvisioningState = "Succeeded" )
func PossibleProvisioningStateValues ¶
func PossibleProvisioningStateValues() []ProvisioningState
PossibleProvisioningStateValues returns the possible values for the ProvisioningState const type.
type ProxyResource ¶
type ProxyResource struct {
// Region where the VM is located.
Location *string
// Name of the guest configuration assignment.
Name *string
// READ-ONLY; ARM resource id of the guest configuration assignment.
ID *string
// READ-ONLY; The type of the resource.
Type *string
}
ProxyResource - ARM proxy resource.
func (ProxyResource) MarshalJSON ¶
func (p ProxyResource) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ProxyResource.
func (*ProxyResource) UnmarshalJSON ¶
func (p *ProxyResource) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ProxyResource.
type Resource ¶
type Resource struct {
// Region where the VM is located.
Location *string
// Name of the guest configuration assignment.
Name *string
// READ-ONLY; ARM resource id of the guest configuration assignment.
ID *string
// READ-ONLY; The type of the resource.
Type *string
}
Resource - The core properties of ARM resources
func (Resource) MarshalJSON ¶
MarshalJSON implements the json.Marshaller interface for type Resource.
func (*Resource) UnmarshalJSON ¶
UnmarshalJSON implements the json.Unmarshaller interface for type Resource.
type SystemData ¶
type SystemData struct {
// The timestamp of resource creation (UTC).
CreatedAt *time.Time
// The identity that created the resource.
CreatedBy *string
// The type of identity that created the resource.
CreatedByType *CreatedByType
// The timestamp of resource last modification (UTC)
LastModifiedAt *time.Time
// The identity that last modified the resource.
LastModifiedBy *string
// The type of identity that last modified the resource.
LastModifiedByType *CreatedByType
}
SystemData - Metadata pertaining to creation and last modification of the resource.
func (SystemData) MarshalJSON ¶
func (s SystemData) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type SystemData.
func (*SystemData) UnmarshalJSON ¶
func (s *SystemData) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type SystemData.
type Type ¶
type Type string
Type - Type of report, Consistency or Initial
func PossibleTypeValues ¶
func PossibleTypeValues() []Type
PossibleTypeValues returns the possible values for the Type const type.
type VMInfo ¶
type VMInfo struct {
// READ-ONLY; Azure resource Id of the VM.
ID *string
// READ-ONLY; UUID(Universally Unique Identifier) of the VM.
UUID *string
}
VMInfo - Information about the VM.
func (VMInfo) MarshalJSON ¶
MarshalJSON implements the json.Marshaller interface for type VMInfo.
func (*VMInfo) UnmarshalJSON ¶
UnmarshalJSON implements the json.Unmarshaller interface for type VMInfo.
type VMSSVMInfo ¶
type VMSSVMInfo struct {
// READ-ONLY; A value indicating compliance status of the machine for the assigned guest configuration.
ComplianceStatus *ComplianceStatus
// READ-ONLY; Date and time when last compliance status was checked.
LastComplianceChecked *time.Time
// READ-ONLY; Id of the latest report for the guest configuration assignment.
LatestReportID *string
// READ-ONLY; UUID of the VM.
VMID *string
// READ-ONLY; Azure resource Id of the VM.
VMResourceID *string
}
VMSSVMInfo - Information about VMSS VM
func (VMSSVMInfo) MarshalJSON ¶
func (v VMSSVMInfo) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type VMSSVMInfo.
func (*VMSSVMInfo) UnmarshalJSON ¶
func (v *VMSSVMInfo) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type VMSSVMInfo.