Documentation ¶
Index ¶
- type AccessMode
- type AccessRule
- type AccessRuleDirection
- type AccessRuleProperties
- type AgentConfiguration
- type AgentConfigurationMode
- type AgentUpgrade
- type ArcKindEnum
- type AssessmentModeTypes
- type AvailablePatchCountByClassification
- type ClientFactory
- func (c *ClientFactory) NewExtensionMetadataClient() *ExtensionMetadataClient
- func (c *ClientFactory) NewLicenseProfilesClient() *LicenseProfilesClient
- func (c *ClientFactory) NewLicensesClient() *LicensesClient
- func (c *ClientFactory) NewMachineExtensionsClient() *MachineExtensionsClient
- func (c *ClientFactory) NewMachinesClient() *MachinesClient
- func (c *ClientFactory) NewManagementClient() *ManagementClient
- func (c *ClientFactory) NewNetworkProfileClient() *NetworkProfileClient
- func (c *ClientFactory) NewNetworkSecurityPerimeterConfigurationsClient() *NetworkSecurityPerimeterConfigurationsClient
- func (c *ClientFactory) NewOperationsClient() *OperationsClient
- func (c *ClientFactory) NewPrivateEndpointConnectionsClient() *PrivateEndpointConnectionsClient
- func (c *ClientFactory) NewPrivateLinkResourcesClient() *PrivateLinkResourcesClient
- func (c *ClientFactory) NewPrivateLinkScopesClient() *PrivateLinkScopesClient
- type CloudMetadata
- type ConfigurationExtension
- type ConnectionDetail
- type CreatedByType
- type ErrorAdditionalInfo
- type ErrorDetail
- type EsuEligibility
- type EsuKey
- type EsuKeyState
- type EsuProfileUpdateProperties
- type EsuServerType
- type ExtensionMetadataClient
- func (client *ExtensionMetadataClient) Get(ctx context.Context, location string, publisher string, extensionType string, ...) (ExtensionMetadataClientGetResponse, error)
- func (client *ExtensionMetadataClient) NewListPager(location string, publisher string, extensionType string, ...) *runtime.Pager[ExtensionMetadataClientListResponse]
- type ExtensionMetadataClientGetOptions
- type ExtensionMetadataClientGetResponse
- type ExtensionMetadataClientListOptions
- type ExtensionMetadataClientListResponse
- type ExtensionTargetProperties
- type ExtensionValue
- type ExtensionValueListResult
- type ExtensionValueProperties
- type HotpatchEnablementStatus
- type IPAddress
- type Identity
- type InstanceViewTypes
- type LastAttemptStatusEnum
- type License
- type LicenseAssignmentState
- type LicenseCoreType
- type LicenseDetails
- type LicenseEdition
- type LicenseProfile
- type LicenseProfileArmEsuProperties
- type LicenseProfileArmProductProfileProperties
- type LicenseProfileMachineInstanceView
- type LicenseProfileMachineInstanceViewEsuProperties
- type LicenseProfileMachineInstanceViewSoftwareAssurance
- type LicenseProfileProductType
- type LicenseProfileProperties
- type LicenseProfilePropertiesSoftwareAssurance
- type LicenseProfileSubscriptionStatus
- type LicenseProfileSubscriptionStatusUpdate
- type LicenseProfileUpdate
- type LicenseProfileUpdateProperties
- type LicenseProfileUpdatePropertiesSoftwareAssurance
- type LicenseProfilesClient
- func (client *LicenseProfilesClient) BeginCreateOrUpdate(ctx context.Context, resourceGroupName string, machineName string, ...) (*runtime.Poller[LicenseProfilesClientCreateOrUpdateResponse], error)
- func (client *LicenseProfilesClient) BeginDelete(ctx context.Context, resourceGroupName string, machineName string, ...) (*runtime.Poller[LicenseProfilesClientDeleteResponse], error)
- func (client *LicenseProfilesClient) BeginUpdate(ctx context.Context, resourceGroupName string, machineName string, ...) (*runtime.Poller[LicenseProfilesClientUpdateResponse], error)
- func (client *LicenseProfilesClient) Get(ctx context.Context, resourceGroupName string, machineName string, ...) (LicenseProfilesClientGetResponse, error)
- func (client *LicenseProfilesClient) NewListPager(resourceGroupName string, machineName string, ...) *runtime.Pager[LicenseProfilesClientListResponse]
- type LicenseProfilesClientBeginCreateOrUpdateOptions
- type LicenseProfilesClientBeginDeleteOptions
- type LicenseProfilesClientBeginUpdateOptions
- type LicenseProfilesClientCreateOrUpdateResponse
- type LicenseProfilesClientDeleteResponse
- type LicenseProfilesClientGetOptions
- type LicenseProfilesClientGetResponse
- type LicenseProfilesClientListOptions
- type LicenseProfilesClientListResponse
- type LicenseProfilesClientUpdateResponse
- type LicenseProfilesListResult
- type LicenseProperties
- type LicenseState
- type LicenseStatus
- type LicenseTarget
- type LicenseType
- type LicenseUpdate
- type LicenseUpdateProperties
- type LicenseUpdatePropertiesLicenseDetails
- type LicensesClient
- func (client *LicensesClient) BeginCreateOrUpdate(ctx context.Context, resourceGroupName string, licenseName string, ...) (*runtime.Poller[LicensesClientCreateOrUpdateResponse], error)
- func (client *LicensesClient) BeginDelete(ctx context.Context, resourceGroupName string, licenseName string, ...) (*runtime.Poller[LicensesClientDeleteResponse], error)
- func (client *LicensesClient) BeginUpdate(ctx context.Context, resourceGroupName string, licenseName string, ...) (*runtime.Poller[LicensesClientUpdateResponse], error)
- func (client *LicensesClient) BeginValidateLicense(ctx context.Context, parameters License, ...) (*runtime.Poller[LicensesClientValidateLicenseResponse], error)
- func (client *LicensesClient) Get(ctx context.Context, resourceGroupName string, licenseName string, ...) (LicensesClientGetResponse, error)
- func (client *LicensesClient) NewListByResourceGroupPager(resourceGroupName string, options *LicensesClientListByResourceGroupOptions) *runtime.Pager[LicensesClientListByResourceGroupResponse]
- func (client *LicensesClient) NewListBySubscriptionPager(options *LicensesClientListBySubscriptionOptions) *runtime.Pager[LicensesClientListBySubscriptionResponse]
- type LicensesClientBeginCreateOrUpdateOptions
- type LicensesClientBeginDeleteOptions
- type LicensesClientBeginUpdateOptions
- type LicensesClientBeginValidateLicenseOptions
- type LicensesClientCreateOrUpdateResponse
- type LicensesClientDeleteResponse
- type LicensesClientGetOptions
- type LicensesClientGetResponse
- type LicensesClientListByResourceGroupOptions
- type LicensesClientListByResourceGroupResponse
- type LicensesClientListBySubscriptionOptions
- type LicensesClientListBySubscriptionResponse
- type LicensesClientUpdateResponse
- type LicensesClientValidateLicenseResponse
- type LicensesListResult
- type LinuxParameters
- type LocationData
- type Machine
- type MachineAssessPatchesResult
- type MachineExtension
- type MachineExtensionInstanceView
- type MachineExtensionInstanceViewStatus
- type MachineExtensionProperties
- type MachineExtensionUpdate
- type MachineExtensionUpdateProperties
- type MachineExtensionUpgrade
- type MachineExtensionsClient
- func (client *MachineExtensionsClient) BeginCreateOrUpdate(ctx context.Context, resourceGroupName string, machineName string, ...) (*runtime.Poller[MachineExtensionsClientCreateOrUpdateResponse], error)
- func (client *MachineExtensionsClient) BeginDelete(ctx context.Context, resourceGroupName string, machineName string, ...) (*runtime.Poller[MachineExtensionsClientDeleteResponse], error)
- func (client *MachineExtensionsClient) BeginUpdate(ctx context.Context, resourceGroupName string, machineName string, ...) (*runtime.Poller[MachineExtensionsClientUpdateResponse], error)
- func (client *MachineExtensionsClient) Get(ctx context.Context, resourceGroupName string, machineName string, ...) (MachineExtensionsClientGetResponse, error)
- func (client *MachineExtensionsClient) NewListPager(resourceGroupName string, machineName string, ...) *runtime.Pager[MachineExtensionsClientListResponse]
- type MachineExtensionsClientBeginCreateOrUpdateOptions
- type MachineExtensionsClientBeginDeleteOptions
- type MachineExtensionsClientBeginUpdateOptions
- type MachineExtensionsClientCreateOrUpdateResponse
- type MachineExtensionsClientDeleteResponse
- type MachineExtensionsClientGetOptions
- type MachineExtensionsClientGetResponse
- type MachineExtensionsClientListOptions
- type MachineExtensionsClientListResponse
- type MachineExtensionsClientUpdateResponse
- type MachineExtensionsListResult
- type MachineInstallPatchesParameters
- type MachineInstallPatchesResult
- type MachineListResult
- type MachineProperties
- type MachineUpdate
- type MachineUpdateProperties
- type MachinesClient
- func (client *MachinesClient) BeginAssessPatches(ctx context.Context, resourceGroupName string, name string, ...) (*runtime.Poller[MachinesClientAssessPatchesResponse], error)
- func (client *MachinesClient) BeginInstallPatches(ctx context.Context, resourceGroupName string, name string, ...) (*runtime.Poller[MachinesClientInstallPatchesResponse], error)
- func (client *MachinesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, machineName string, ...) (MachinesClientCreateOrUpdateResponse, error)
- func (client *MachinesClient) Delete(ctx context.Context, resourceGroupName string, machineName string, ...) (MachinesClientDeleteResponse, error)
- func (client *MachinesClient) Get(ctx context.Context, resourceGroupName string, machineName string, ...) (MachinesClientGetResponse, error)
- func (client *MachinesClient) NewListByResourceGroupPager(resourceGroupName string, options *MachinesClientListByResourceGroupOptions) *runtime.Pager[MachinesClientListByResourceGroupResponse]
- func (client *MachinesClient) NewListBySubscriptionPager(options *MachinesClientListBySubscriptionOptions) *runtime.Pager[MachinesClientListBySubscriptionResponse]
- func (client *MachinesClient) Update(ctx context.Context, resourceGroupName string, machineName string, ...) (MachinesClientUpdateResponse, error)
- type MachinesClientAssessPatchesResponse
- type MachinesClientBeginAssessPatchesOptions
- type MachinesClientBeginInstallPatchesOptions
- type MachinesClientCreateOrUpdateOptions
- type MachinesClientCreateOrUpdateResponse
- type MachinesClientDeleteOptions
- type MachinesClientDeleteResponse
- type MachinesClientGetOptions
- type MachinesClientGetResponse
- type MachinesClientInstallPatchesResponse
- type MachinesClientListByResourceGroupOptions
- type MachinesClientListByResourceGroupResponse
- type MachinesClientListBySubscriptionOptions
- type MachinesClientListBySubscriptionResponse
- type MachinesClientUpdateOptions
- type MachinesClientUpdateResponse
- type ManagementClient
- type ManagementClientBeginUpgradeExtensionsOptions
- type ManagementClientUpgradeExtensionsResponse
- type NetworkInterface
- type NetworkProfile
- type NetworkProfileClient
- type NetworkProfileClientGetOptions
- type NetworkProfileClientGetResponse
- type NetworkSecurityPerimeter
- type NetworkSecurityPerimeterConfiguration
- type NetworkSecurityPerimeterConfigurationListResult
- type NetworkSecurityPerimeterConfigurationProperties
- type NetworkSecurityPerimeterConfigurationReconcileResult
- type NetworkSecurityPerimeterConfigurationsClient
- func (client *NetworkSecurityPerimeterConfigurationsClient) BeginReconcileForPrivateLinkScope(ctx context.Context, resourceGroupName string, scopeName string, ...) (...)
- func (client *NetworkSecurityPerimeterConfigurationsClient) GetByPrivateLinkScope(ctx context.Context, resourceGroupName string, scopeName string, ...) (NetworkSecurityPerimeterConfigurationsClientGetByPrivateLinkScopeResponse, ...)
- func (client *NetworkSecurityPerimeterConfigurationsClient) NewListByPrivateLinkScopePager(resourceGroupName string, scopeName string, ...) ...
- type NetworkSecurityPerimeterConfigurationsClientBeginReconcileForPrivateLinkScopeOptions
- type NetworkSecurityPerimeterConfigurationsClientGetByPrivateLinkScopeOptions
- type NetworkSecurityPerimeterConfigurationsClientGetByPrivateLinkScopeResponse
- type NetworkSecurityPerimeterConfigurationsClientListByPrivateLinkScopeOptions
- type NetworkSecurityPerimeterConfigurationsClientListByPrivateLinkScopeResponse
- type NetworkSecurityPerimeterConfigurationsClientReconcileForPrivateLinkScopeResponse
- type NetworkSecurityPerimeterProfile
- type OSProfile
- type OSProfileLinuxConfiguration
- type OSProfileWindowsConfiguration
- type OperationListResult
- type OperationValue
- type OperationValueDisplay
- type OperationsClient
- type OperationsClientListOptions
- type OperationsClientListResponse
- type OsType
- type PatchModeTypes
- type PatchOperationStartedBy
- type PatchOperationStatus
- type PatchServiceUsed
- type PatchSettings
- type PatchSettingsStatus
- type PrivateEndpointConnection
- type PrivateEndpointConnectionDataModel
- type PrivateEndpointConnectionListResult
- type PrivateEndpointConnectionProperties
- type PrivateEndpointConnectionsClient
- func (client *PrivateEndpointConnectionsClient) BeginCreateOrUpdate(ctx context.Context, resourceGroupName string, scopeName string, ...) (*runtime.Poller[PrivateEndpointConnectionsClientCreateOrUpdateResponse], error)
- func (client *PrivateEndpointConnectionsClient) BeginDelete(ctx context.Context, resourceGroupName string, scopeName string, ...) (*runtime.Poller[PrivateEndpointConnectionsClientDeleteResponse], error)
- func (client *PrivateEndpointConnectionsClient) Get(ctx context.Context, resourceGroupName string, scopeName string, ...) (PrivateEndpointConnectionsClientGetResponse, error)
- func (client *PrivateEndpointConnectionsClient) NewListByPrivateLinkScopePager(resourceGroupName string, scopeName string, ...) *runtime.Pager[PrivateEndpointConnectionsClientListByPrivateLinkScopeResponse]
- type PrivateEndpointConnectionsClientBeginCreateOrUpdateOptions
- type PrivateEndpointConnectionsClientBeginDeleteOptions
- type PrivateEndpointConnectionsClientCreateOrUpdateResponse
- type PrivateEndpointConnectionsClientDeleteResponse
- type PrivateEndpointConnectionsClientGetOptions
- type PrivateEndpointConnectionsClientGetResponse
- type PrivateEndpointConnectionsClientListByPrivateLinkScopeOptions
- type PrivateEndpointConnectionsClientListByPrivateLinkScopeResponse
- type PrivateEndpointProperty
- type PrivateLinkResource
- type PrivateLinkResourceListResult
- type PrivateLinkResourceProperties
- type PrivateLinkResourcesClient
- func (client *PrivateLinkResourcesClient) Get(ctx context.Context, resourceGroupName string, scopeName string, ...) (PrivateLinkResourcesClientGetResponse, error)
- func (client *PrivateLinkResourcesClient) NewListByPrivateLinkScopePager(resourceGroupName string, scopeName string, ...) *runtime.Pager[PrivateLinkResourcesClientListByPrivateLinkScopeResponse]
- type PrivateLinkResourcesClientGetOptions
- type PrivateLinkResourcesClientGetResponse
- type PrivateLinkResourcesClientListByPrivateLinkScopeOptions
- type PrivateLinkResourcesClientListByPrivateLinkScopeResponse
- type PrivateLinkScope
- type PrivateLinkScopeListResult
- type PrivateLinkScopeProperties
- type PrivateLinkScopeValidationDetails
- type PrivateLinkScopesClient
- func (client *PrivateLinkScopesClient) BeginDelete(ctx context.Context, resourceGroupName string, scopeName string, ...) (*runtime.Poller[PrivateLinkScopesClientDeleteResponse], error)
- func (client *PrivateLinkScopesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, scopeName string, ...) (PrivateLinkScopesClientCreateOrUpdateResponse, error)
- func (client *PrivateLinkScopesClient) Get(ctx context.Context, resourceGroupName string, scopeName string, ...) (PrivateLinkScopesClientGetResponse, error)
- func (client *PrivateLinkScopesClient) GetValidationDetails(ctx context.Context, location string, privateLinkScopeID string, ...) (PrivateLinkScopesClientGetValidationDetailsResponse, error)
- func (client *PrivateLinkScopesClient) GetValidationDetailsForMachine(ctx context.Context, resourceGroupName string, machineName string, ...) (PrivateLinkScopesClientGetValidationDetailsForMachineResponse, error)
- func (client *PrivateLinkScopesClient) NewListByResourceGroupPager(resourceGroupName string, ...) *runtime.Pager[PrivateLinkScopesClientListByResourceGroupResponse]
- func (client *PrivateLinkScopesClient) NewListPager(options *PrivateLinkScopesClientListOptions) *runtime.Pager[PrivateLinkScopesClientListResponse]
- func (client *PrivateLinkScopesClient) UpdateTags(ctx context.Context, resourceGroupName string, scopeName string, ...) (PrivateLinkScopesClientUpdateTagsResponse, error)
- type PrivateLinkScopesClientBeginDeleteOptions
- type PrivateLinkScopesClientCreateOrUpdateOptions
- type PrivateLinkScopesClientCreateOrUpdateResponse
- type PrivateLinkScopesClientDeleteResponse
- type PrivateLinkScopesClientGetOptions
- type PrivateLinkScopesClientGetResponse
- type PrivateLinkScopesClientGetValidationDetailsForMachineOptions
- type PrivateLinkScopesClientGetValidationDetailsForMachineResponse
- type PrivateLinkScopesClientGetValidationDetailsOptions
- type PrivateLinkScopesClientGetValidationDetailsResponse
- type PrivateLinkScopesClientListByResourceGroupOptions
- type PrivateLinkScopesClientListByResourceGroupResponse
- type PrivateLinkScopesClientListOptions
- type PrivateLinkScopesClientListResponse
- type PrivateLinkScopesClientUpdateTagsOptions
- type PrivateLinkScopesClientUpdateTagsResponse
- type PrivateLinkServiceConnectionStateProperty
- type ProductFeature
- type ProductFeatureUpdate
- type ProductProfileUpdateProperties
- type ProgramYear
- type ProvisioningIssue
- type ProvisioningIssueProperties
- type ProvisioningIssueSeverity
- type ProvisioningIssueType
- type ProvisioningState
- type PublicNetworkAccessType
- type ResourceAssociation
- type ServiceStatus
- type ServiceStatuses
- type StatusLevelTypes
- type StatusTypes
- type Subnet
- type SystemData
- type TagsResource
- type VMGuestPatchClassificationLinux
- type VMGuestPatchClassificationWindows
- type VMGuestPatchRebootSetting
- type VMGuestPatchRebootStatus
- type VolumeLicenseDetails
- type WindowsParameters
Examples ¶
- ExtensionMetadataClient.Get
- ExtensionMetadataClient.NewListPager
- LicenseProfilesClient.BeginCreateOrUpdate
- LicenseProfilesClient.BeginDelete
- LicenseProfilesClient.BeginUpdate
- LicenseProfilesClient.Get
- LicenseProfilesClient.NewListPager
- LicensesClient.BeginCreateOrUpdate
- LicensesClient.BeginDelete
- LicensesClient.BeginUpdate
- LicensesClient.BeginValidateLicense
- LicensesClient.Get
- LicensesClient.NewListByResourceGroupPager
- LicensesClient.NewListBySubscriptionPager
- MachineExtensionsClient.BeginCreateOrUpdate
- MachineExtensionsClient.BeginDelete
- MachineExtensionsClient.BeginUpdate
- MachineExtensionsClient.Get
- MachineExtensionsClient.NewListPager
- MachinesClient.BeginAssessPatches
- MachinesClient.BeginInstallPatches
- MachinesClient.CreateOrUpdate
- MachinesClient.Delete
- MachinesClient.Get (GetMachine)
- MachinesClient.Get (GetMachineWithLicenseProfileInstanceView)
- MachinesClient.NewListByResourceGroupPager
- MachinesClient.NewListBySubscriptionPager
- MachinesClient.Update
- ManagementClient.BeginUpgradeExtensions
- NetworkProfileClient.Get
- NetworkSecurityPerimeterConfigurationsClient.BeginReconcileForPrivateLinkScope
- NetworkSecurityPerimeterConfigurationsClient.GetByPrivateLinkScope
- NetworkSecurityPerimeterConfigurationsClient.NewListByPrivateLinkScopePager
- OperationsClient.NewListPager
- PrivateEndpointConnectionsClient.BeginCreateOrUpdate
- PrivateEndpointConnectionsClient.BeginDelete
- PrivateEndpointConnectionsClient.Get
- PrivateEndpointConnectionsClient.NewListByPrivateLinkScopePager
- PrivateLinkResourcesClient.Get
- PrivateLinkResourcesClient.NewListByPrivateLinkScopePager
- PrivateLinkScopesClient.BeginDelete
- PrivateLinkScopesClient.CreateOrUpdate (PrivateLinkScopeCreate)
- PrivateLinkScopesClient.CreateOrUpdate (PrivateLinkScopeUpdate)
- PrivateLinkScopesClient.Get
- PrivateLinkScopesClient.GetValidationDetails
- PrivateLinkScopesClient.GetValidationDetailsForMachine
- PrivateLinkScopesClient.NewListByResourceGroupPager
- PrivateLinkScopesClient.NewListPager
- PrivateLinkScopesClient.UpdateTags
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AccessMode ¶
type AccessMode string
AccessMode - Property that impacts a resource's logging behavior and its connectivity with other resources and public networks.
const ( // AccessModeAudit - Dry run mode, where traffic is evaluated against NSP Rules, logged but not enforced. AccessModeAudit AccessMode = "audit" // AccessModeEnforced - Indicates that resource access is controlled by the NSP definition. AccessModeEnforced AccessMode = "enforced" // AccessModeLearning - Enables traffic evaluation to fall back to resource-specific firewall configurations. AccessModeLearning AccessMode = "learning" )
func PossibleAccessModeValues ¶
func PossibleAccessModeValues() []AccessMode
PossibleAccessModeValues returns the possible values for the AccessMode const type.
type AccessRule ¶
type AccessRule struct { // READ-ONLY; Name of the access rule. Name *string // READ-ONLY; Access rule properties Properties *AccessRuleProperties }
AccessRule - Access rule.
func (AccessRule) MarshalJSON ¶
func (a AccessRule) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type AccessRule.
func (*AccessRule) UnmarshalJSON ¶
func (a *AccessRule) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type AccessRule.
type AccessRuleDirection ¶
type AccessRuleDirection string
AccessRuleDirection - Indicates direction of an access rule.
const ( // AccessRuleDirectionInbound - Traffic originates outside of network. AccessRuleDirectionInbound AccessRuleDirection = "Inbound" // AccessRuleDirectionOutbound - Traffic originates inside the network AccessRuleDirectionOutbound AccessRuleDirection = "Outbound" )
func PossibleAccessRuleDirectionValues ¶
func PossibleAccessRuleDirectionValues() []AccessRuleDirection
PossibleAccessRuleDirectionValues returns the possible values for the AccessRuleDirection const type.
type AccessRuleProperties ¶
type AccessRuleProperties struct { // READ-ONLY; Address prefixes that are allowed access. AddressPrefixes []*string // READ-ONLY; Direction of the access rule. Direction *AccessRuleDirection }
AccessRuleProperties - Properties of an access rule.
func (AccessRuleProperties) MarshalJSON ¶
func (a AccessRuleProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type AccessRuleProperties.
func (*AccessRuleProperties) UnmarshalJSON ¶
func (a *AccessRuleProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type AccessRuleProperties.
type AgentConfiguration ¶
type AgentConfiguration struct { // READ-ONLY; Name of configuration mode to use. Modes are pre-defined configurations of security controls, extension allowlists // and guest configuration, maintained by Microsoft. ConfigMode *AgentConfigurationMode // READ-ONLY; Array of extensions that are allowed to be installed or updated. ExtensionsAllowList []*ConfigurationExtension // READ-ONLY; Array of extensions that are blocked (cannot be installed or updated) ExtensionsBlockList []*ConfigurationExtension // READ-ONLY; Specifies whether the extension service is enabled or disabled. ExtensionsEnabled *string // READ-ONLY; Specified whether the guest configuration service is enabled or disabled. GuestConfigurationEnabled *string // READ-ONLY; Specifies the list of ports that the agent will be able to listen on. IncomingConnectionsPorts []*string // READ-ONLY; List of service names which should not use the specified proxy server. ProxyBypass []*string // READ-ONLY; Specifies the URL of the proxy to be used. ProxyURL *string }
AgentConfiguration - Configurable properties that the user can set locally via the azcmagent config command, or remotely via ARM.
func (AgentConfiguration) MarshalJSON ¶
func (a AgentConfiguration) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type AgentConfiguration.
func (*AgentConfiguration) UnmarshalJSON ¶
func (a *AgentConfiguration) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type AgentConfiguration.
type AgentConfigurationMode ¶
type AgentConfigurationMode string
AgentConfigurationMode - Name of configuration mode to use. Modes are pre-defined configurations of security controls, extension allowlists and guest configuration, maintained by Microsoft.
const ( AgentConfigurationModeFull AgentConfigurationMode = "full" AgentConfigurationModeMonitor AgentConfigurationMode = "monitor" )
func PossibleAgentConfigurationModeValues ¶
func PossibleAgentConfigurationModeValues() []AgentConfigurationMode
PossibleAgentConfigurationModeValues returns the possible values for the AgentConfigurationMode const type.
type AgentUpgrade ¶
type AgentUpgrade struct { // The correlation ID passed in from RSM per upgrade. CorrelationID *string // Specifies the version info w.r.t AgentUpgrade for the machine. DesiredVersion *string // Specifies if RSM should try to upgrade this machine EnableAutomaticUpgrade *bool // READ-ONLY; Specifies the version of the last attempt LastAttemptDesiredVersion *string // READ-ONLY; Failure message of last upgrade attempt if any. LastAttemptMessage *string // READ-ONLY; Specifies the status of Agent Upgrade. LastAttemptStatus *LastAttemptStatusEnum // READ-ONLY; Timestamp of last upgrade attempt LastAttemptTimestamp *time.Time }
AgentUpgrade - The info w.r.t Agent Upgrade.
func (AgentUpgrade) MarshalJSON ¶
func (a AgentUpgrade) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type AgentUpgrade.
func (*AgentUpgrade) UnmarshalJSON ¶
func (a *AgentUpgrade) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type AgentUpgrade.
type ArcKindEnum ¶
type ArcKindEnum string
ArcKindEnum - Indicates which kind of Arc machine placement on-premises, such as HCI, SCVMM or VMware etc.
const ( ArcKindEnumAVS ArcKindEnum = "AVS" ArcKindEnumAWS ArcKindEnum = "AWS" ArcKindEnumEPS ArcKindEnum = "EPS" ArcKindEnumGCP ArcKindEnum = "GCP" ArcKindEnumHCI ArcKindEnum = "HCI" ArcKindEnumSCVMM ArcKindEnum = "SCVMM" ArcKindEnumVMware ArcKindEnum = "VMware" )
func PossibleArcKindEnumValues ¶
func PossibleArcKindEnumValues() []ArcKindEnum
PossibleArcKindEnumValues returns the possible values for the ArcKindEnum const type.
type AssessmentModeTypes ¶
type AssessmentModeTypes string
AssessmentModeTypes - Specifies the assessment mode.
const ( AssessmentModeTypesAutomaticByPlatform AssessmentModeTypes = "AutomaticByPlatform" AssessmentModeTypesImageDefault AssessmentModeTypes = "ImageDefault" )
func PossibleAssessmentModeTypesValues ¶
func PossibleAssessmentModeTypesValues() []AssessmentModeTypes
PossibleAssessmentModeTypesValues returns the possible values for the AssessmentModeTypes const type.
type AvailablePatchCountByClassification ¶
type AvailablePatchCountByClassification struct { // READ-ONLY; Number of critical patches available for installation. Critical *int32 // READ-ONLY; Number of definition patches available for installation. Definition *int32 // READ-ONLY; Number of feature pack patches available for installation. FeaturePack *int32 // READ-ONLY; Number of other patches available for installation. Other *int32 // READ-ONLY; Number of security patches available for installation. Security *int32 // READ-ONLY; Number of service pack patches available for installation. ServicePack *int32 // READ-ONLY; Number of tools patches available for installation. Tools *int32 // READ-ONLY; Number of update Rollup patches available for installation. UpdateRollup *int32 // READ-ONLY; Number of updates category patches available for installation. Updates *int32 }
AvailablePatchCountByClassification - Summarization of patches available for installation on the machine by classification.
func (AvailablePatchCountByClassification) MarshalJSON ¶
func (a AvailablePatchCountByClassification) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type AvailablePatchCountByClassification.
func (*AvailablePatchCountByClassification) UnmarshalJSON ¶
func (a *AvailablePatchCountByClassification) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type AvailablePatchCountByClassification.
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 - The ID of the target subscription.
- credential - used to authorize requests. Usually a credential from azidentity.
- options - pass nil to accept the default values.
func (*ClientFactory) NewExtensionMetadataClient ¶
func (c *ClientFactory) NewExtensionMetadataClient() *ExtensionMetadataClient
NewExtensionMetadataClient creates a new instance of ExtensionMetadataClient.
func (*ClientFactory) NewLicenseProfilesClient ¶
func (c *ClientFactory) NewLicenseProfilesClient() *LicenseProfilesClient
NewLicenseProfilesClient creates a new instance of LicenseProfilesClient.
func (*ClientFactory) NewLicensesClient ¶
func (c *ClientFactory) NewLicensesClient() *LicensesClient
NewLicensesClient creates a new instance of LicensesClient.
func (*ClientFactory) NewMachineExtensionsClient ¶
func (c *ClientFactory) NewMachineExtensionsClient() *MachineExtensionsClient
NewMachineExtensionsClient creates a new instance of MachineExtensionsClient.
func (*ClientFactory) NewMachinesClient ¶
func (c *ClientFactory) NewMachinesClient() *MachinesClient
NewMachinesClient creates a new instance of MachinesClient.
func (*ClientFactory) NewManagementClient ¶
func (c *ClientFactory) NewManagementClient() *ManagementClient
NewManagementClient creates a new instance of ManagementClient.
func (*ClientFactory) NewNetworkProfileClient ¶
func (c *ClientFactory) NewNetworkProfileClient() *NetworkProfileClient
NewNetworkProfileClient creates a new instance of NetworkProfileClient.
func (*ClientFactory) NewNetworkSecurityPerimeterConfigurationsClient ¶
func (c *ClientFactory) NewNetworkSecurityPerimeterConfigurationsClient() *NetworkSecurityPerimeterConfigurationsClient
NewNetworkSecurityPerimeterConfigurationsClient creates a new instance of NetworkSecurityPerimeterConfigurationsClient.
func (*ClientFactory) NewOperationsClient ¶
func (c *ClientFactory) NewOperationsClient() *OperationsClient
NewOperationsClient creates a new instance of OperationsClient.
func (*ClientFactory) NewPrivateEndpointConnectionsClient ¶
func (c *ClientFactory) NewPrivateEndpointConnectionsClient() *PrivateEndpointConnectionsClient
NewPrivateEndpointConnectionsClient creates a new instance of PrivateEndpointConnectionsClient.
func (*ClientFactory) NewPrivateLinkResourcesClient ¶
func (c *ClientFactory) NewPrivateLinkResourcesClient() *PrivateLinkResourcesClient
NewPrivateLinkResourcesClient creates a new instance of PrivateLinkResourcesClient.
func (*ClientFactory) NewPrivateLinkScopesClient ¶
func (c *ClientFactory) NewPrivateLinkScopesClient() *PrivateLinkScopesClient
NewPrivateLinkScopesClient creates a new instance of PrivateLinkScopesClient.
type CloudMetadata ¶
type CloudMetadata struct { // READ-ONLY; Specifies the cloud provider (Azure/AWS/GCP…). Provider *string }
CloudMetadata - The metadata of the cloud environment (Azure/GCP/AWS/OCI…).
func (CloudMetadata) MarshalJSON ¶
func (c CloudMetadata) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type CloudMetadata.
func (*CloudMetadata) UnmarshalJSON ¶
func (c *CloudMetadata) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type CloudMetadata.
type ConfigurationExtension ¶
type ConfigurationExtension struct { // READ-ONLY; Publisher of the extension. Publisher *string // READ-ONLY; Type of the extension. Type *string }
ConfigurationExtension - Describes properties that can identify extensions.
func (ConfigurationExtension) MarshalJSON ¶
func (c ConfigurationExtension) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ConfigurationExtension.
func (*ConfigurationExtension) UnmarshalJSON ¶
func (c *ConfigurationExtension) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ConfigurationExtension.
type ConnectionDetail ¶
type ConnectionDetail struct { // READ-ONLY; The private endpoint connection group id GroupID *string // READ-ONLY; Azure resource Id ID *string // READ-ONLY; The private endpoint connection link identifier LinkIdentifier *string // READ-ONLY; The private endpoint connection member name MemberName *string // READ-ONLY; The private endpoint connection private ip address PrivateIPAddress *string }
func (ConnectionDetail) MarshalJSON ¶
func (c ConnectionDetail) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ConnectionDetail.
func (*ConnectionDetail) UnmarshalJSON ¶
func (c *ConnectionDetail) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ConnectionDetail.
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 ErrorAdditionalInfo ¶
type ErrorAdditionalInfo struct { // READ-ONLY; The additional info. Info any // READ-ONLY; The additional info type. Type *string }
ErrorAdditionalInfo - The resource management error additional info.
func (ErrorAdditionalInfo) MarshalJSON ¶
func (e ErrorAdditionalInfo) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ErrorAdditionalInfo.
func (*ErrorAdditionalInfo) UnmarshalJSON ¶
func (e *ErrorAdditionalInfo) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ErrorAdditionalInfo.
type ErrorDetail ¶
type ErrorDetail struct { // READ-ONLY; The error additional info. AdditionalInfo []*ErrorAdditionalInfo // READ-ONLY; The error code. Code *string // READ-ONLY; The error details. Details []*ErrorDetail // READ-ONLY; The error message. Message *string // READ-ONLY; The error target. Target *string }
ErrorDetail - The error detail.
func (ErrorDetail) MarshalJSON ¶
func (e ErrorDetail) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ErrorDetail.
func (*ErrorDetail) UnmarshalJSON ¶
func (e *ErrorDetail) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ErrorDetail.
type EsuEligibility ¶
type EsuEligibility string
EsuEligibility - The ESU eligibility.
const ( EsuEligibilityEligible EsuEligibility = "Eligible" EsuEligibilityIneligible EsuEligibility = "Ineligible" EsuEligibilityUnknown EsuEligibility = "Unknown" )
func PossibleEsuEligibilityValues ¶
func PossibleEsuEligibilityValues() []EsuEligibility
PossibleEsuEligibilityValues returns the possible values for the EsuEligibility const type.
type EsuKey ¶
type EsuKey struct { // The current status of the license profile key. Represented by the same integer value that is presented on the machine itself // when querying the license key status. LicenseStatus *int32 // SKU number. SKU *string }
EsuKey - ESU key
func (EsuKey) MarshalJSON ¶
MarshalJSON implements the json.Marshaller interface for type EsuKey.
func (*EsuKey) UnmarshalJSON ¶
UnmarshalJSON implements the json.Unmarshaller interface for type EsuKey.
type EsuKeyState ¶
type EsuKeyState string
EsuKeyState - The ESU key state.
const ( EsuKeyStateActive EsuKeyState = "Active" EsuKeyStateInactive EsuKeyState = "Inactive" )
func PossibleEsuKeyStateValues ¶
func PossibleEsuKeyStateValues() []EsuKeyState
PossibleEsuKeyStateValues returns the possible values for the EsuKeyState const type.
type EsuProfileUpdateProperties ¶
type EsuProfileUpdateProperties struct { // The resource id of the license. AssignedLicense *string }
EsuProfileUpdateProperties - Describes the Update properties of a ESU License Profile.
func (EsuProfileUpdateProperties) MarshalJSON ¶
func (e EsuProfileUpdateProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type EsuProfileUpdateProperties.
func (*EsuProfileUpdateProperties) UnmarshalJSON ¶
func (e *EsuProfileUpdateProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type EsuProfileUpdateProperties.
type EsuServerType ¶
type EsuServerType string
EsuServerType - The server types for Esu.
const ( EsuServerTypeDatacenter EsuServerType = "Datacenter" EsuServerTypeStandard EsuServerType = "Standard" )
func PossibleEsuServerTypeValues ¶
func PossibleEsuServerTypeValues() []EsuServerType
PossibleEsuServerTypeValues returns the possible values for the EsuServerType const type.
type ExtensionMetadataClient ¶
type ExtensionMetadataClient struct {
// contains filtered or unexported fields
}
ExtensionMetadataClient contains the methods for the ExtensionMetadata group. Don't use this type directly, use NewExtensionMetadataClient() instead.
func NewExtensionMetadataClient ¶
func NewExtensionMetadataClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*ExtensionMetadataClient, error)
NewExtensionMetadataClient creates a new instance of ExtensionMetadataClient with the specified values.
- subscriptionID - The ID of the target subscription.
- credential - used to authorize requests. Usually a credential from azidentity.
- options - pass nil to accept the default values.
func (*ExtensionMetadataClient) Get ¶
func (client *ExtensionMetadataClient) Get(ctx context.Context, location string, publisher string, extensionType string, version string, options *ExtensionMetadataClientGetOptions) (ExtensionMetadataClientGetResponse, error)
Get - Gets an Extension Metadata based on location, publisher, extensionType and version If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-07-10
- location - The location of the Extension being received.
- publisher - The publisher of the Extension being received.
- extensionType - The extensionType of the Extension being received.
- version - The version of the Extension being received.
- options - ExtensionMetadataClientGetOptions contains the optional parameters for the ExtensionMetadataClient.Get method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/extension/ExtensionMetadata_Get.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := clientFactory.NewExtensionMetadataClient().Get(ctx, "EastUS", "microsoft.azure.monitor", "azuremonitorlinuxagent", "1.9.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.ExtensionValue = armhybridcompute.ExtensionValue{ // ID: to.Ptr("/subscriptions/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/Providers/Microsoft.HybridCompute/locations/eastus/publishers/microsoft.azure.monitor/extensionTypes/azuremonitorlinuxagent/versions/1.9.1"), // Properties: &armhybridcompute.ExtensionValueProperties{ // ExtensionType: to.Ptr("azuremonitorlinuxagent"), // Publisher: to.Ptr("microsoft.azure.monitor"), // Version: to.Ptr("1.9.1"), // }, // }
Output:
func (*ExtensionMetadataClient) NewListPager ¶
func (client *ExtensionMetadataClient) NewListPager(location string, publisher string, extensionType string, options *ExtensionMetadataClientListOptions) *runtime.Pager[ExtensionMetadataClientListResponse]
NewListPager - Gets all Extension versions based on location, publisher, extensionType
Generated from API version 2024-07-10
- location - The location of the Extension being received.
- publisher - The publisher of the Extension being received.
- extensionType - The extensionType of the Extension being received.
- options - ExtensionMetadataClientListOptions contains the optional parameters for the ExtensionMetadataClient.NewListPager method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/extension/ExtensionMetadata_List.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } pager := clientFactory.NewExtensionMetadataClient().NewListPager("EastUS", "microsoft.azure.monitor", "azuremonitorlinuxagent", 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.ExtensionValueListResult = armhybridcompute.ExtensionValueListResult{ // Value: []*armhybridcompute.ExtensionValue{ // { // ID: to.Ptr("/subscriptions/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/Providers/Microsoft.HybridCompute/locations/eastus/publishers/microsoft.azure.monitor/extensionTypes/azuremonitorlinuxagent/versions/1.9.1"), // Properties: &armhybridcompute.ExtensionValueProperties{ // ExtensionType: to.Ptr("azuremonitorlinuxagent"), // Publisher: to.Ptr("microsoft.azure.monitor"), // Version: to.Ptr("1.9.1"), // }, // }, // { // ID: to.Ptr("/subscriptions/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/Providers/Microsoft.HybridCompute/locations/eastus/publishers/microsoft.azure.monitor/extensionTypes/azuremonitorlinuxagent/versions/1.9.2"), // Properties: &armhybridcompute.ExtensionValueProperties{ // ExtensionType: to.Ptr("azuremonitorlinuxagent"), // Publisher: to.Ptr("microsoft.azure.monitor"), // Version: to.Ptr("1.9.2"), // }, // }}, // } }
Output:
type ExtensionMetadataClientGetOptions ¶
type ExtensionMetadataClientGetOptions struct { }
ExtensionMetadataClientGetOptions contains the optional parameters for the ExtensionMetadataClient.Get method.
type ExtensionMetadataClientGetResponse ¶
type ExtensionMetadataClientGetResponse struct { // Describes a Extension Metadata ExtensionValue }
ExtensionMetadataClientGetResponse contains the response from method ExtensionMetadataClient.Get.
type ExtensionMetadataClientListOptions ¶
type ExtensionMetadataClientListOptions struct { }
ExtensionMetadataClientListOptions contains the optional parameters for the ExtensionMetadataClient.NewListPager method.
type ExtensionMetadataClientListResponse ¶
type ExtensionMetadataClientListResponse struct { // The List Extension Metadata response. ExtensionValueListResult }
ExtensionMetadataClientListResponse contains the response from method ExtensionMetadataClient.NewListPager.
type ExtensionTargetProperties ¶
type ExtensionTargetProperties struct { // Properties for the specified Extension to Upgrade. TargetVersion *string }
ExtensionTargetProperties - Describes the Machine Extension Target Version Properties
func (ExtensionTargetProperties) MarshalJSON ¶
func (e ExtensionTargetProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ExtensionTargetProperties.
func (*ExtensionTargetProperties) UnmarshalJSON ¶
func (e *ExtensionTargetProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ExtensionTargetProperties.
type ExtensionValue ¶
type ExtensionValue struct { // The single extension based on search criteria Properties *ExtensionValueProperties // READ-ONLY; Fully qualified resource ID for the resource. E.g. "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}" ID *string // READ-ONLY; The name of the resource Name *string // READ-ONLY; Azure Resource Manager metadata containing createdBy and modifiedBy information. SystemData *SystemData // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string }
ExtensionValue - Describes a Extension Metadata
func (ExtensionValue) MarshalJSON ¶
func (e ExtensionValue) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ExtensionValue.
func (*ExtensionValue) UnmarshalJSON ¶
func (e *ExtensionValue) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ExtensionValue.
type ExtensionValueListResult ¶
type ExtensionValueListResult struct { // READ-ONLY; The list of extension metadata Value []*ExtensionValue }
ExtensionValueListResult - The List Extension Metadata response.
func (ExtensionValueListResult) MarshalJSON ¶
func (e ExtensionValueListResult) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ExtensionValueListResult.
func (*ExtensionValueListResult) UnmarshalJSON ¶
func (e *ExtensionValueListResult) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ExtensionValueListResult.
type ExtensionValueProperties ¶
type ExtensionValueProperties struct { // READ-ONLY; The type of the Extension being received. ExtensionType *string // READ-ONLY; The publisher of the Extension being received. Publisher *string // READ-ONLY; The version of the Extension being received. Version *string }
ExtensionValueProperties - Describes Extension Metadata properties
func (ExtensionValueProperties) MarshalJSON ¶
func (e ExtensionValueProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ExtensionValueProperties.
func (*ExtensionValueProperties) UnmarshalJSON ¶
func (e *ExtensionValueProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ExtensionValueProperties.
type HotpatchEnablementStatus ¶
type HotpatchEnablementStatus string
HotpatchEnablementStatus - Status of hotpatch enablement or disablement.
const ( HotpatchEnablementStatusActionRequired HotpatchEnablementStatus = "ActionRequired" HotpatchEnablementStatusDisabled HotpatchEnablementStatus = "Disabled" HotpatchEnablementStatusEnabled HotpatchEnablementStatus = "Enabled" HotpatchEnablementStatusPendingEvaluation HotpatchEnablementStatus = "PendingEvaluation" HotpatchEnablementStatusUnknown HotpatchEnablementStatus = "Unknown" )
func PossibleHotpatchEnablementStatusValues ¶
func PossibleHotpatchEnablementStatusValues() []HotpatchEnablementStatus
PossibleHotpatchEnablementStatusValues returns the possible values for the HotpatchEnablementStatus const type.
type IPAddress ¶
type IPAddress struct { // Represents the IP Address. Address *string // Represents the Ip Address Version. IPAddressVersion *string // READ-ONLY; The subnet to which this IP address belongs. Subnet *Subnet }
IPAddress - Describes properties of the IP address.
func (IPAddress) MarshalJSON ¶
MarshalJSON implements the json.Marshaller interface for type IPAddress.
func (*IPAddress) UnmarshalJSON ¶
UnmarshalJSON implements the json.Unmarshaller interface for type IPAddress.
type Identity ¶
type Identity struct { // The identity type. Type *string // READ-ONLY; The principal ID of resource identity. PrincipalID *string // READ-ONLY; The tenant ID of resource. TenantID *string }
Identity for the resource.
func (Identity) MarshalJSON ¶
MarshalJSON implements the json.Marshaller interface for type Identity.
func (*Identity) UnmarshalJSON ¶
UnmarshalJSON implements the json.Unmarshaller interface for type Identity.
type InstanceViewTypes ¶
type InstanceViewTypes string
const (
InstanceViewTypesInstanceView InstanceViewTypes = "instanceView"
)
func PossibleInstanceViewTypesValues ¶
func PossibleInstanceViewTypesValues() []InstanceViewTypes
PossibleInstanceViewTypesValues returns the possible values for the InstanceViewTypes const type.
type LastAttemptStatusEnum ¶
type LastAttemptStatusEnum string
LastAttemptStatusEnum - Specifies the status of Agent Upgrade.
const ( LastAttemptStatusEnumFailed LastAttemptStatusEnum = "Failed" LastAttemptStatusEnumSuccess LastAttemptStatusEnum = "Success" )
func PossibleLastAttemptStatusEnumValues ¶
func PossibleLastAttemptStatusEnumValues() []LastAttemptStatusEnum
PossibleLastAttemptStatusEnumValues returns the possible values for the LastAttemptStatusEnum const type.
type License ¶
type License struct { // REQUIRED; The geo-location where the resource lives Location *string // Hybrid Compute License properties Properties *LicenseProperties // Resource tags. Tags map[string]*string // READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string // READ-ONLY; The name of the resource Name *string // READ-ONLY; Azure Resource Manager metadata containing createdBy and modifiedBy information. SystemData *SystemData // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string }
License - Describes a license in a hybrid machine.
func (License) MarshalJSON ¶
MarshalJSON implements the json.Marshaller interface for type License.
func (*License) UnmarshalJSON ¶
UnmarshalJSON implements the json.Unmarshaller interface for type License.
type LicenseAssignmentState ¶
type LicenseAssignmentState string
LicenseAssignmentState - Describes the license assignment state (Assigned or NotAssigned).
const ( LicenseAssignmentStateAssigned LicenseAssignmentState = "Assigned" LicenseAssignmentStateNotAssigned LicenseAssignmentState = "NotAssigned" )
func PossibleLicenseAssignmentStateValues ¶
func PossibleLicenseAssignmentStateValues() []LicenseAssignmentState
PossibleLicenseAssignmentStateValues returns the possible values for the LicenseAssignmentState const type.
type LicenseCoreType ¶
type LicenseCoreType string
LicenseCoreType - Describes the license core type (pCore or vCore).
const ( LicenseCoreTypePCore LicenseCoreType = "pCore" LicenseCoreTypeVCore LicenseCoreType = "vCore" )
func PossibleLicenseCoreTypeValues ¶
func PossibleLicenseCoreTypeValues() []LicenseCoreType
PossibleLicenseCoreTypeValues returns the possible values for the LicenseCoreType const type.
type LicenseDetails ¶
type LicenseDetails struct { // Describes the edition of the license. The values are either Standard or Datacenter. Edition *LicenseEdition // Describes the number of processors. Processors *int32 // Describes the state of the license. State *LicenseState // Describes the license target server. Target *LicenseTarget // Describes the license core type (pCore or vCore). Type *LicenseCoreType // A list of volume license details. VolumeLicenseDetails []*VolumeLicenseDetails // READ-ONLY; Describes the number of assigned licenses. AssignedLicenses *int32 // READ-ONLY; Describes the immutable id. ImmutableID *string }
LicenseDetails - Describes the properties of a License.
func (LicenseDetails) MarshalJSON ¶
func (l LicenseDetails) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type LicenseDetails.
func (*LicenseDetails) UnmarshalJSON ¶
func (l *LicenseDetails) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type LicenseDetails.
type LicenseEdition ¶
type LicenseEdition string
LicenseEdition - Describes the edition of the license. The values are either Standard or Datacenter.
const ( LicenseEditionDatacenter LicenseEdition = "Datacenter" LicenseEditionStandard LicenseEdition = "Standard" )
func PossibleLicenseEditionValues ¶
func PossibleLicenseEditionValues() []LicenseEdition
PossibleLicenseEditionValues returns the possible values for the LicenseEdition const type.
type LicenseProfile ¶
type LicenseProfile struct { // REQUIRED; The geo-location where the resource lives Location *string // Describe the properties of a license profile. Properties *LicenseProfileProperties // Resource tags. Tags map[string]*string // READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string // READ-ONLY; The name of the resource Name *string // READ-ONLY; Azure Resource Manager metadata containing createdBy and modifiedBy information. SystemData *SystemData // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string }
LicenseProfile - Describes a license profile in a hybrid machine.
func (LicenseProfile) MarshalJSON ¶
func (l LicenseProfile) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type LicenseProfile.
func (*LicenseProfile) UnmarshalJSON ¶
func (l *LicenseProfile) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type LicenseProfile.
type LicenseProfileArmEsuProperties ¶
type LicenseProfileArmEsuProperties struct { // The resource id of the license. AssignedLicense *string // READ-ONLY; The guid id of the license. AssignedLicenseImmutableID *string // READ-ONLY; Indicates the eligibility state of Esu. EsuEligibility *EsuEligibility // READ-ONLY; Indicates whether there is an ESU Key currently active for the machine. EsuKeyState *EsuKeyState // READ-ONLY; The list of ESU keys. EsuKeys []*EsuKey // READ-ONLY; The type of the Esu servers. ServerType *EsuServerType }
LicenseProfileArmEsuProperties - Describes the properties of a License Profile ARM model.
func (LicenseProfileArmEsuProperties) MarshalJSON ¶
func (l LicenseProfileArmEsuProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type LicenseProfileArmEsuProperties.
func (*LicenseProfileArmEsuProperties) UnmarshalJSON ¶
func (l *LicenseProfileArmEsuProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type LicenseProfileArmEsuProperties.
type LicenseProfileArmProductProfileProperties ¶
type LicenseProfileArmProductProfileProperties struct { // The list of product features. ProductFeatures []*ProductFeature // Indicates the product type of the license. ProductType *LicenseProfileProductType // Indicates the subscription status of the product. SubscriptionStatus *LicenseProfileSubscriptionStatus // READ-ONLY; The timestamp in UTC when the billing ends. BillingEndDate *time.Time // READ-ONLY; The timestamp in UTC when the billing starts. BillingStartDate *time.Time // READ-ONLY; The timestamp in UTC when the user disenrolled the feature. DisenrollmentDate *time.Time // READ-ONLY; The timestamp in UTC when the user enrolls the feature. EnrollmentDate *time.Time // READ-ONLY; The errors that were encountered during the feature enrollment or disenrollment. Error *ErrorDetail }
LicenseProfileArmProductProfileProperties - Describes the properties of a Product License Profile ARM model.
func (LicenseProfileArmProductProfileProperties) MarshalJSON ¶
func (l LicenseProfileArmProductProfileProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type LicenseProfileArmProductProfileProperties.
func (*LicenseProfileArmProductProfileProperties) UnmarshalJSON ¶
func (l *LicenseProfileArmProductProfileProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type LicenseProfileArmProductProfileProperties.
type LicenseProfileMachineInstanceView ¶
type LicenseProfileMachineInstanceView struct { // Properties for the Machine ESU profile. EsuProfile *LicenseProfileMachineInstanceViewEsuProperties // READ-ONLY; Indicates the license channel. LicenseChannel *string // READ-ONLY; Indicates the license status of the OS. LicenseStatus *LicenseStatus // READ-ONLY; Hybrid Compute Product Profile properties ProductProfile *LicenseProfileArmProductProfileProperties // READ-ONLY SoftwareAssurance *LicenseProfileMachineInstanceViewSoftwareAssurance }
LicenseProfileMachineInstanceView - License Profile Instance View in Machine Properties.
func (LicenseProfileMachineInstanceView) MarshalJSON ¶
func (l LicenseProfileMachineInstanceView) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type LicenseProfileMachineInstanceView.
func (*LicenseProfileMachineInstanceView) UnmarshalJSON ¶
func (l *LicenseProfileMachineInstanceView) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type LicenseProfileMachineInstanceView.
type LicenseProfileMachineInstanceViewEsuProperties ¶
type LicenseProfileMachineInstanceViewEsuProperties struct { // The assigned license resource. AssignedLicense *License // Describes the license assignment state (Assigned or NotAssigned). LicenseAssignmentState *LicenseAssignmentState // READ-ONLY; The guid id of the license. AssignedLicenseImmutableID *string // READ-ONLY; Indicates the eligibility state of Esu. EsuEligibility *EsuEligibility // READ-ONLY; Indicates whether there is an ESU Key currently active for the machine. EsuKeyState *EsuKeyState // READ-ONLY; The list of ESU keys. EsuKeys []*EsuKey // READ-ONLY; The type of the Esu servers. ServerType *EsuServerType }
LicenseProfileMachineInstanceViewEsuProperties - Properties for the Machine ESU profile.
func (LicenseProfileMachineInstanceViewEsuProperties) MarshalJSON ¶
func (l LicenseProfileMachineInstanceViewEsuProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type LicenseProfileMachineInstanceViewEsuProperties.
func (*LicenseProfileMachineInstanceViewEsuProperties) UnmarshalJSON ¶
func (l *LicenseProfileMachineInstanceViewEsuProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type LicenseProfileMachineInstanceViewEsuProperties.
type LicenseProfileMachineInstanceViewSoftwareAssurance ¶
type LicenseProfileMachineInstanceViewSoftwareAssurance struct { // Specifies if this machine is licensed as part of a Software Assurance agreement. SoftwareAssuranceCustomer *bool }
func (LicenseProfileMachineInstanceViewSoftwareAssurance) MarshalJSON ¶
func (l LicenseProfileMachineInstanceViewSoftwareAssurance) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type LicenseProfileMachineInstanceViewSoftwareAssurance.
func (*LicenseProfileMachineInstanceViewSoftwareAssurance) UnmarshalJSON ¶
func (l *LicenseProfileMachineInstanceViewSoftwareAssurance) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type LicenseProfileMachineInstanceViewSoftwareAssurance.
type LicenseProfileProductType ¶
type LicenseProfileProductType string
LicenseProfileProductType - The product type of the license.
const ( LicenseProfileProductTypeWindowsIoTEnterprise LicenseProfileProductType = "WindowsIoTEnterprise" LicenseProfileProductTypeWindowsServer LicenseProfileProductType = "WindowsServer" )
func PossibleLicenseProfileProductTypeValues ¶
func PossibleLicenseProfileProductTypeValues() []LicenseProfileProductType
PossibleLicenseProfileProductTypeValues returns the possible values for the LicenseProfileProductType const type.
type LicenseProfileProperties ¶
type LicenseProfileProperties struct { // Hybrid Compute ESU Profile properties EsuProfile *LicenseProfileArmEsuProperties // Hybrid Compute Product Profile properties ProductProfile *LicenseProfileArmProductProfileProperties SoftwareAssurance *LicenseProfilePropertiesSoftwareAssurance // READ-ONLY; The provisioning state, which only appears in the response. ProvisioningState *ProvisioningState }
LicenseProfileProperties - Describe the properties of a license profile.
func (LicenseProfileProperties) MarshalJSON ¶
func (l LicenseProfileProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type LicenseProfileProperties.
func (*LicenseProfileProperties) UnmarshalJSON ¶
func (l *LicenseProfileProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type LicenseProfileProperties.
type LicenseProfilePropertiesSoftwareAssurance ¶
type LicenseProfilePropertiesSoftwareAssurance struct { // Specifies if this machine is licensed as part of a Software Assurance agreement. SoftwareAssuranceCustomer *bool }
func (LicenseProfilePropertiesSoftwareAssurance) MarshalJSON ¶
func (l LicenseProfilePropertiesSoftwareAssurance) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type LicenseProfilePropertiesSoftwareAssurance.
func (*LicenseProfilePropertiesSoftwareAssurance) UnmarshalJSON ¶
func (l *LicenseProfilePropertiesSoftwareAssurance) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type LicenseProfilePropertiesSoftwareAssurance.
type LicenseProfileSubscriptionStatus ¶
type LicenseProfileSubscriptionStatus string
LicenseProfileSubscriptionStatus - Subscription status of the OS or Product feature.
const ( LicenseProfileSubscriptionStatusDisabled LicenseProfileSubscriptionStatus = "Disabled" LicenseProfileSubscriptionStatusDisabling LicenseProfileSubscriptionStatus = "Disabling" LicenseProfileSubscriptionStatusEnabled LicenseProfileSubscriptionStatus = "Enabled" LicenseProfileSubscriptionStatusEnabling LicenseProfileSubscriptionStatus = "Enabling" LicenseProfileSubscriptionStatusFailed LicenseProfileSubscriptionStatus = "Failed" LicenseProfileSubscriptionStatusUnknown LicenseProfileSubscriptionStatus = "Unknown" )
func PossibleLicenseProfileSubscriptionStatusValues ¶
func PossibleLicenseProfileSubscriptionStatusValues() []LicenseProfileSubscriptionStatus
PossibleLicenseProfileSubscriptionStatusValues returns the possible values for the LicenseProfileSubscriptionStatus const type.
type LicenseProfileSubscriptionStatusUpdate ¶
type LicenseProfileSubscriptionStatusUpdate string
LicenseProfileSubscriptionStatusUpdate - Indicates the new subscription status of the OS or Product Features.
const ( LicenseProfileSubscriptionStatusUpdateDisable LicenseProfileSubscriptionStatusUpdate = "Disable" LicenseProfileSubscriptionStatusUpdateEnable LicenseProfileSubscriptionStatusUpdate = "Enable" )
func PossibleLicenseProfileSubscriptionStatusUpdateValues ¶
func PossibleLicenseProfileSubscriptionStatusUpdateValues() []LicenseProfileSubscriptionStatusUpdate
PossibleLicenseProfileSubscriptionStatusUpdateValues returns the possible values for the LicenseProfileSubscriptionStatusUpdate const type.
type LicenseProfileUpdate ¶
type LicenseProfileUpdate struct { // Describe the Update properties of a license profile. Properties *LicenseProfileUpdateProperties // Resource tags Tags map[string]*string }
LicenseProfileUpdate - Describes a License Profile Update.
func (LicenseProfileUpdate) MarshalJSON ¶
func (l LicenseProfileUpdate) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type LicenseProfileUpdate.
func (*LicenseProfileUpdate) UnmarshalJSON ¶
func (l *LicenseProfileUpdate) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type LicenseProfileUpdate.
type LicenseProfileUpdateProperties ¶
type LicenseProfileUpdateProperties struct { // Hybrid Compute ESU Profile Update properties EsuProfile *EsuProfileUpdateProperties // Hybrid Compute Product Profile Update properties ProductProfile *ProductProfileUpdateProperties SoftwareAssurance *LicenseProfileUpdatePropertiesSoftwareAssurance }
LicenseProfileUpdateProperties - Describe the Update properties of a license profile.
func (LicenseProfileUpdateProperties) MarshalJSON ¶
func (l LicenseProfileUpdateProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type LicenseProfileUpdateProperties.
func (*LicenseProfileUpdateProperties) UnmarshalJSON ¶
func (l *LicenseProfileUpdateProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type LicenseProfileUpdateProperties.
type LicenseProfileUpdatePropertiesSoftwareAssurance ¶
type LicenseProfileUpdatePropertiesSoftwareAssurance struct { // Specifies if this machine is licensed as part of a Software Assurance agreement. SoftwareAssuranceCustomer *bool }
func (LicenseProfileUpdatePropertiesSoftwareAssurance) MarshalJSON ¶
func (l LicenseProfileUpdatePropertiesSoftwareAssurance) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type LicenseProfileUpdatePropertiesSoftwareAssurance.
func (*LicenseProfileUpdatePropertiesSoftwareAssurance) UnmarshalJSON ¶
func (l *LicenseProfileUpdatePropertiesSoftwareAssurance) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type LicenseProfileUpdatePropertiesSoftwareAssurance.
type LicenseProfilesClient ¶
type LicenseProfilesClient struct {
// contains filtered or unexported fields
}
LicenseProfilesClient contains the methods for the LicenseProfiles group. Don't use this type directly, use NewLicenseProfilesClient() instead.
func NewLicenseProfilesClient ¶
func NewLicenseProfilesClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*LicenseProfilesClient, error)
NewLicenseProfilesClient creates a new instance of LicenseProfilesClient with the specified values.
- subscriptionID - The ID of the target subscription.
- credential - used to authorize requests. Usually a credential from azidentity.
- options - pass nil to accept the default values.
func (*LicenseProfilesClient) BeginCreateOrUpdate ¶
func (client *LicenseProfilesClient) BeginCreateOrUpdate(ctx context.Context, resourceGroupName string, machineName string, parameters LicenseProfile, options *LicenseProfilesClientBeginCreateOrUpdateOptions) (*runtime.Poller[LicenseProfilesClientCreateOrUpdateResponse], error)
BeginCreateOrUpdate - The operation to create or update a license profile. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group. The name is case insensitive.
- machineName - The name of the hybrid machine.
- parameters - Parameters supplied to the Create or Update license profile operation.
- options - LicenseProfilesClientBeginCreateOrUpdateOptions contains the optional parameters for the LicenseProfilesClient.BeginCreateOrUpdate method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/licenseProfile/LicenseProfile_CreateOrUpdate.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewLicenseProfilesClient().BeginCreateOrUpdate(ctx, "myResourceGroup", "myMachine", armhybridcompute.LicenseProfile{ Location: to.Ptr("eastus2euap"), Properties: &armhybridcompute.LicenseProfileProperties{ EsuProfile: &armhybridcompute.LicenseProfileArmEsuProperties{ AssignedLicense: to.Ptr("{LicenseResourceId}"), }, ProductProfile: &armhybridcompute.LicenseProfileArmProductProfileProperties{ ProductFeatures: []*armhybridcompute.ProductFeature{ { Name: to.Ptr("Hotpatch"), SubscriptionStatus: to.Ptr(armhybridcompute.LicenseProfileSubscriptionStatusEnabled), }}, ProductType: to.Ptr(armhybridcompute.LicenseProfileProductTypeWindowsServer), SubscriptionStatus: to.Ptr(armhybridcompute.LicenseProfileSubscriptionStatusEnabled), }, SoftwareAssurance: &armhybridcompute.LicenseProfilePropertiesSoftwareAssurance{ SoftwareAssuranceCustomer: to.Ptr(true), }, }, }, nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) } res, err := poller.PollUntilDone(ctx, nil) if err != nil { log.Fatalf("failed to pull the result: %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.LicenseProfile = armhybridcompute.LicenseProfile{ // Name: to.Ptr("default"), // Type: to.Ptr("Microsoft.HybridCompute/machines/licenseProfiles"), // ID: to.Ptr("/subscriptions/{subscriptionId}/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/Machines/myMachine/licenseProfiles/default"), // Location: to.Ptr("eastus2euap"), // Properties: &armhybridcompute.LicenseProfileProperties{ // EsuProfile: &armhybridcompute.LicenseProfileArmEsuProperties{ // AssignedLicenseImmutableID: to.Ptr("{Guid}"), // EsuKeys: []*armhybridcompute.EsuKey{ // { // LicenseStatus: to.Ptr[int32](1), // SKU: to.Ptr("skuNumber1"), // }, // { // LicenseStatus: to.Ptr[int32](1), // SKU: to.Ptr("skuNumber2"), // }}, // EsuEligibility: to.Ptr(armhybridcompute.EsuEligibilityEligible), // EsuKeyState: to.Ptr(armhybridcompute.EsuKeyStateInactive), // ServerType: to.Ptr(armhybridcompute.EsuServerTypeStandard), // AssignedLicense: to.Ptr("{LicenseResourceId}"), // }, // ProductProfile: &armhybridcompute.LicenseProfileArmProductProfileProperties{ // BillingEndDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // BillingStartDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // DisenrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // EnrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // ProductFeatures: []*armhybridcompute.ProductFeature{ // { // Name: to.Ptr("Hotpatch"), // BillingEndDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // BillingStartDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // DisenrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // EnrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // SubscriptionStatus: to.Ptr(armhybridcompute.LicenseProfileSubscriptionStatusEnabling), // }}, // ProductType: to.Ptr(armhybridcompute.LicenseProfileProductTypeWindowsServer), // SubscriptionStatus: to.Ptr(armhybridcompute.LicenseProfileSubscriptionStatusEnabling), // }, // SoftwareAssurance: &armhybridcompute.LicenseProfilePropertiesSoftwareAssurance{ // SoftwareAssuranceCustomer: to.Ptr(true), // }, // }, // }
Output:
func (*LicenseProfilesClient) BeginDelete ¶
func (client *LicenseProfilesClient) BeginDelete(ctx context.Context, resourceGroupName string, machineName string, options *LicenseProfilesClientBeginDeleteOptions) (*runtime.Poller[LicenseProfilesClientDeleteResponse], error)
BeginDelete - The operation to delete a license profile. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group. The name is case insensitive.
- machineName - The name of the hybrid machine.
- options - LicenseProfilesClientBeginDeleteOptions contains the optional parameters for the LicenseProfilesClient.BeginDelete method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/licenseProfile/LicenseProfile_Delete.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewLicenseProfilesClient().BeginDelete(ctx, "myResourceGroup", "myMachine", nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) } _, err = poller.PollUntilDone(ctx, nil) if err != nil { log.Fatalf("failed to pull the result: %v", err) }
Output:
func (*LicenseProfilesClient) BeginUpdate ¶
func (client *LicenseProfilesClient) BeginUpdate(ctx context.Context, resourceGroupName string, machineName string, parameters LicenseProfileUpdate, options *LicenseProfilesClientBeginUpdateOptions) (*runtime.Poller[LicenseProfilesClientUpdateResponse], error)
BeginUpdate - The operation to update a license profile. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group. The name is case insensitive.
- machineName - The name of the hybrid machine.
- parameters - Parameters supplied to the Update license profile operation.
- options - LicenseProfilesClientBeginUpdateOptions contains the optional parameters for the LicenseProfilesClient.BeginUpdate method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/licenseProfile/LicenseProfile_Update.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewLicenseProfilesClient().BeginUpdate(ctx, "myResourceGroup", "myMachine", armhybridcompute.LicenseProfileUpdate{ Properties: &armhybridcompute.LicenseProfileUpdateProperties{ EsuProfile: &armhybridcompute.EsuProfileUpdateProperties{ AssignedLicense: to.Ptr("{LicenseResourceId}"), }, ProductProfile: &armhybridcompute.ProductProfileUpdateProperties{ ProductFeatures: []*armhybridcompute.ProductFeatureUpdate{ { Name: to.Ptr("Hotpatch"), SubscriptionStatus: to.Ptr(armhybridcompute.LicenseProfileSubscriptionStatusUpdateEnable), }}, ProductType: to.Ptr(armhybridcompute.LicenseProfileProductTypeWindowsServer), SubscriptionStatus: to.Ptr(armhybridcompute.LicenseProfileSubscriptionStatusUpdateEnable), }, SoftwareAssurance: &armhybridcompute.LicenseProfileUpdatePropertiesSoftwareAssurance{ SoftwareAssuranceCustomer: to.Ptr(true), }, }, }, nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) } res, err := poller.PollUntilDone(ctx, nil) if err != nil { log.Fatalf("failed to pull the result: %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.LicenseProfile = armhybridcompute.LicenseProfile{ // Name: to.Ptr("default"), // Type: to.Ptr("Microsoft.HybridCompute/machines/licenseProfiles"), // ID: to.Ptr("/subscriptions/{subscriptionId}/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/Machines/myMachine/licenseProfiles/default"), // Location: to.Ptr("eastus2euap"), // Properties: &armhybridcompute.LicenseProfileProperties{ // EsuProfile: &armhybridcompute.LicenseProfileArmEsuProperties{ // EsuKeys: []*armhybridcompute.EsuKey{ // { // LicenseStatus: to.Ptr[int32](1), // SKU: to.Ptr("skuNumber1"), // }, // { // LicenseStatus: to.Ptr[int32](1), // SKU: to.Ptr("skuNumber2"), // }}, // EsuEligibility: to.Ptr(armhybridcompute.EsuEligibilityEligible), // EsuKeyState: to.Ptr(armhybridcompute.EsuKeyStateInactive), // ServerType: to.Ptr(armhybridcompute.EsuServerTypeStandard), // AssignedLicense: to.Ptr("{LicenseResourceId}"), // }, // ProductProfile: &armhybridcompute.LicenseProfileArmProductProfileProperties{ // BillingEndDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // BillingStartDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // DisenrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // EnrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // ProductFeatures: []*armhybridcompute.ProductFeature{ // { // Name: to.Ptr("Hotpatch"), // BillingEndDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // BillingStartDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // DisenrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // EnrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // SubscriptionStatus: to.Ptr(armhybridcompute.LicenseProfileSubscriptionStatusEnabling), // }}, // ProductType: to.Ptr(armhybridcompute.LicenseProfileProductTypeWindowsServer), // SubscriptionStatus: to.Ptr(armhybridcompute.LicenseProfileSubscriptionStatusEnabling), // }, // SoftwareAssurance: &armhybridcompute.LicenseProfilePropertiesSoftwareAssurance{ // SoftwareAssuranceCustomer: to.Ptr(true), // }, // }, // }
Output:
func (*LicenseProfilesClient) Get ¶
func (client *LicenseProfilesClient) Get(ctx context.Context, resourceGroupName string, machineName string, options *LicenseProfilesClientGetOptions) (LicenseProfilesClientGetResponse, error)
Get - Retrieves information about the view of a license profile. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group. The name is case insensitive.
- machineName - The name of the hybrid machine.
- options - LicenseProfilesClientGetOptions contains the optional parameters for the LicenseProfilesClient.Get method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/licenseProfile/LicenseProfile_Get.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := clientFactory.NewLicenseProfilesClient().Get(ctx, "myResourceGroup", "myMachine", 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.LicenseProfile = armhybridcompute.LicenseProfile{ // Name: to.Ptr("default"), // Type: to.Ptr("Microsoft.HybridCompute/machines/licenseProfiles"), // ID: to.Ptr("/subscriptions/{subscriptionId}/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/Machines/myMachine/licenseProfiles/default"), // Location: to.Ptr("eastus2euap"), // Properties: &armhybridcompute.LicenseProfileProperties{ // EsuProfile: &armhybridcompute.LicenseProfileArmEsuProperties{ // EsuKeys: []*armhybridcompute.EsuKey{ // { // LicenseStatus: to.Ptr[int32](1), // SKU: to.Ptr("skuNumber1"), // }, // { // LicenseStatus: to.Ptr[int32](1), // SKU: to.Ptr("skuNumber2"), // }}, // EsuEligibility: to.Ptr(armhybridcompute.EsuEligibilityEligible), // EsuKeyState: to.Ptr(armhybridcompute.EsuKeyStateInactive), // ServerType: to.Ptr(armhybridcompute.EsuServerTypeStandard), // AssignedLicense: to.Ptr("{LicenseResourceId}"), // }, // ProductProfile: &armhybridcompute.LicenseProfileArmProductProfileProperties{ // BillingEndDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // BillingStartDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // DisenrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // EnrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // ProductFeatures: []*armhybridcompute.ProductFeature{ // { // Name: to.Ptr("Hotpatch"), // BillingEndDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // BillingStartDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // DisenrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // EnrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // SubscriptionStatus: to.Ptr(armhybridcompute.LicenseProfileSubscriptionStatusEnabled), // }}, // ProductType: to.Ptr(armhybridcompute.LicenseProfileProductTypeWindowsServer), // SubscriptionStatus: to.Ptr(armhybridcompute.LicenseProfileSubscriptionStatusEnabled), // }, // SoftwareAssurance: &armhybridcompute.LicenseProfilePropertiesSoftwareAssurance{ // SoftwareAssuranceCustomer: to.Ptr(true), // }, // }, // }
Output:
func (*LicenseProfilesClient) NewListPager ¶
func (client *LicenseProfilesClient) NewListPager(resourceGroupName string, machineName string, options *LicenseProfilesClientListOptions) *runtime.Pager[LicenseProfilesClientListResponse]
NewListPager - The operation to get all license profiles of a non-Azure machine
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group. The name is case insensitive.
- machineName - The name of the machine.
- options - LicenseProfilesClientListOptions contains the optional parameters for the LicenseProfilesClient.NewListPager method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/licenseProfile/LicenseProfile_List.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } pager := clientFactory.NewLicenseProfilesClient().NewListPager("myResourceGroup", "myMachine", 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.LicenseProfilesListResult = armhybridcompute.LicenseProfilesListResult{ // Value: []*armhybridcompute.LicenseProfile{ // { // Name: to.Ptr("default"), // Type: to.Ptr("Microsoft.HybridCompute/machines/licenseProfiles"), // ID: to.Ptr("/subscriptions/{subscriptionId}/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/Machines/myMachine/licenseProfiles/default"), // Location: to.Ptr("eastus2euap"), // Properties: &armhybridcompute.LicenseProfileProperties{ // EsuProfile: &armhybridcompute.LicenseProfileArmEsuProperties{ // EsuKeys: []*armhybridcompute.EsuKey{ // { // LicenseStatus: to.Ptr[int32](1), // SKU: to.Ptr("skuNumber1"), // }, // { // LicenseStatus: to.Ptr[int32](1), // SKU: to.Ptr("skuNumber2"), // }}, // EsuEligibility: to.Ptr(armhybridcompute.EsuEligibilityEligible), // EsuKeyState: to.Ptr(armhybridcompute.EsuKeyStateInactive), // ServerType: to.Ptr(armhybridcompute.EsuServerTypeStandard), // AssignedLicense: to.Ptr("{LicenseResourceId}"), // }, // ProductProfile: &armhybridcompute.LicenseProfileArmProductProfileProperties{ // BillingEndDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // BillingStartDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // DisenrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // EnrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // ProductFeatures: []*armhybridcompute.ProductFeature{ // { // Name: to.Ptr("Hotpatch"), // BillingEndDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // BillingStartDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // DisenrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // EnrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // SubscriptionStatus: to.Ptr(armhybridcompute.LicenseProfileSubscriptionStatusEnabled), // }}, // ProductType: to.Ptr(armhybridcompute.LicenseProfileProductTypeWindowsServer), // SubscriptionStatus: to.Ptr(armhybridcompute.LicenseProfileSubscriptionStatusEnabled), // }, // SoftwareAssurance: &armhybridcompute.LicenseProfilePropertiesSoftwareAssurance{ // SoftwareAssuranceCustomer: to.Ptr(true), // }, // }, // }}, // } }
Output:
type LicenseProfilesClientBeginCreateOrUpdateOptions ¶
type LicenseProfilesClientBeginCreateOrUpdateOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
LicenseProfilesClientBeginCreateOrUpdateOptions contains the optional parameters for the LicenseProfilesClient.BeginCreateOrUpdate method.
type LicenseProfilesClientBeginDeleteOptions ¶
type LicenseProfilesClientBeginDeleteOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
LicenseProfilesClientBeginDeleteOptions contains the optional parameters for the LicenseProfilesClient.BeginDelete method.
type LicenseProfilesClientBeginUpdateOptions ¶
type LicenseProfilesClientBeginUpdateOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
LicenseProfilesClientBeginUpdateOptions contains the optional parameters for the LicenseProfilesClient.BeginUpdate method.
type LicenseProfilesClientCreateOrUpdateResponse ¶
type LicenseProfilesClientCreateOrUpdateResponse struct { // Describes a license profile in a hybrid machine. LicenseProfile }
LicenseProfilesClientCreateOrUpdateResponse contains the response from method LicenseProfilesClient.BeginCreateOrUpdate.
type LicenseProfilesClientDeleteResponse ¶
type LicenseProfilesClientDeleteResponse struct { }
LicenseProfilesClientDeleteResponse contains the response from method LicenseProfilesClient.BeginDelete.
type LicenseProfilesClientGetOptions ¶
type LicenseProfilesClientGetOptions struct { }
LicenseProfilesClientGetOptions contains the optional parameters for the LicenseProfilesClient.Get method.
type LicenseProfilesClientGetResponse ¶
type LicenseProfilesClientGetResponse struct { // Describes a license profile in a hybrid machine. LicenseProfile }
LicenseProfilesClientGetResponse contains the response from method LicenseProfilesClient.Get.
type LicenseProfilesClientListOptions ¶
type LicenseProfilesClientListOptions struct { }
LicenseProfilesClientListOptions contains the optional parameters for the LicenseProfilesClient.NewListPager method.
type LicenseProfilesClientListResponse ¶
type LicenseProfilesClientListResponse struct { // The List hybrid machine license profile operation response. LicenseProfilesListResult }
LicenseProfilesClientListResponse contains the response from method LicenseProfilesClient.NewListPager.
type LicenseProfilesClientUpdateResponse ¶
type LicenseProfilesClientUpdateResponse struct { // Describes a license profile in a hybrid machine. LicenseProfile }
LicenseProfilesClientUpdateResponse contains the response from method LicenseProfilesClient.BeginUpdate.
type LicenseProfilesListResult ¶
type LicenseProfilesListResult struct { // REQUIRED; The list of license profiles. Value []*LicenseProfile // The URI to fetch the next page of Machines. Call ListNext() with this URI to fetch the next page of license profile. NextLink *string }
LicenseProfilesListResult - The List hybrid machine license profile operation response.
func (LicenseProfilesListResult) MarshalJSON ¶
func (l LicenseProfilesListResult) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type LicenseProfilesListResult.
func (*LicenseProfilesListResult) UnmarshalJSON ¶
func (l *LicenseProfilesListResult) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type LicenseProfilesListResult.
type LicenseProperties ¶
type LicenseProperties struct { // Describes the properties of a License. LicenseDetails *LicenseDetails // The type of the license resource. LicenseType *LicenseType // Describes the tenant id. TenantID *string // READ-ONLY; The provisioning state, which only appears in the response. ProvisioningState *ProvisioningState }
LicenseProperties - Describes the properties of a License Profile.
func (LicenseProperties) MarshalJSON ¶
func (l LicenseProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type LicenseProperties.
func (*LicenseProperties) UnmarshalJSON ¶
func (l *LicenseProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type LicenseProperties.
type LicenseState ¶
type LicenseState string
LicenseState - Describes the state of the license.
const ( LicenseStateActivated LicenseState = "Activated" LicenseStateDeactivated LicenseState = "Deactivated" )
func PossibleLicenseStateValues ¶
func PossibleLicenseStateValues() []LicenseState
PossibleLicenseStateValues returns the possible values for the LicenseState const type.
type LicenseStatus ¶
type LicenseStatus string
LicenseStatus - The license status.
const ( LicenseStatusExtendedGrace LicenseStatus = "ExtendedGrace" LicenseStatusLicensed LicenseStatus = "Licensed" LicenseStatusNonGenuineGrace LicenseStatus = "NonGenuineGrace" LicenseStatusNotification LicenseStatus = "Notification" LicenseStatusOOBGrace LicenseStatus = "OOBGrace" LicenseStatusOOTGrace LicenseStatus = "OOTGrace" LicenseStatusUnlicensed LicenseStatus = "Unlicensed" )
func PossibleLicenseStatusValues ¶
func PossibleLicenseStatusValues() []LicenseStatus
PossibleLicenseStatusValues returns the possible values for the LicenseStatus const type.
type LicenseTarget ¶
type LicenseTarget string
LicenseTarget - Describes the license target server.
const ( LicenseTargetWindowsServer2012 LicenseTarget = "Windows Server 2012" LicenseTargetWindowsServer2012R2 LicenseTarget = "Windows Server 2012 R2" )
func PossibleLicenseTargetValues ¶
func PossibleLicenseTargetValues() []LicenseTarget
PossibleLicenseTargetValues returns the possible values for the LicenseTarget const type.
type LicenseType ¶
type LicenseType string
LicenseType - The type of the license resource.
const (
LicenseTypeESU LicenseType = "ESU"
)
func PossibleLicenseTypeValues ¶
func PossibleLicenseTypeValues() []LicenseType
PossibleLicenseTypeValues returns the possible values for the LicenseType const type.
type LicenseUpdate ¶
type LicenseUpdate struct { // License Update properties Properties *LicenseUpdateProperties // Resource tags Tags map[string]*string }
LicenseUpdate - Describes a License Update.
func (LicenseUpdate) MarshalJSON ¶
func (l LicenseUpdate) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type LicenseUpdate.
func (*LicenseUpdate) UnmarshalJSON ¶
func (l *LicenseUpdate) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type LicenseUpdate.
type LicenseUpdateProperties ¶
type LicenseUpdateProperties struct { LicenseDetails *LicenseUpdatePropertiesLicenseDetails // The type of the license resource. LicenseType *LicenseType }
LicenseUpdateProperties - Describes the Update properties of a License Profile.
func (LicenseUpdateProperties) MarshalJSON ¶
func (l LicenseUpdateProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type LicenseUpdateProperties.
func (*LicenseUpdateProperties) UnmarshalJSON ¶
func (l *LicenseUpdateProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type LicenseUpdateProperties.
type LicenseUpdatePropertiesLicenseDetails ¶
type LicenseUpdatePropertiesLicenseDetails struct { // Describes the edition of the license. The values are either Standard or Datacenter. Edition *LicenseEdition // Describes the number of processors. Processors *int32 // Describes the state of the license. State *LicenseState // Describes the license target server. Target *LicenseTarget // Describes the license core type (pCore or vCore). Type *LicenseCoreType }
func (LicenseUpdatePropertiesLicenseDetails) MarshalJSON ¶
func (l LicenseUpdatePropertiesLicenseDetails) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type LicenseUpdatePropertiesLicenseDetails.
func (*LicenseUpdatePropertiesLicenseDetails) UnmarshalJSON ¶
func (l *LicenseUpdatePropertiesLicenseDetails) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type LicenseUpdatePropertiesLicenseDetails.
type LicensesClient ¶
type LicensesClient struct {
// contains filtered or unexported fields
}
LicensesClient contains the methods for the Licenses group. Don't use this type directly, use NewLicensesClient() instead.
func NewLicensesClient ¶
func NewLicensesClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*LicensesClient, error)
NewLicensesClient creates a new instance of LicensesClient with the specified values.
- subscriptionID - The ID of the target subscription.
- credential - used to authorize requests. Usually a credential from azidentity.
- options - pass nil to accept the default values.
func (*LicensesClient) BeginCreateOrUpdate ¶
func (client *LicensesClient) BeginCreateOrUpdate(ctx context.Context, resourceGroupName string, licenseName string, parameters License, options *LicensesClientBeginCreateOrUpdateOptions) (*runtime.Poller[LicensesClientCreateOrUpdateResponse], error)
BeginCreateOrUpdate - The operation to create or update a license. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group. The name is case insensitive.
- licenseName - The name of the license.
- parameters - Parameters supplied to the Create license operation.
- options - LicensesClientBeginCreateOrUpdateOptions contains the optional parameters for the LicensesClient.BeginCreateOrUpdate method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/license/License_CreateOrUpdate.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewLicensesClient().BeginCreateOrUpdate(ctx, "myResourceGroup", "{licenseName}", armhybridcompute.License{ Location: to.Ptr("eastus2euap"), Properties: &armhybridcompute.LicenseProperties{ LicenseDetails: &armhybridcompute.LicenseDetails{ Type: to.Ptr(armhybridcompute.LicenseCoreTypePCore), Edition: to.Ptr(armhybridcompute.LicenseEditionDatacenter), Processors: to.Ptr[int32](6), State: to.Ptr(armhybridcompute.LicenseStateActivated), Target: to.Ptr(armhybridcompute.LicenseTargetWindowsServer2012), }, LicenseType: to.Ptr(armhybridcompute.LicenseTypeESU), }, }, nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) } res, err := poller.PollUntilDone(ctx, nil) if err != nil { log.Fatalf("failed to pull the result: %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.License = armhybridcompute.License{ // Name: to.Ptr("{licenseName}"), // Type: to.Ptr("Microsoft.HybridCompute/licenses"), // ID: to.Ptr("/subscriptions/{subscriptionId}/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/Licenses/{licenseName}"), // Location: to.Ptr("eastus2euap"), // Properties: &armhybridcompute.LicenseProperties{ // LicenseDetails: &armhybridcompute.LicenseDetails{ // Type: to.Ptr(armhybridcompute.LicenseCoreTypePCore), // AssignedLicenses: to.Ptr[int32](2), // Edition: to.Ptr(armhybridcompute.LicenseEditionDatacenter), // ImmutableID: to.Ptr("<generated Guid>"), // Processors: to.Ptr[int32](6), // State: to.Ptr(armhybridcompute.LicenseStateActivated), // Target: to.Ptr(armhybridcompute.LicenseTargetWindowsServer2012), // }, // LicenseType: to.Ptr(armhybridcompute.LicenseTypeESU), // TenantID: to.Ptr("{tenandId}"), // }, // }
Output:
func (*LicensesClient) BeginDelete ¶
func (client *LicensesClient) BeginDelete(ctx context.Context, resourceGroupName string, licenseName string, options *LicensesClientBeginDeleteOptions) (*runtime.Poller[LicensesClientDeleteResponse], error)
BeginDelete - The operation to delete a license. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group. The name is case insensitive.
- licenseName - The name of the license.
- options - LicensesClientBeginDeleteOptions contains the optional parameters for the LicensesClient.BeginDelete method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/license/License_Delete.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewLicensesClient().BeginDelete(ctx, "myResourceGroup", "{licenseName}", nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) } _, err = poller.PollUntilDone(ctx, nil) if err != nil { log.Fatalf("failed to pull the result: %v", err) }
Output:
func (*LicensesClient) BeginUpdate ¶
func (client *LicensesClient) BeginUpdate(ctx context.Context, resourceGroupName string, licenseName string, parameters LicenseUpdate, options *LicensesClientBeginUpdateOptions) (*runtime.Poller[LicensesClientUpdateResponse], error)
BeginUpdate - The operation to update a license. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group. The name is case insensitive.
- licenseName - The name of the license.
- parameters - Parameters supplied to the Update license operation.
- options - LicensesClientBeginUpdateOptions contains the optional parameters for the LicensesClient.BeginUpdate method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/license/License_Update.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewLicensesClient().BeginUpdate(ctx, "myResourceGroup", "{licenseName}", armhybridcompute.LicenseUpdate{ Properties: &armhybridcompute.LicenseUpdateProperties{ LicenseDetails: &armhybridcompute.LicenseUpdatePropertiesLicenseDetails{ Type: to.Ptr(armhybridcompute.LicenseCoreTypePCore), Edition: to.Ptr(armhybridcompute.LicenseEditionDatacenter), Processors: to.Ptr[int32](6), State: to.Ptr(armhybridcompute.LicenseStateActivated), Target: to.Ptr(armhybridcompute.LicenseTargetWindowsServer2012), }, LicenseType: to.Ptr(armhybridcompute.LicenseTypeESU), }, }, nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) } res, err := poller.PollUntilDone(ctx, nil) if err != nil { log.Fatalf("failed to pull the result: %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.License = armhybridcompute.License{ // Name: to.Ptr("{licenseName}"), // Type: to.Ptr("Microsoft.HybridCompute/licenses"), // ID: to.Ptr("/subscriptions/{subscriptionId}/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/licenses/{licenseName}"), // Location: to.Ptr("eastus2euap"), // Properties: &armhybridcompute.LicenseProperties{ // LicenseDetails: &armhybridcompute.LicenseDetails{ // Type: to.Ptr(armhybridcompute.LicenseCoreTypePCore), // AssignedLicenses: to.Ptr[int32](8), // Edition: to.Ptr(armhybridcompute.LicenseEditionDatacenter), // ImmutableID: to.Ptr("<generated Guid>"), // Processors: to.Ptr[int32](6), // State: to.Ptr(armhybridcompute.LicenseStateActivated), // Target: to.Ptr(armhybridcompute.LicenseTargetWindowsServer2012), // }, // LicenseType: to.Ptr(armhybridcompute.LicenseTypeESU), // TenantID: to.Ptr("{tenandId}"), // }, // }
Output:
func (*LicensesClient) BeginValidateLicense ¶
func (client *LicensesClient) BeginValidateLicense(ctx context.Context, parameters License, options *LicensesClientBeginValidateLicenseOptions) (*runtime.Poller[LicensesClientValidateLicenseResponse], error)
BeginValidateLicense - The operation to validate a license. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-07-10
- parameters - Parameters supplied to the license validation operation.
- options - LicensesClientBeginValidateLicenseOptions contains the optional parameters for the LicensesClient.BeginValidateLicense method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/license/License_ValidateLicense.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewLicensesClient().BeginValidateLicense(ctx, armhybridcompute.License{ Location: to.Ptr("eastus2euap"), Properties: &armhybridcompute.LicenseProperties{ LicenseDetails: &armhybridcompute.LicenseDetails{ Type: to.Ptr(armhybridcompute.LicenseCoreTypePCore), Edition: to.Ptr(armhybridcompute.LicenseEditionDatacenter), Processors: to.Ptr[int32](6), State: to.Ptr(armhybridcompute.LicenseStateActivated), Target: to.Ptr(armhybridcompute.LicenseTargetWindowsServer2012), }, LicenseType: to.Ptr(armhybridcompute.LicenseTypeESU), }, }, nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) } res, err := poller.PollUntilDone(ctx, nil) if err != nil { log.Fatalf("failed to pull the result: %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.License = armhybridcompute.License{ // Name: to.Ptr("{licenseName}"), // Type: to.Ptr("Microsoft.HybridCompute/licenses"), // ID: to.Ptr("/subscriptions/{subscriptionId}/providers/Microsoft.HybridCompute/Licenses/{licenseName}"), // Location: to.Ptr("eastus2euap"), // Properties: &armhybridcompute.LicenseProperties{ // LicenseDetails: &armhybridcompute.LicenseDetails{ // Type: to.Ptr(armhybridcompute.LicenseCoreTypePCore), // AssignedLicenses: to.Ptr[int32](2), // Edition: to.Ptr(armhybridcompute.LicenseEditionDatacenter), // ImmutableID: to.Ptr("<generated Guid>"), // Processors: to.Ptr[int32](6), // State: to.Ptr(armhybridcompute.LicenseStateActivated), // Target: to.Ptr(armhybridcompute.LicenseTargetWindowsServer2012), // }, // LicenseType: to.Ptr(armhybridcompute.LicenseTypeESU), // TenantID: to.Ptr("{tenandId}"), // }, // }
Output:
func (*LicensesClient) Get ¶
func (client *LicensesClient) Get(ctx context.Context, resourceGroupName string, licenseName string, options *LicensesClientGetOptions) (LicensesClientGetResponse, error)
Get - Retrieves information about the view of a license. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group. The name is case insensitive.
- licenseName - The name of the license.
- options - LicensesClientGetOptions contains the optional parameters for the LicensesClient.Get method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/license/License_Get.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := clientFactory.NewLicensesClient().Get(ctx, "myResourceGroup", "{licenseName}", 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.License = armhybridcompute.License{ // Name: to.Ptr("{licenseName}"), // Type: to.Ptr("Microsoft.HybridCompute/licenses"), // ID: to.Ptr("/subscriptions/{subscriptionId}/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/Licenses/{licenseName}"), // Location: to.Ptr("eastus2euap"), // Properties: &armhybridcompute.LicenseProperties{ // LicenseDetails: &armhybridcompute.LicenseDetails{ // Type: to.Ptr(armhybridcompute.LicenseCoreTypePCore), // AssignedLicenses: to.Ptr[int32](8), // Edition: to.Ptr(armhybridcompute.LicenseEditionDatacenter), // ImmutableID: to.Ptr("<generated Guid>"), // Processors: to.Ptr[int32](6), // State: to.Ptr(armhybridcompute.LicenseStateActivated), // Target: to.Ptr(armhybridcompute.LicenseTargetWindowsServer2012), // }, // LicenseType: to.Ptr(armhybridcompute.LicenseTypeESU), // TenantID: to.Ptr("{tenandId}"), // }, // }
Output:
func (*LicensesClient) NewListByResourceGroupPager ¶
func (client *LicensesClient) NewListByResourceGroupPager(resourceGroupName string, options *LicensesClientListByResourceGroupOptions) *runtime.Pager[LicensesClientListByResourceGroupResponse]
NewListByResourceGroupPager - The operation to get all licenses of a non-Azure machine
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group. The name is case insensitive.
- options - LicensesClientListByResourceGroupOptions contains the optional parameters for the LicensesClient.NewListByResourceGroupPager method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/license/License_ListByResourceGroup.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } pager := clientFactory.NewLicensesClient().NewListByResourceGroupPager("myResourceGroup", 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.LicensesListResult = armhybridcompute.LicensesListResult{ // Value: []*armhybridcompute.License{ // { // Name: to.Ptr("{licenseName}"), // Type: to.Ptr("Microsoft.HybridCompute/licenses"), // ID: to.Ptr("/subscriptions/{subscriptionId}/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/Licenses/{licenseName}"), // Location: to.Ptr("eastus2euap"), // Properties: &armhybridcompute.LicenseProperties{ // LicenseDetails: &armhybridcompute.LicenseDetails{ // Type: to.Ptr(armhybridcompute.LicenseCoreTypePCore), // AssignedLicenses: to.Ptr[int32](8), // Edition: to.Ptr(armhybridcompute.LicenseEditionDatacenter), // ImmutableID: to.Ptr("<generated Guid>"), // Processors: to.Ptr[int32](6), // State: to.Ptr(armhybridcompute.LicenseStateActivated), // Target: to.Ptr(armhybridcompute.LicenseTargetWindowsServer2012), // }, // LicenseType: to.Ptr(armhybridcompute.LicenseTypeESU), // TenantID: to.Ptr("{tenandId}"), // }, // }}, // } }
Output:
func (*LicensesClient) NewListBySubscriptionPager ¶
func (client *LicensesClient) NewListBySubscriptionPager(options *LicensesClientListBySubscriptionOptions) *runtime.Pager[LicensesClientListBySubscriptionResponse]
NewListBySubscriptionPager - The operation to get all licenses of a non-Azure machine
Generated from API version 2024-07-10
- options - LicensesClientListBySubscriptionOptions contains the optional parameters for the LicensesClient.NewListBySubscriptionPager method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/license/License_ListBySubscription.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } pager := clientFactory.NewLicensesClient().NewListBySubscriptionPager(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.LicensesListResult = armhybridcompute.LicensesListResult{ // Value: []*armhybridcompute.License{ // { // Name: to.Ptr("{licenseName}"), // Type: to.Ptr("Microsoft.HybridCompute/licenses"), // ID: to.Ptr("/subscriptions/{subscriptionId}/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/Licenses/{licenseName}"), // Location: to.Ptr("eastus2euap"), // Properties: &armhybridcompute.LicenseProperties{ // LicenseDetails: &armhybridcompute.LicenseDetails{ // Type: to.Ptr(armhybridcompute.LicenseCoreTypePCore), // AssignedLicenses: to.Ptr[int32](8), // Edition: to.Ptr(armhybridcompute.LicenseEditionDatacenter), // ImmutableID: to.Ptr("<generated Guid>"), // Processors: to.Ptr[int32](6), // State: to.Ptr(armhybridcompute.LicenseStateActivated), // Target: to.Ptr(armhybridcompute.LicenseTargetWindowsServer2012), // }, // LicenseType: to.Ptr(armhybridcompute.LicenseTypeESU), // TenantID: to.Ptr("{tenandId}"), // }, // }}, // } }
Output:
type LicensesClientBeginCreateOrUpdateOptions ¶
type LicensesClientBeginCreateOrUpdateOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
LicensesClientBeginCreateOrUpdateOptions contains the optional parameters for the LicensesClient.BeginCreateOrUpdate method.
type LicensesClientBeginDeleteOptions ¶
type LicensesClientBeginDeleteOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
LicensesClientBeginDeleteOptions contains the optional parameters for the LicensesClient.BeginDelete method.
type LicensesClientBeginUpdateOptions ¶
type LicensesClientBeginUpdateOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
LicensesClientBeginUpdateOptions contains the optional parameters for the LicensesClient.BeginUpdate method.
type LicensesClientBeginValidateLicenseOptions ¶
type LicensesClientBeginValidateLicenseOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
LicensesClientBeginValidateLicenseOptions contains the optional parameters for the LicensesClient.BeginValidateLicense method.
type LicensesClientCreateOrUpdateResponse ¶
type LicensesClientCreateOrUpdateResponse struct { // Describes a license in a hybrid machine. License }
LicensesClientCreateOrUpdateResponse contains the response from method LicensesClient.BeginCreateOrUpdate.
type LicensesClientDeleteResponse ¶
type LicensesClientDeleteResponse struct { }
LicensesClientDeleteResponse contains the response from method LicensesClient.BeginDelete.
type LicensesClientGetOptions ¶
type LicensesClientGetOptions struct { }
LicensesClientGetOptions contains the optional parameters for the LicensesClient.Get method.
type LicensesClientGetResponse ¶
type LicensesClientGetResponse struct { // Describes a license in a hybrid machine. License }
LicensesClientGetResponse contains the response from method LicensesClient.Get.
type LicensesClientListByResourceGroupOptions ¶
type LicensesClientListByResourceGroupOptions struct { }
LicensesClientListByResourceGroupOptions contains the optional parameters for the LicensesClient.NewListByResourceGroupPager method.
type LicensesClientListByResourceGroupResponse ¶
type LicensesClientListByResourceGroupResponse struct { // The List license operation response. LicensesListResult }
LicensesClientListByResourceGroupResponse contains the response from method LicensesClient.NewListByResourceGroupPager.
type LicensesClientListBySubscriptionOptions ¶
type LicensesClientListBySubscriptionOptions struct { }
LicensesClientListBySubscriptionOptions contains the optional parameters for the LicensesClient.NewListBySubscriptionPager method.
type LicensesClientListBySubscriptionResponse ¶
type LicensesClientListBySubscriptionResponse struct { // The List license operation response. LicensesListResult }
LicensesClientListBySubscriptionResponse contains the response from method LicensesClient.NewListBySubscriptionPager.
type LicensesClientUpdateResponse ¶
type LicensesClientUpdateResponse struct { // Describes a license in a hybrid machine. License }
LicensesClientUpdateResponse contains the response from method LicensesClient.BeginUpdate.
type LicensesClientValidateLicenseResponse ¶
type LicensesClientValidateLicenseResponse struct { // Describes a license in a hybrid machine. License }
LicensesClientValidateLicenseResponse contains the response from method LicensesClient.BeginValidateLicense.
type LicensesListResult ¶
type LicensesListResult struct { // REQUIRED; The list of licenses. Value []*License // The URI to fetch the next page of Machines. Call ListNext() with this URI to fetch the next page of license profile. NextLink *string }
LicensesListResult - The List license operation response.
func (LicensesListResult) MarshalJSON ¶
func (l LicensesListResult) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type LicensesListResult.
func (*LicensesListResult) UnmarshalJSON ¶
func (l *LicensesListResult) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type LicensesListResult.
type LinuxParameters ¶
type LinuxParameters struct { // The update classifications to select when installing patches for Linux. ClassificationsToInclude []*VMGuestPatchClassificationLinux // packages to exclude in the patch operation. Format: packageName_packageVersion PackageNameMasksToExclude []*string // packages to include in the patch operation. Format: packageName_packageVersion PackageNameMasksToInclude []*string }
LinuxParameters - Input for InstallPatches on a Linux VM, as directly received by the API
func (LinuxParameters) MarshalJSON ¶
func (l LinuxParameters) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type LinuxParameters.
func (*LinuxParameters) UnmarshalJSON ¶
func (l *LinuxParameters) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type LinuxParameters.
type LocationData ¶
type LocationData struct { // REQUIRED; A canonical name for the geographic or physical location. Name *string // The city or locality where the resource is located. City *string // The country or region where the resource is located CountryOrRegion *string // The district, state, or province where the resource is located. District *string }
LocationData - Metadata pertaining to the geographic location of the resource.
func (LocationData) MarshalJSON ¶
func (l LocationData) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type LocationData.
func (*LocationData) UnmarshalJSON ¶
func (l *LocationData) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type LocationData.
type Machine ¶
type Machine struct { // REQUIRED; The geo-location where the resource lives Location *string // Identity for the resource. Identity *Identity // Indicates which kind of Arc machine placement on-premises, such as HCI, SCVMM or VMware etc. Kind *ArcKindEnum // Hybrid Compute Machine properties Properties *MachineProperties // Resource tags. Tags map[string]*string // READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string // READ-ONLY; The name of the resource Name *string // READ-ONLY; The list of extensions affiliated to the machine Resources []*MachineExtension // READ-ONLY; Azure Resource Manager metadata containing createdBy and modifiedBy information. SystemData *SystemData // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string }
Machine - Describes a hybrid machine.
func (Machine) MarshalJSON ¶
MarshalJSON implements the json.Marshaller interface for type Machine.
func (*Machine) UnmarshalJSON ¶
UnmarshalJSON implements the json.Unmarshaller interface for type Machine.
type MachineAssessPatchesResult ¶
type MachineAssessPatchesResult struct { // Summarization of patches available for installation on the machine by classification. AvailablePatchCountByClassification *AvailablePatchCountByClassification // READ-ONLY; The activity ID of the operation that produced this result. AssessmentActivityID *string // READ-ONLY; The errors that were encountered during execution of the operation. The details array contains the list of them. ErrorDetails *ErrorDetail // READ-ONLY; The UTC timestamp when the operation finished. LastModifiedDateTime *time.Time // READ-ONLY; The operating system type of the machine. OSType *OsType // READ-ONLY; Specifies the patch service used for the operation. PatchServiceUsed *PatchServiceUsed // READ-ONLY; The overall reboot status of the VM. It will be true when partially installed patches require a reboot to complete // installation but the reboot has not yet occurred. RebootPending *bool // READ-ONLY; The UTC timestamp when the operation began. StartDateTime *time.Time // READ-ONLY; Indicates if operation was triggered by user or by platform. StartedBy *PatchOperationStartedBy // READ-ONLY; The overall success or failure status of the operation. It remains "InProgress" until the operation completes. // At that point it will become "Unknown", "Failed", "Succeeded", or // "CompletedWithWarnings." Status *PatchOperationStatus }
MachineAssessPatchesResult - Describes the properties of an AssessPatches result.
func (MachineAssessPatchesResult) MarshalJSON ¶
func (m MachineAssessPatchesResult) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type MachineAssessPatchesResult.
func (*MachineAssessPatchesResult) UnmarshalJSON ¶
func (m *MachineAssessPatchesResult) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type MachineAssessPatchesResult.
type MachineExtension ¶
type MachineExtension struct { // REQUIRED; The geo-location where the resource lives Location *string // Describes Machine Extension Properties. Properties *MachineExtensionProperties // Resource tags. Tags map[string]*string // READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string // READ-ONLY; The name of the resource Name *string // READ-ONLY; Azure Resource Manager metadata containing createdBy and modifiedBy information. SystemData *SystemData // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string }
MachineExtension - Describes a Machine Extension.
func (MachineExtension) MarshalJSON ¶
func (m MachineExtension) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type MachineExtension.
func (*MachineExtension) UnmarshalJSON ¶
func (m *MachineExtension) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type MachineExtension.
type MachineExtensionInstanceView ¶
type MachineExtensionInstanceView struct { // The machine extension name. Name *string // Instance view status. Status *MachineExtensionInstanceViewStatus // Specifies the type of the extension; an example is "CustomScriptExtension". Type *string // Specifies the version of the script handler. TypeHandlerVersion *string }
MachineExtensionInstanceView - Describes the Machine Extension Instance View.
func (MachineExtensionInstanceView) MarshalJSON ¶
func (m MachineExtensionInstanceView) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type MachineExtensionInstanceView.
func (*MachineExtensionInstanceView) UnmarshalJSON ¶
func (m *MachineExtensionInstanceView) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type MachineExtensionInstanceView.
type MachineExtensionInstanceViewStatus ¶
type MachineExtensionInstanceViewStatus struct { // The status code. Code *string // The short localizable label for the status. DisplayStatus *string // The level code. Level *StatusLevelTypes // The detailed status message, including for alerts and error messages. Message *string // The time of the status. Time *time.Time }
MachineExtensionInstanceViewStatus - Instance view status.
func (MachineExtensionInstanceViewStatus) MarshalJSON ¶
func (m MachineExtensionInstanceViewStatus) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type MachineExtensionInstanceViewStatus.
func (*MachineExtensionInstanceViewStatus) UnmarshalJSON ¶
func (m *MachineExtensionInstanceViewStatus) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type MachineExtensionInstanceViewStatus.
type MachineExtensionProperties ¶
type MachineExtensionProperties struct { // Indicates whether the extension should use a newer minor version if one is available at deployment time. Once deployed, // however, the extension will not upgrade minor versions unless redeployed, even // with this property set to true. AutoUpgradeMinorVersion *bool // Indicates whether the extension should be automatically upgraded by the platform if there is a newer version available. EnableAutomaticUpgrade *bool // How the extension handler should be forced to update even if the extension configuration has not changed. ForceUpdateTag *string // The machine extension instance view. InstanceView *MachineExtensionInstanceView // The extension can contain either protectedSettings or protectedSettingsFromKeyVault or no protected settings at all. ProtectedSettings map[string]any // The name of the extension handler publisher. Publisher *string // Json formatted public settings for the extension. Settings map[string]any // Specifies the type of the extension; an example is "CustomScriptExtension". Type *string // Specifies the version of the script handler. TypeHandlerVersion *string // READ-ONLY; The provisioning state, which only appears in the response. ProvisioningState *string }
MachineExtensionProperties - Describes the properties of a Machine Extension.
func (MachineExtensionProperties) MarshalJSON ¶
func (m MachineExtensionProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type MachineExtensionProperties.
func (*MachineExtensionProperties) UnmarshalJSON ¶
func (m *MachineExtensionProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type MachineExtensionProperties.
type MachineExtensionUpdate ¶
type MachineExtensionUpdate struct { // Describes Machine Extension Update Properties. Properties *MachineExtensionUpdateProperties // Resource tags Tags map[string]*string }
MachineExtensionUpdate - Describes a Machine Extension Update.
func (MachineExtensionUpdate) MarshalJSON ¶
func (m MachineExtensionUpdate) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type MachineExtensionUpdate.
func (*MachineExtensionUpdate) UnmarshalJSON ¶
func (m *MachineExtensionUpdate) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type MachineExtensionUpdate.
type MachineExtensionUpdateProperties ¶
type MachineExtensionUpdateProperties struct { // Indicates whether the extension should use a newer minor version if one is available at deployment time. Once deployed, // however, the extension will not upgrade minor versions unless redeployed, even // with this property set to true. AutoUpgradeMinorVersion *bool // Indicates whether the extension should be automatically upgraded by the platform if there is a newer version available. EnableAutomaticUpgrade *bool // How the extension handler should be forced to update even if the extension configuration has not changed. ForceUpdateTag *string // The extension can contain either protectedSettings or protectedSettingsFromKeyVault or no protected settings at all. ProtectedSettings map[string]any // The name of the extension handler publisher. Publisher *string // Json formatted public settings for the extension. Settings map[string]any // Specifies the type of the extension; an example is "CustomScriptExtension". Type *string // Specifies the version of the script handler. TypeHandlerVersion *string }
MachineExtensionUpdateProperties - Describes the properties of a Machine Extension.
func (MachineExtensionUpdateProperties) MarshalJSON ¶
func (m MachineExtensionUpdateProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type MachineExtensionUpdateProperties.
func (*MachineExtensionUpdateProperties) UnmarshalJSON ¶
func (m *MachineExtensionUpdateProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type MachineExtensionUpdateProperties.
type MachineExtensionUpgrade ¶
type MachineExtensionUpgrade struct { // Describes the Extension Target Properties. ExtensionTargets map[string]*ExtensionTargetProperties }
MachineExtensionUpgrade - Describes the Machine Extension Upgrade Properties.
func (MachineExtensionUpgrade) MarshalJSON ¶
func (m MachineExtensionUpgrade) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type MachineExtensionUpgrade.
func (*MachineExtensionUpgrade) UnmarshalJSON ¶
func (m *MachineExtensionUpgrade) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type MachineExtensionUpgrade.
type MachineExtensionsClient ¶
type MachineExtensionsClient struct {
// contains filtered or unexported fields
}
MachineExtensionsClient contains the methods for the MachineExtensions group. Don't use this type directly, use NewMachineExtensionsClient() instead.
func NewMachineExtensionsClient ¶
func NewMachineExtensionsClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*MachineExtensionsClient, error)
NewMachineExtensionsClient creates a new instance of MachineExtensionsClient with the specified values.
- subscriptionID - The ID of the target subscription.
- credential - used to authorize requests. Usually a credential from azidentity.
- options - pass nil to accept the default values.
func (*MachineExtensionsClient) BeginCreateOrUpdate ¶
func (client *MachineExtensionsClient) BeginCreateOrUpdate(ctx context.Context, resourceGroupName string, machineName string, extensionName string, extensionParameters MachineExtension, options *MachineExtensionsClientBeginCreateOrUpdateOptions) (*runtime.Poller[MachineExtensionsClientCreateOrUpdateResponse], error)
BeginCreateOrUpdate - The operation to create or update the extension. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group. The name is case insensitive.
- machineName - The name of the machine where the extension should be created or updated.
- extensionName - The name of the machine extension.
- extensionParameters - Parameters supplied to the Create Machine Extension operation.
- options - MachineExtensionsClientBeginCreateOrUpdateOptions contains the optional parameters for the MachineExtensionsClient.BeginCreateOrUpdate method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/extension/Extension_CreateOrUpdate.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewMachineExtensionsClient().BeginCreateOrUpdate(ctx, "myResourceGroup", "myMachine", "CustomScriptExtension", armhybridcompute.MachineExtension{ Location: to.Ptr("eastus2euap"), Properties: &armhybridcompute.MachineExtensionProperties{ Type: to.Ptr("CustomScriptExtension"), Publisher: to.Ptr("Microsoft.Compute"), Settings: map[string]any{ "commandToExecute": "powershell.exe -c \"Get-Process | Where-Object { $_.CPU -gt 10000 }\"", }, TypeHandlerVersion: to.Ptr("1.10"), }, }, nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) } res, err := poller.PollUntilDone(ctx, nil) if err != nil { log.Fatalf("failed to pull the result: %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.MachineExtension = armhybridcompute.MachineExtension{ // Name: to.Ptr("CustomScriptExtension"), // Type: to.Ptr("Microsoft.HybridCompute/machines/extensions"), // ID: to.Ptr("/subscriptions/{subscriptionId}/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/Machines/myMachine/Extensions/CustomScriptExtension"), // Location: to.Ptr("eastus2euap"), // Properties: &armhybridcompute.MachineExtensionProperties{ // Type: to.Ptr("string"), // AutoUpgradeMinorVersion: to.Ptr(false), // InstanceView: &armhybridcompute.MachineExtensionInstanceView{ // Name: to.Ptr("CustomScriptExtension"), // Type: to.Ptr("CustomScriptExtension"), // Status: &armhybridcompute.MachineExtensionInstanceViewStatus{ // Code: to.Ptr("success"), // Level: to.Ptr(armhybridcompute.StatusLevelTypes("Information")), // Message: to.Ptr("Finished executing command, StdOut: , StdErr:"), // Time: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2020-08-08T20:42:10.999Z"); return t}()), // }, // TypeHandlerVersion: to.Ptr("1.10.3"), // }, // ProtectedSettings: map[string]any{ // }, // ProvisioningState: to.Ptr("Succeeded"), // Publisher: to.Ptr("Microsoft.Compute"), // Settings: map[string]any{ // "commandToExecute": "powershell.exe -c \"Get-Process | Where-Object { $_.CPU -gt 10000 }\"", // }, // TypeHandlerVersion: to.Ptr("1.10.3"), // }, // }
Output:
func (*MachineExtensionsClient) BeginDelete ¶
func (client *MachineExtensionsClient) BeginDelete(ctx context.Context, resourceGroupName string, machineName string, extensionName string, options *MachineExtensionsClientBeginDeleteOptions) (*runtime.Poller[MachineExtensionsClientDeleteResponse], error)
BeginDelete - The operation to delete the extension. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group. The name is case insensitive.
- machineName - The name of the machine where the extension should be deleted.
- extensionName - The name of the machine extension.
- options - MachineExtensionsClientBeginDeleteOptions contains the optional parameters for the MachineExtensionsClient.BeginDelete method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/extension/Extension_Delete.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewMachineExtensionsClient().BeginDelete(ctx, "myResourceGroup", "myMachine", "MMA", nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) } _, err = poller.PollUntilDone(ctx, nil) if err != nil { log.Fatalf("failed to pull the result: %v", err) }
Output:
func (*MachineExtensionsClient) BeginUpdate ¶
func (client *MachineExtensionsClient) BeginUpdate(ctx context.Context, resourceGroupName string, machineName string, extensionName string, extensionParameters MachineExtensionUpdate, options *MachineExtensionsClientBeginUpdateOptions) (*runtime.Poller[MachineExtensionsClientUpdateResponse], error)
BeginUpdate - The operation to update the extension. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group. The name is case insensitive.
- machineName - The name of the machine where the extension should be created or updated.
- extensionName - The name of the machine extension.
- extensionParameters - Parameters supplied to the Create Machine Extension operation.
- options - MachineExtensionsClientBeginUpdateOptions contains the optional parameters for the MachineExtensionsClient.BeginUpdate method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/extension/Extension_Update.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewMachineExtensionsClient().BeginUpdate(ctx, "myResourceGroup", "myMachine", "CustomScriptExtension", armhybridcompute.MachineExtensionUpdate{ Properties: &armhybridcompute.MachineExtensionUpdateProperties{ Type: to.Ptr("CustomScriptExtension"), EnableAutomaticUpgrade: to.Ptr(true), Publisher: to.Ptr("Microsoft.Compute"), Settings: map[string]any{ "commandToExecute": "powershell.exe -c \"Get-Process | Where-Object { $_.CPU -lt 100 }\"", }, TypeHandlerVersion: to.Ptr("1.10"), }, }, nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) } res, err := poller.PollUntilDone(ctx, nil) if err != nil { log.Fatalf("failed to pull the result: %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.MachineExtension = armhybridcompute.MachineExtension{ // Name: to.Ptr("CustomScriptExtension"), // Type: to.Ptr("Microsoft.HybridCompute/machines/extensions"), // ID: to.Ptr("/subscriptions/{subscriptionId}/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/Machines/myMachine/Extensions/CustomScriptExtension"), // Location: to.Ptr("eastus2euap"), // Properties: &armhybridcompute.MachineExtensionProperties{ // Type: to.Ptr("string"), // AutoUpgradeMinorVersion: to.Ptr(false), // EnableAutomaticUpgrade: to.Ptr(true), // InstanceView: &armhybridcompute.MachineExtensionInstanceView{ // Name: to.Ptr("CustomScriptExtension"), // Type: to.Ptr("CustomScriptExtension"), // Status: &armhybridcompute.MachineExtensionInstanceViewStatus{ // Code: to.Ptr("success"), // Level: to.Ptr(armhybridcompute.StatusLevelTypes("Information")), // Message: to.Ptr("Finished executing command, StdOut: , StdErr:"), // Time: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2020-01-08T20:42:10.999Z"); return t}()), // }, // TypeHandlerVersion: to.Ptr("1.10.3"), // }, // ProtectedSettings: map[string]any{ // }, // ProvisioningState: to.Ptr("Succeeded"), // Publisher: to.Ptr("Microsoft.Compute"), // Settings: map[string]any{ // "commandToExecute": "powershell.exe -c \"Get-Process | Where-Object { $_.CPU -gt 10000 }\"", // }, // TypeHandlerVersion: to.Ptr("1.10.3"), // }, // }
Output:
func (*MachineExtensionsClient) Get ¶
func (client *MachineExtensionsClient) Get(ctx context.Context, resourceGroupName string, machineName string, extensionName string, options *MachineExtensionsClientGetOptions) (MachineExtensionsClientGetResponse, error)
Get - The operation to get the extension. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group. The name is case insensitive.
- machineName - The name of the machine containing the extension.
- extensionName - The name of the machine extension.
- options - MachineExtensionsClientGetOptions contains the optional parameters for the MachineExtensionsClient.Get method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/extension/Extension_Get.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := clientFactory.NewMachineExtensionsClient().Get(ctx, "myResourceGroup", "myMachine", "CustomScriptExtension", 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.MachineExtension = armhybridcompute.MachineExtension{ // Name: to.Ptr("CustomScriptExtension"), // Type: to.Ptr("Microsoft.HybridCompute/machines/extensions"), // ID: to.Ptr("/subscriptions/{subscriptionId}/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/Machines/myMachine/Extensions/CustomScriptExtension"), // Location: to.Ptr("eastus2euap"), // Properties: &armhybridcompute.MachineExtensionProperties{ // Type: to.Ptr("string"), // AutoUpgradeMinorVersion: to.Ptr(false), // InstanceView: &armhybridcompute.MachineExtensionInstanceView{ // Name: to.Ptr("CustomScriptExtension"), // Type: to.Ptr("CustomScriptExtension"), // Status: &armhybridcompute.MachineExtensionInstanceViewStatus{ // Code: to.Ptr("success"), // DisplayStatus: to.Ptr("Provisioning succeeded"), // Level: to.Ptr(armhybridcompute.StatusLevelTypes("Information")), // Message: to.Ptr("Finished executing command, StdOut: , StdErr:"), // Time: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2019-08-08T20:42:10.999Z"); return t}()), // }, // TypeHandlerVersion: to.Ptr("1.10.3"), // }, // ProtectedSettings: map[string]any{ // }, // ProvisioningState: to.Ptr("Succeeded"), // Publisher: to.Ptr("Microsoft.Compute"), // Settings: map[string]any{ // "commandToExecute": "powershell.exe -c \"Get-Process | Where-Object { $_.CPU -gt 10000 }\"", // }, // TypeHandlerVersion: to.Ptr("1.10.3"), // }, // }
Output:
func (*MachineExtensionsClient) NewListPager ¶
func (client *MachineExtensionsClient) NewListPager(resourceGroupName string, machineName string, options *MachineExtensionsClientListOptions) *runtime.Pager[MachineExtensionsClientListResponse]
NewListPager - The operation to get all extensions of a non-Azure machine
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group. The name is case insensitive.
- machineName - The name of the machine containing the extension.
- options - MachineExtensionsClientListOptions contains the optional parameters for the MachineExtensionsClient.NewListPager method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/extension/Extension_List.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } pager := clientFactory.NewMachineExtensionsClient().NewListPager("myResourceGroup", "myMachine", &armhybridcompute.MachineExtensionsClientListOptions{Expand: 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.MachineExtensionsListResult = armhybridcompute.MachineExtensionsListResult{ // Value: []*armhybridcompute.MachineExtension{ // { // Name: to.Ptr("CustomScriptExtension"), // Type: to.Ptr("Microsoft.HybridCompute/machines/extensions"), // ID: to.Ptr("/subscriptions/{subscriptionId}/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/Machines/myMachine/Extensions/CustomScriptExtension"), // Location: to.Ptr("eastus2euap"), // Properties: &armhybridcompute.MachineExtensionProperties{ // Type: to.Ptr("CustomScriptExtension"), // AutoUpgradeMinorVersion: to.Ptr(false), // InstanceView: &armhybridcompute.MachineExtensionInstanceView{ // Name: to.Ptr("CustomScriptExtension"), // Type: to.Ptr("CustomScriptExtension"), // Status: &armhybridcompute.MachineExtensionInstanceViewStatus{ // Code: to.Ptr("success"), // DisplayStatus: to.Ptr("Provisioning succeeded"), // Level: to.Ptr(armhybridcompute.StatusLevelTypes("Information")), // Message: to.Ptr("formattedMessage: Finished executing command, StdOut: , StdErr: "), // Time: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2020-08-13T17:18:57.405Z"); return t}()), // }, // TypeHandlerVersion: to.Ptr("1.10.3"), // }, // ProvisioningState: to.Ptr("Succeeded"), // Publisher: to.Ptr("Microsoft.Compute"), // Settings: map[string]any{ // "commandToExecute": "powershell.exe -c \"Get-Process | Where-Object { $_.CPU -gt 10000 }\"", // }, // TypeHandlerVersion: to.Ptr("1.10.3"), // }, // }, // { // Name: to.Ptr("winosupdateextension"), // Type: to.Ptr("Microsoft.HybridCompute/machines/extensions"), // ID: to.Ptr("/subscriptions/{subscriptionId}/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/Machines/myMachine/Extensions/winosupdateextension"), // Location: to.Ptr("eastus2euap"), // Properties: &armhybridcompute.MachineExtensionProperties{ // Type: to.Ptr("windowsosupdateextension"), // AutoUpgradeMinorVersion: to.Ptr(false), // InstanceView: &armhybridcompute.MachineExtensionInstanceView{ // Name: to.Ptr("winosupdateextension"), // Type: to.Ptr("windowsosupdateextension"), // Status: &armhybridcompute.MachineExtensionInstanceViewStatus{ // }, // TypeHandlerVersion: to.Ptr("1.0.0.0"), // }, // ProvisioningState: to.Ptr("Succeeded"), // Publisher: to.Ptr("microsoft.softwareupdatemanagement.test"), // Settings: map[string]any{ // }, // TypeHandlerVersion: to.Ptr("1.0.0.0"), // }, // }}, // } }
Output:
type MachineExtensionsClientBeginCreateOrUpdateOptions ¶
type MachineExtensionsClientBeginCreateOrUpdateOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
MachineExtensionsClientBeginCreateOrUpdateOptions contains the optional parameters for the MachineExtensionsClient.BeginCreateOrUpdate method.
type MachineExtensionsClientBeginDeleteOptions ¶
type MachineExtensionsClientBeginDeleteOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
MachineExtensionsClientBeginDeleteOptions contains the optional parameters for the MachineExtensionsClient.BeginDelete method.
type MachineExtensionsClientBeginUpdateOptions ¶
type MachineExtensionsClientBeginUpdateOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
MachineExtensionsClientBeginUpdateOptions contains the optional parameters for the MachineExtensionsClient.BeginUpdate method.
type MachineExtensionsClientCreateOrUpdateResponse ¶
type MachineExtensionsClientCreateOrUpdateResponse struct { // Describes a Machine Extension. MachineExtension }
MachineExtensionsClientCreateOrUpdateResponse contains the response from method MachineExtensionsClient.BeginCreateOrUpdate.
type MachineExtensionsClientDeleteResponse ¶
type MachineExtensionsClientDeleteResponse struct { }
MachineExtensionsClientDeleteResponse contains the response from method MachineExtensionsClient.BeginDelete.
type MachineExtensionsClientGetOptions ¶
type MachineExtensionsClientGetOptions struct { }
MachineExtensionsClientGetOptions contains the optional parameters for the MachineExtensionsClient.Get method.
type MachineExtensionsClientGetResponse ¶
type MachineExtensionsClientGetResponse struct { // Describes a Machine Extension. MachineExtension }
MachineExtensionsClientGetResponse contains the response from method MachineExtensionsClient.Get.
type MachineExtensionsClientListOptions ¶
type MachineExtensionsClientListOptions struct { // The expand expression to apply on the operation. Expand *string }
MachineExtensionsClientListOptions contains the optional parameters for the MachineExtensionsClient.NewListPager method.
type MachineExtensionsClientListResponse ¶
type MachineExtensionsClientListResponse struct { // Describes the Machine Extensions List Result. MachineExtensionsListResult }
MachineExtensionsClientListResponse contains the response from method MachineExtensionsClient.NewListPager.
type MachineExtensionsClientUpdateResponse ¶
type MachineExtensionsClientUpdateResponse struct { // Describes a Machine Extension. MachineExtension }
MachineExtensionsClientUpdateResponse contains the response from method MachineExtensionsClient.BeginUpdate.
type MachineExtensionsListResult ¶
type MachineExtensionsListResult struct { // The uri to fetch the next page of machine extensions. Call ListNext() with this to fetch the next page of extensions. NextLink *string // The list of extensions Value []*MachineExtension }
MachineExtensionsListResult - Describes the Machine Extensions List Result.
func (MachineExtensionsListResult) MarshalJSON ¶
func (m MachineExtensionsListResult) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type MachineExtensionsListResult.
func (*MachineExtensionsListResult) UnmarshalJSON ¶
func (m *MachineExtensionsListResult) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type MachineExtensionsListResult.
type MachineInstallPatchesParameters ¶
type MachineInstallPatchesParameters struct { // REQUIRED; Specifies the maximum amount of time that the operation will run. It must be an ISO 8601-compliant duration string // such as PT4H (4 hours) MaximumDuration *string // REQUIRED; Defines when it is acceptable to reboot a VM during a software update operation. RebootSetting *VMGuestPatchRebootSetting // Input for InstallPatches on a Linux VM, as directly received by the API LinuxParameters *LinuxParameters // Input for InstallPatches on a Windows VM, as directly received by the API WindowsParameters *WindowsParameters }
MachineInstallPatchesParameters - Input for InstallPatches as directly received by the API
func (MachineInstallPatchesParameters) MarshalJSON ¶
func (m MachineInstallPatchesParameters) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type MachineInstallPatchesParameters.
func (*MachineInstallPatchesParameters) UnmarshalJSON ¶
func (m *MachineInstallPatchesParameters) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type MachineInstallPatchesParameters.
type MachineInstallPatchesResult ¶
type MachineInstallPatchesResult struct { // READ-ONLY; The errors that were encountered during execution of the operation. The details array contains the list of them. ErrorDetails *ErrorDetail // READ-ONLY; The number of patches that were not installed due to the user blocking their installation. ExcludedPatchCount *int32 // READ-ONLY; The number of patches that could not be installed due to some issue. See errors for details. FailedPatchCount *int32 // READ-ONLY; The activity ID of the operation that produced this result. InstallationActivityID *string // READ-ONLY; The number of patches successfully installed. InstalledPatchCount *int32 // READ-ONLY; The UTC timestamp when the operation finished. LastModifiedDateTime *time.Time // READ-ONLY; Whether the operation ran out of time before it completed all its intended actions. MaintenanceWindowExceeded *bool // READ-ONLY; The number of patches that were detected as available for install, but did not meet the operation's criteria. NotSelectedPatchCount *int32 // READ-ONLY; The operating system type of the machine. OSType *OsType // READ-ONLY; Specifies the patch service used for the operation. PatchServiceUsed *PatchServiceUsed // READ-ONLY; The number of patches that were identified as meeting the installation criteria, but were not able to be installed. // Typically this happens when maintenanceWindowExceeded == true. PendingPatchCount *int32 // READ-ONLY; The reboot state of the VM following completion of the operation. RebootStatus *VMGuestPatchRebootStatus // READ-ONLY; The UTC timestamp when the operation began. StartDateTime *time.Time // READ-ONLY; Indicates if operation was triggered by user or by platform. StartedBy *PatchOperationStartedBy // READ-ONLY; The overall success or failure status of the operation. It remains "InProgress" until the operation completes. // At that point it will become "Failed", "Succeeded", "Unknown" or "CompletedWithWarnings." Status *PatchOperationStatus }
MachineInstallPatchesResult - The result summary of an installation operation.
func (MachineInstallPatchesResult) MarshalJSON ¶
func (m MachineInstallPatchesResult) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type MachineInstallPatchesResult.
func (*MachineInstallPatchesResult) UnmarshalJSON ¶
func (m *MachineInstallPatchesResult) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type MachineInstallPatchesResult.
type MachineListResult ¶
type MachineListResult struct { // REQUIRED; The list of hybrid machines. Value []*Machine // The URI to fetch the next page of Machines. Call ListNext() with this URI to fetch the next page of hybrid machines. NextLink *string }
MachineListResult - The List hybrid machine operation response.
func (MachineListResult) MarshalJSON ¶
func (m MachineListResult) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type MachineListResult.
func (*MachineListResult) UnmarshalJSON ¶
func (m *MachineListResult) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type MachineListResult.
type MachineProperties ¶
type MachineProperties struct { // The info of the machine w.r.t Agent Upgrade AgentUpgrade *AgentUpgrade // Public Key that the client provides to be used during initial resource onboarding ClientPublicKey *string // The metadata of the cloud environment (Azure/GCP/AWS/OCI…). CloudMetadata *CloudMetadata // Machine Extensions information (deprecated field) Extensions []*MachineExtensionInstanceView // Specifies the License related properties for a machine. LicenseProfile *LicenseProfileMachineInstanceView // Metadata pertaining to the geographic location of the resource. LocationData *LocationData // Specifies whether any MS SQL instance is discovered on the machine. MssqlDiscovered *string // Specifies the operating system settings for the hybrid machine. OSProfile *OSProfile // The type of Operating System (windows/linux). OSType *string // The resource id of the parent cluster (Azure HCI) this machine is assigned to, if any. ParentClusterResourceID *string // The resource id of the private link scope this machine is assigned to, if any. PrivateLinkScopeResourceID *string // Statuses of dependent services that are reported back to ARM. ServiceStatuses *ServiceStatuses // Specifies the hybrid machine unique ID. VMID *string // READ-ONLY; Specifies the AD fully qualified display name. AdFqdn *string // READ-ONLY; Configurable properties that the user can set locally via the azcmagent config command, or remotely via ARM. AgentConfiguration *AgentConfiguration // READ-ONLY; The hybrid machine agent full version. AgentVersion *string // READ-ONLY; Specifies the DNS fully qualified display name. DNSFqdn *string // READ-ONLY; Detected properties from the machine. DetectedProperties map[string]*string // READ-ONLY; Specifies the hybrid machine display name. DisplayName *string // READ-ONLY; Specifies the Windows domain name. DomainName *string // READ-ONLY; Details about the error state. ErrorDetails []*ErrorDetail // READ-ONLY; The time of the last status change. LastStatusChange *time.Time // READ-ONLY; Specifies the hybrid machine FQDN. MachineFqdn *string // READ-ONLY; Information about the network the machine is on. NetworkProfile *NetworkProfile // READ-ONLY; The edition of the Operating System. OSEdition *string // READ-ONLY; The Operating System running on the hybrid machine. OSName *string // READ-ONLY; Specifies the Operating System product SKU. OSSKU *string // READ-ONLY; The version of Operating System running on the hybrid machine. OSVersion *string // READ-ONLY; The provisioning state, which only appears in the response. ProvisioningState *string // READ-ONLY; The status of the hybrid machine agent. Status *StatusTypes // READ-ONLY; Specifies the Arc Machine's unique SMBIOS ID VMUUID *string }
MachineProperties - Describes the properties of a hybrid machine.
func (MachineProperties) MarshalJSON ¶
func (m MachineProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type MachineProperties.
func (*MachineProperties) UnmarshalJSON ¶
func (m *MachineProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type MachineProperties.
type MachineUpdate ¶
type MachineUpdate struct { // Identity for the resource. Identity *Identity // Indicates which kind of Arc machine placement on-premises, such as HCI, SCVMM or VMware etc. Kind *ArcKindEnum // Hybrid Compute Machine properties Properties *MachineUpdateProperties // Resource tags Tags map[string]*string }
MachineUpdate - Describes a hybrid machine Update.
func (MachineUpdate) MarshalJSON ¶
func (m MachineUpdate) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type MachineUpdate.
func (*MachineUpdate) UnmarshalJSON ¶
func (m *MachineUpdate) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type MachineUpdate.
type MachineUpdateProperties ¶
type MachineUpdateProperties struct { // The info of the machine w.r.t Agent Upgrade AgentUpgrade *AgentUpgrade // The metadata of the cloud environment (Azure/GCP/AWS/OCI…). CloudMetadata *CloudMetadata // Metadata pertaining to the geographic location of the resource. LocationData *LocationData // Specifies the operating system settings for the hybrid machine. OSProfile *OSProfile // The resource id of the parent cluster (Azure HCI) this machine is assigned to, if any. ParentClusterResourceID *string // The resource id of the private link scope this machine is assigned to, if any. PrivateLinkScopeResourceID *string }
MachineUpdateProperties - Describes the ARM updatable properties of a hybrid machine.
func (MachineUpdateProperties) MarshalJSON ¶
func (m MachineUpdateProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type MachineUpdateProperties.
func (*MachineUpdateProperties) UnmarshalJSON ¶
func (m *MachineUpdateProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type MachineUpdateProperties.
type MachinesClient ¶
type MachinesClient struct {
// contains filtered or unexported fields
}
MachinesClient contains the methods for the Machines group. Don't use this type directly, use NewMachinesClient() instead.
func NewMachinesClient ¶
func NewMachinesClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*MachinesClient, error)
NewMachinesClient creates a new instance of MachinesClient with the specified values.
- subscriptionID - The ID of the target subscription.
- credential - used to authorize requests. Usually a credential from azidentity.
- options - pass nil to accept the default values.
func (*MachinesClient) BeginAssessPatches ¶
func (client *MachinesClient) BeginAssessPatches(ctx context.Context, resourceGroupName string, name string, options *MachinesClientBeginAssessPatchesOptions) (*runtime.Poller[MachinesClientAssessPatchesResponse], error)
BeginAssessPatches - The operation to assess patches on a hybrid machine identity in Azure. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group.
- name - The name of the hybrid machine.
- options - MachinesClientBeginAssessPatchesOptions contains the optional parameters for the MachinesClient.BeginAssessPatches method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/machine/Machine_AssessPatches.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewMachinesClient().BeginAssessPatches(ctx, "myResourceGroupName", "myMachineName", nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) } res, err := poller.PollUntilDone(ctx, nil) if err != nil { log.Fatalf("failed to pull the result: %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.MachineAssessPatchesResult = armhybridcompute.MachineAssessPatchesResult{ // AssessmentActivityID: to.Ptr("68f8b292-dfc2-4646-9781-33cc88631968"), // AvailablePatchCountByClassification: &armhybridcompute.AvailablePatchCountByClassification{ // Critical: to.Ptr[int32](0), // Definition: to.Ptr[int32](0), // FeaturePack: to.Ptr[int32](0), // Security: to.Ptr[int32](0), // ServicePack: to.Ptr[int32](0), // Tools: to.Ptr[int32](0), // UpdateRollup: to.Ptr[int32](1), // Updates: to.Ptr[int32](1), // }, // LastModifiedDateTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-22T02:16:06.974Z"); return t}()), // OSType: to.Ptr(armhybridcompute.OsTypeWindows), // RebootPending: to.Ptr(true), // StartDateTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-22T02:15:20.934Z"); return t}()), // StartedBy: to.Ptr(armhybridcompute.PatchOperationStartedByUser), // Status: to.Ptr(armhybridcompute.PatchOperationStatusSucceeded), // }
Output:
func (*MachinesClient) BeginInstallPatches ¶
func (client *MachinesClient) BeginInstallPatches(ctx context.Context, resourceGroupName string, name string, installPatchesInput MachineInstallPatchesParameters, options *MachinesClientBeginInstallPatchesOptions) (*runtime.Poller[MachinesClientInstallPatchesResponse], error)
BeginInstallPatches - The operation to install patches on a hybrid machine identity in Azure. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group.
- name - The name of the hybrid machine.
- installPatchesInput - Input for InstallPatches as directly received by the API
- options - MachinesClientBeginInstallPatchesOptions contains the optional parameters for the MachinesClient.BeginInstallPatches method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/machine/Machine_InstallPatches.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewMachinesClient().BeginInstallPatches(ctx, "myResourceGroupName", "myMachineName", armhybridcompute.MachineInstallPatchesParameters{ MaximumDuration: to.Ptr("PT4H"), RebootSetting: to.Ptr(armhybridcompute.VMGuestPatchRebootSettingIfRequired), WindowsParameters: &armhybridcompute.WindowsParameters{ ClassificationsToInclude: []*armhybridcompute.VMGuestPatchClassificationWindows{ to.Ptr(armhybridcompute.VMGuestPatchClassificationWindowsCritical), to.Ptr(armhybridcompute.VMGuestPatchClassificationWindowsSecurity)}, MaxPatchPublishDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-19T02:36:43.053Z"); return t }()), }, }, nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) } res, err := poller.PollUntilDone(ctx, nil) if err != nil { log.Fatalf("failed to pull the result: %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.MachineInstallPatchesResult = armhybridcompute.MachineInstallPatchesResult{ // ExcludedPatchCount: to.Ptr[int32](0), // FailedPatchCount: to.Ptr[int32](0), // InstallationActivityID: to.Ptr("68f8b292-dfc2-4646-9781-33cc88631968"), // InstalledPatchCount: to.Ptr[int32](3), // LastModifiedDateTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-22T02:16:06.974Z"); return t}()), // MaintenanceWindowExceeded: to.Ptr(false), // NotSelectedPatchCount: to.Ptr[int32](0), // OSType: to.Ptr(armhybridcompute.OsTypeWindows), // PendingPatchCount: to.Ptr[int32](2), // RebootStatus: to.Ptr(armhybridcompute.VMGuestPatchRebootStatusCompleted), // StartDateTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-08-22T02:15:06.974Z"); return t}()), // StartedBy: to.Ptr(armhybridcompute.PatchOperationStartedByUser), // Status: to.Ptr(armhybridcompute.PatchOperationStatusSucceeded), // }
Output:
func (*MachinesClient) CreateOrUpdate ¶
func (client *MachinesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, machineName string, parameters Machine, options *MachinesClientCreateOrUpdateOptions) (MachinesClientCreateOrUpdateResponse, error)
CreateOrUpdate - The operation to create or update a hybrid machine. Please note some properties can be set only during machine creation. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group. The name is case insensitive.
- machineName - The name of the hybrid machine.
- parameters - Parameters supplied to the Create hybrid machine operation.
- options - MachinesClientCreateOrUpdateOptions contains the optional parameters for the MachinesClient.CreateOrUpdate method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/machine/Machines_CreateOrUpdate.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := clientFactory.NewMachinesClient().CreateOrUpdate(ctx, "myResourceGroup", "myMachine", armhybridcompute.Machine{ Location: to.Ptr("eastus2euap"), Identity: &armhybridcompute.Identity{ Type: to.Ptr("SystemAssigned"), }, Properties: &armhybridcompute.MachineProperties{ ClientPublicKey: to.Ptr("string"), LocationData: &armhybridcompute.LocationData{ Name: to.Ptr("Redmond"), }, OSProfile: &armhybridcompute.OSProfile{ WindowsConfiguration: &armhybridcompute.OSProfileWindowsConfiguration{ PatchSettings: &armhybridcompute.PatchSettings{ EnableHotpatching: to.Ptr(true), }, }, }, ParentClusterResourceID: to.Ptr("{AzureStackHCIResourceId}"), PrivateLinkScopeResourceID: to.Ptr("/subscriptions/{subscriptionId}/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/privateLinkScopes/privateLinkScopeName"), VMID: to.Ptr("b7a098cc-b0b8-46e8-a205-62f301a62a8f"), }, }, &armhybridcompute.MachinesClientCreateOrUpdateOptions{Expand: 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.Machine = armhybridcompute.Machine{ // Name: to.Ptr("myMachine"), // Type: to.Ptr("Microsoft.HybridCompute/machines"), // ID: to.Ptr("/subscriptions/{subscriptionId}/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/machines/myMachine"), // Location: to.Ptr("eastus2euap"), // Identity: &armhybridcompute.Identity{ // Type: to.Ptr("SystemAssigned"), // PrincipalID: to.Ptr("string"), // TenantID: to.Ptr("string"), // }, // Properties: &armhybridcompute.MachineProperties{ // ClientPublicKey: to.Ptr("string"), // DetectedProperties: map[string]*string{ // "cloudprovider": to.Ptr("N/A"), // "manufacturer": to.Ptr("Microsoft Corporation"), // "model": to.Ptr("Virtual Machine"), // }, // LicenseProfile: &armhybridcompute.LicenseProfileMachineInstanceView{ // EsuProfile: &armhybridcompute.LicenseProfileMachineInstanceViewEsuProperties{ // EsuKeys: []*armhybridcompute.EsuKey{ // { // LicenseStatus: to.Ptr[int32](1), // SKU: to.Ptr("skuNumber1"), // }, // { // LicenseStatus: to.Ptr[int32](1), // SKU: to.Ptr("skuNumber2"), // }}, // EsuEligibility: to.Ptr(armhybridcompute.EsuEligibilityIneligible), // EsuKeyState: to.Ptr(armhybridcompute.EsuKeyStateInactive), // ServerType: to.Ptr(armhybridcompute.EsuServerTypeStandard), // LicenseAssignmentState: to.Ptr(armhybridcompute.LicenseAssignmentStateAssigned), // }, // LicenseChannel: to.Ptr("PSG"), // LicenseStatus: to.Ptr(armhybridcompute.LicenseStatusLicensed), // ProductProfile: &armhybridcompute.LicenseProfileArmProductProfileProperties{ // BillingEndDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // BillingStartDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // DisenrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // EnrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // ProductFeatures: []*armhybridcompute.ProductFeature{ // { // Name: to.Ptr("Hotpatch"), // BillingEndDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // BillingStartDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // DisenrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // EnrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // SubscriptionStatus: to.Ptr(armhybridcompute.LicenseProfileSubscriptionStatusEnabled), // }}, // ProductType: to.Ptr(armhybridcompute.LicenseProfileProductTypeWindowsServer), // SubscriptionStatus: to.Ptr(armhybridcompute.LicenseProfileSubscriptionStatusEnabled), // }, // SoftwareAssurance: &armhybridcompute.LicenseProfileMachineInstanceViewSoftwareAssurance{ // SoftwareAssuranceCustomer: to.Ptr(true), // }, // }, // LocationData: &armhybridcompute.LocationData{ // Name: to.Ptr("Redmond"), // City: to.Ptr("redmond"), // CountryOrRegion: to.Ptr("usa"), // }, // MssqlDiscovered: to.Ptr("false"), // OSEdition: to.Ptr("Standard"), // OSProfile: &armhybridcompute.OSProfile{ // LinuxConfiguration: &armhybridcompute.OSProfileLinuxConfiguration{ // PatchSettings: &armhybridcompute.PatchSettings{ // }, // }, // WindowsConfiguration: &armhybridcompute.OSProfileWindowsConfiguration{ // PatchSettings: &armhybridcompute.PatchSettings{ // EnableHotpatching: to.Ptr(true), // Status: &armhybridcompute.PatchSettingsStatus{ // HotpatchEnablementStatus: to.Ptr(armhybridcompute.HotpatchEnablementStatusPendingEvaluation), // }, // }, // }, // }, // ParentClusterResourceID: to.Ptr("{AzureStackHCIResourceId}"), // PrivateLinkScopeResourceID: to.Ptr("/subscriptions/{subscriptionId}/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/privateLinkScopes/privateLinkScopeName"), // ProvisioningState: to.Ptr("Succeeded"), // VMID: to.Ptr("b7a098cc-b0b8-46e8-a205-62f301a62a8f"), // }, // }
Output:
func (*MachinesClient) Delete ¶
func (client *MachinesClient) Delete(ctx context.Context, resourceGroupName string, machineName string, options *MachinesClientDeleteOptions) (MachinesClientDeleteResponse, error)
Delete - The operation to delete a hybrid machine. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group. The name is case insensitive.
- machineName - The name of the hybrid machine.
- options - MachinesClientDeleteOptions contains the optional parameters for the MachinesClient.Delete method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/machine/Machines_Delete.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } _, err = clientFactory.NewMachinesClient().Delete(ctx, "myResourceGroup", "myMachine", nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) }
Output:
func (*MachinesClient) Get ¶
func (client *MachinesClient) Get(ctx context.Context, resourceGroupName string, machineName string, options *MachinesClientGetOptions) (MachinesClientGetResponse, error)
Get - Retrieves information about the model view or the instance view of a hybrid machine. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group. The name is case insensitive.
- machineName - The name of the hybrid machine.
- options - MachinesClientGetOptions contains the optional parameters for the MachinesClient.Get method.
Example (GetMachine) ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/machine/Machines_Get.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := clientFactory.NewMachinesClient().Get(ctx, "myResourceGroup", "myMachine", &armhybridcompute.MachinesClientGetOptions{Expand: 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.Machine = armhybridcompute.Machine{ // Name: to.Ptr("myMachine"), // Type: to.Ptr("Microsoft.HybridCompute/machines"), // ID: to.Ptr("/subscriptions/{subscriptionId}/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/machines/myMachine"), // Location: to.Ptr("eastus2euap"), // Identity: &armhybridcompute.Identity{ // Type: to.Ptr("SystemAssigned"), // PrincipalID: to.Ptr("string"), // TenantID: to.Ptr("string"), // }, // Properties: &armhybridcompute.MachineProperties{ // AgentConfiguration: &armhybridcompute.AgentConfiguration{ // ConfigMode: to.Ptr(armhybridcompute.AgentConfigurationModeFull), // ExtensionsEnabled: to.Ptr("true"), // GuestConfigurationEnabled: to.Ptr("true"), // IncomingConnectionsPorts: []*string{ // to.Ptr("22"), // to.Ptr("23")}, // ProxyBypass: []*string{ // to.Ptr("proxy1"), // to.Ptr("proxy2")}, // ProxyURL: to.Ptr("https://test.test"), // }, // ClientPublicKey: to.Ptr("string"), // DetectedProperties: map[string]*string{ // "cloudprovider": to.Ptr("N/A"), // "manufacturer": to.Ptr("Microsoft Corporation"), // "model": to.Ptr("Virtual Machine"), // }, // LicenseProfile: &armhybridcompute.LicenseProfileMachineInstanceView{ // EsuProfile: &armhybridcompute.LicenseProfileMachineInstanceViewEsuProperties{ // EsuKeys: []*armhybridcompute.EsuKey{ // { // LicenseStatus: to.Ptr[int32](1), // SKU: to.Ptr("skuNumber1"), // }, // { // LicenseStatus: to.Ptr[int32](1), // SKU: to.Ptr("skuNumber2"), // }}, // EsuEligibility: to.Ptr(armhybridcompute.EsuEligibilityIneligible), // EsuKeyState: to.Ptr(armhybridcompute.EsuKeyStateInactive), // ServerType: to.Ptr(armhybridcompute.EsuServerTypeStandard), // LicenseAssignmentState: to.Ptr(armhybridcompute.LicenseAssignmentStateAssigned), // }, // LicenseChannel: to.Ptr("PSG"), // LicenseStatus: to.Ptr(armhybridcompute.LicenseStatusLicensed), // ProductProfile: &armhybridcompute.LicenseProfileArmProductProfileProperties{ // BillingEndDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // BillingStartDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // DisenrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // EnrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // ProductFeatures: []*armhybridcompute.ProductFeature{ // { // Name: to.Ptr("Hotpatch"), // BillingEndDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // BillingStartDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // DisenrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // EnrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // SubscriptionStatus: to.Ptr(armhybridcompute.LicenseProfileSubscriptionStatusEnabled), // }}, // ProductType: to.Ptr(armhybridcompute.LicenseProfileProductTypeWindowsServer), // SubscriptionStatus: to.Ptr(armhybridcompute.LicenseProfileSubscriptionStatusEnabled), // }, // SoftwareAssurance: &armhybridcompute.LicenseProfileMachineInstanceViewSoftwareAssurance{ // SoftwareAssuranceCustomer: to.Ptr(true), // }, // }, // LocationData: &armhybridcompute.LocationData{ // Name: to.Ptr("Redmond"), // City: to.Ptr("redmond"), // CountryOrRegion: to.Ptr("usa"), // }, // MssqlDiscovered: to.Ptr("false"), // NetworkProfile: &armhybridcompute.NetworkProfile{ // NetworkInterfaces: []*armhybridcompute.NetworkInterface{ // { // IPAddresses: []*armhybridcompute.IPAddress{ // { // Address: to.Ptr("192.168.12.345"), // IPAddressVersion: to.Ptr("IPv4"), // Subnet: &armhybridcompute.Subnet{ // AddressPrefix: to.Ptr("192.168.12.0/24"), // }, // }}, // }, // { // IPAddresses: []*armhybridcompute.IPAddress{ // { // Address: to.Ptr("1001:0:34aa:5000:1234:aaaa:bbbb:cccc"), // IPAddressVersion: to.Ptr("IPv6"), // Subnet: &armhybridcompute.Subnet{ // AddressPrefix: to.Ptr("1001:0:34aa:5000::/64"), // }, // }}, // }}, // }, // OSEdition: to.Ptr("Standard"), // OSProfile: &armhybridcompute.OSProfile{ // LinuxConfiguration: &armhybridcompute.OSProfileLinuxConfiguration{ // PatchSettings: &armhybridcompute.PatchSettings{ // }, // }, // WindowsConfiguration: &armhybridcompute.OSProfileWindowsConfiguration{ // PatchSettings: &armhybridcompute.PatchSettings{ // EnableHotpatching: to.Ptr(true), // Status: &armhybridcompute.PatchSettingsStatus{ // HotpatchEnablementStatus: to.Ptr(armhybridcompute.HotpatchEnablementStatusEnabled), // }, // }, // }, // }, // ParentClusterResourceID: to.Ptr("{AzureStackHCIResourceId}"), // PrivateLinkScopeResourceID: to.Ptr("/subscriptions/{subscriptionId}/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/privateLinkScopes/privateLinkScopeName"), // ProvisioningState: to.Ptr("Succeeded"), // ServiceStatuses: &armhybridcompute.ServiceStatuses{ // ExtensionService: &armhybridcompute.ServiceStatus{ // StartupType: to.Ptr("Automatic"), // Status: to.Ptr("Running"), // }, // GuestConfigurationService: &armhybridcompute.ServiceStatus{ // StartupType: to.Ptr("Automatic"), // Status: to.Ptr("Running"), // }, // }, // VMID: to.Ptr("b7a098cc-b0b8-46e8-a205-62f301a62a8f"), // }, // Resources: []*armhybridcompute.MachineExtension{ // }, // }
Output:
Example (GetMachineWithLicenseProfileInstanceView) ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/machine/Machines_Get_LicenseProfileInstanceView.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := clientFactory.NewMachinesClient().Get(ctx, "myResourceGroup", "myMachine", &armhybridcompute.MachinesClientGetOptions{Expand: to.Ptr(armhybridcompute.InstanceViewTypesInstanceView)}) 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.Machine = armhybridcompute.Machine{ // Name: to.Ptr("myMachine"), // Type: to.Ptr("Microsoft.HybridCompute/machines"), // ID: to.Ptr("/subscriptions/{subscriptionId}/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/machines/myMachine"), // Location: to.Ptr("eastus2euap"), // Identity: &armhybridcompute.Identity{ // Type: to.Ptr("SystemAssigned"), // PrincipalID: to.Ptr("string"), // TenantID: to.Ptr("string"), // }, // Properties: &armhybridcompute.MachineProperties{ // AgentConfiguration: &armhybridcompute.AgentConfiguration{ // ConfigMode: to.Ptr(armhybridcompute.AgentConfigurationModeFull), // ExtensionsEnabled: to.Ptr("true"), // GuestConfigurationEnabled: to.Ptr("true"), // IncomingConnectionsPorts: []*string{ // to.Ptr("22"), // to.Ptr("23")}, // ProxyBypass: []*string{ // to.Ptr("proxy1"), // to.Ptr("proxy2")}, // ProxyURL: to.Ptr("https://test.test"), // }, // ClientPublicKey: to.Ptr("string"), // DetectedProperties: map[string]*string{ // "cloudprovider": to.Ptr("N/A"), // "manufacturer": to.Ptr("Microsoft Corporation"), // "model": to.Ptr("Virtual Machine"), // }, // LicenseProfile: &armhybridcompute.LicenseProfileMachineInstanceView{ // EsuProfile: &armhybridcompute.LicenseProfileMachineInstanceViewEsuProperties{ // EsuKeys: []*armhybridcompute.EsuKey{ // { // LicenseStatus: to.Ptr[int32](1), // SKU: to.Ptr("skuNumber1"), // }, // { // LicenseStatus: to.Ptr[int32](1), // SKU: to.Ptr("skuNumber2"), // }}, // EsuEligibility: to.Ptr(armhybridcompute.EsuEligibilityIneligible), // EsuKeyState: to.Ptr(armhybridcompute.EsuKeyStateInactive), // ServerType: to.Ptr(armhybridcompute.EsuServerTypeStandard), // AssignedLicense: &armhybridcompute.License{ // Name: to.Ptr("{licenseName}"), // Type: to.Ptr("Microsoft.HybridCompute/licenses"), // ID: to.Ptr("/subscriptions/{subscriptionId}/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/Licenses/{licenseName}"), // Location: to.Ptr("eastus2euap"), // Properties: &armhybridcompute.LicenseProperties{ // LicenseDetails: &armhybridcompute.LicenseDetails{ // Type: to.Ptr(armhybridcompute.LicenseCoreTypePCore), // AssignedLicenses: to.Ptr[int32](8), // Edition: to.Ptr(armhybridcompute.LicenseEditionDatacenter), // ImmutableID: to.Ptr("<generated Guid>"), // Processors: to.Ptr[int32](6), // State: to.Ptr(armhybridcompute.LicenseStateActivated), // Target: to.Ptr(armhybridcompute.LicenseTargetWindowsServer2012), // }, // LicenseType: to.Ptr(armhybridcompute.LicenseTypeESU), // TenantID: to.Ptr("{tenandId}"), // }, // }, // LicenseAssignmentState: to.Ptr(armhybridcompute.LicenseAssignmentStateAssigned), // }, // LicenseChannel: to.Ptr("PSG"), // LicenseStatus: to.Ptr(armhybridcompute.LicenseStatusLicensed), // ProductProfile: &armhybridcompute.LicenseProfileArmProductProfileProperties{ // BillingEndDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // BillingStartDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // DisenrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // EnrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // ProductFeatures: []*armhybridcompute.ProductFeature{ // { // Name: to.Ptr("Hotpatch"), // BillingEndDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // BillingStartDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // DisenrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // EnrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // SubscriptionStatus: to.Ptr(armhybridcompute.LicenseProfileSubscriptionStatusEnabled), // }}, // ProductType: to.Ptr(armhybridcompute.LicenseProfileProductTypeWindowsServer), // SubscriptionStatus: to.Ptr(armhybridcompute.LicenseProfileSubscriptionStatusEnabled), // }, // SoftwareAssurance: &armhybridcompute.LicenseProfileMachineInstanceViewSoftwareAssurance{ // SoftwareAssuranceCustomer: to.Ptr(true), // }, // }, // LocationData: &armhybridcompute.LocationData{ // Name: to.Ptr("Redmond"), // City: to.Ptr("redmond"), // CountryOrRegion: to.Ptr("usa"), // }, // MssqlDiscovered: to.Ptr("false"), // NetworkProfile: &armhybridcompute.NetworkProfile{ // NetworkInterfaces: []*armhybridcompute.NetworkInterface{ // { // IPAddresses: []*armhybridcompute.IPAddress{ // { // Address: to.Ptr("192.168.12.345"), // IPAddressVersion: to.Ptr("IPv4"), // Subnet: &armhybridcompute.Subnet{ // AddressPrefix: to.Ptr("192.168.12.0/24"), // }, // }}, // }, // { // IPAddresses: []*armhybridcompute.IPAddress{ // { // Address: to.Ptr("1001:0:34aa:5000:1234:aaaa:bbbb:cccc"), // IPAddressVersion: to.Ptr("IPv6"), // Subnet: &armhybridcompute.Subnet{ // AddressPrefix: to.Ptr("1001:0:34aa:5000::/64"), // }, // }}, // }}, // }, // OSEdition: to.Ptr("Standard"), // OSProfile: &armhybridcompute.OSProfile{ // LinuxConfiguration: &armhybridcompute.OSProfileLinuxConfiguration{ // PatchSettings: &armhybridcompute.PatchSettings{ // }, // }, // WindowsConfiguration: &armhybridcompute.OSProfileWindowsConfiguration{ // PatchSettings: &armhybridcompute.PatchSettings{ // EnableHotpatching: to.Ptr(true), // Status: &armhybridcompute.PatchSettingsStatus{ // HotpatchEnablementStatus: to.Ptr(armhybridcompute.HotpatchEnablementStatusEnabled), // }, // }, // }, // }, // ParentClusterResourceID: to.Ptr("{AzureStackHCIResourceId}"), // PrivateLinkScopeResourceID: to.Ptr("/subscriptions/{subscriptionId}/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/privateLinkScopes/privateLinkScopeName"), // ProvisioningState: to.Ptr("Succeeded"), // ServiceStatuses: &armhybridcompute.ServiceStatuses{ // ExtensionService: &armhybridcompute.ServiceStatus{ // StartupType: to.Ptr("Automatic"), // Status: to.Ptr("Running"), // }, // GuestConfigurationService: &armhybridcompute.ServiceStatus{ // StartupType: to.Ptr("Automatic"), // Status: to.Ptr("Running"), // }, // }, // VMID: to.Ptr("b7a098cc-b0b8-46e8-a205-62f301a62a8f"), // }, // Resources: []*armhybridcompute.MachineExtension{ // }, // }
Output:
func (*MachinesClient) NewListByResourceGroupPager ¶
func (client *MachinesClient) NewListByResourceGroupPager(resourceGroupName string, options *MachinesClientListByResourceGroupOptions) *runtime.Pager[MachinesClientListByResourceGroupResponse]
NewListByResourceGroupPager - Lists all the hybrid machines in the specified resource group. Use the nextLink property in the response to get the next page of hybrid machines.
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group. The name is case insensitive.
- options - MachinesClientListByResourceGroupOptions contains the optional parameters for the MachinesClient.NewListByResourceGroupPager method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/machine/Machines_ListByResourceGroup.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } pager := clientFactory.NewMachinesClient().NewListByResourceGroupPager("myResourceGroup", &armhybridcompute.MachinesClientListByResourceGroupOptions{Expand: 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.MachineListResult = armhybridcompute.MachineListResult{ // Value: []*armhybridcompute.Machine{ // { // Name: to.Ptr("myMachine"), // Type: to.Ptr("Microsoft.HybridCompute/machines"), // ID: to.Ptr("/subscriptions/{subscriptionId}/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/machines/myMachine"), // Location: to.Ptr("eastus2euap"), // Identity: &armhybridcompute.Identity{ // Type: to.Ptr("SystemAssigned"), // PrincipalID: to.Ptr("f7a068cc-b0b8-46e8-a203-22f301a62a8f"), // TenantID: to.Ptr("c4098cc-91b8-46c2-a205-d82ab1a62a8f"), // }, // Properties: &armhybridcompute.MachineProperties{ // AgentConfiguration: &armhybridcompute.AgentConfiguration{ // ConfigMode: to.Ptr(armhybridcompute.AgentConfigurationModeFull), // ExtensionsEnabled: to.Ptr("true"), // GuestConfigurationEnabled: to.Ptr("true"), // IncomingConnectionsPorts: []*string{ // to.Ptr("22"), // to.Ptr("23")}, // ProxyBypass: []*string{ // to.Ptr("proxy1"), // to.Ptr("proxy2")}, // ProxyURL: to.Ptr("https://test.test"), // }, // ClientPublicKey: to.Ptr("string"), // DetectedProperties: map[string]*string{ // "cloudprovider": to.Ptr("N/A"), // "manufacturer": to.Ptr("Microsoft Corporation"), // "model": to.Ptr("Virtual Machine"), // }, // LicenseProfile: &armhybridcompute.LicenseProfileMachineInstanceView{ // EsuProfile: &armhybridcompute.LicenseProfileMachineInstanceViewEsuProperties{ // EsuKeys: []*armhybridcompute.EsuKey{ // { // LicenseStatus: to.Ptr[int32](1), // SKU: to.Ptr("skuNumber1"), // }, // { // LicenseStatus: to.Ptr[int32](1), // SKU: to.Ptr("skuNumber2"), // }}, // EsuEligibility: to.Ptr(armhybridcompute.EsuEligibilityIneligible), // EsuKeyState: to.Ptr(armhybridcompute.EsuKeyStateInactive), // ServerType: to.Ptr(armhybridcompute.EsuServerTypeStandard), // LicenseAssignmentState: to.Ptr(armhybridcompute.LicenseAssignmentStateAssigned), // }, // LicenseChannel: to.Ptr("PSG"), // LicenseStatus: to.Ptr(armhybridcompute.LicenseStatusLicensed), // ProductProfile: &armhybridcompute.LicenseProfileArmProductProfileProperties{ // BillingEndDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // BillingStartDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // DisenrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // EnrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // ProductFeatures: []*armhybridcompute.ProductFeature{ // { // Name: to.Ptr("Hotpatch"), // BillingEndDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // BillingStartDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // DisenrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // EnrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // SubscriptionStatus: to.Ptr(armhybridcompute.LicenseProfileSubscriptionStatusEnabled), // }}, // ProductType: to.Ptr(armhybridcompute.LicenseProfileProductTypeWindowsServer), // SubscriptionStatus: to.Ptr(armhybridcompute.LicenseProfileSubscriptionStatusEnabled), // }, // SoftwareAssurance: &armhybridcompute.LicenseProfileMachineInstanceViewSoftwareAssurance{ // SoftwareAssuranceCustomer: to.Ptr(true), // }, // }, // LocationData: &armhybridcompute.LocationData{ // Name: to.Ptr("Redmond"), // }, // MssqlDiscovered: to.Ptr("false"), // OSEdition: to.Ptr("Standard"), // OSProfile: &armhybridcompute.OSProfile{ // LinuxConfiguration: &armhybridcompute.OSProfileLinuxConfiguration{ // PatchSettings: &armhybridcompute.PatchSettings{ // }, // }, // WindowsConfiguration: &armhybridcompute.OSProfileWindowsConfiguration{ // PatchSettings: &armhybridcompute.PatchSettings{ // EnableHotpatching: to.Ptr(true), // Status: &armhybridcompute.PatchSettingsStatus{ // HotpatchEnablementStatus: to.Ptr(armhybridcompute.HotpatchEnablementStatusEnabled), // }, // }, // }, // }, // PrivateLinkScopeResourceID: to.Ptr("/subscriptions/{subscriptionId}/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/privateLinkScopes/privateLinkScopeName"), // ProvisioningState: to.Ptr("Succeeded"), // VMID: to.Ptr("b7a098cc-b0b8-46e8-a205-62f301a62a8f"), // }, // }, // { // Name: to.Ptr("myMachine2"), // Type: to.Ptr("Microsoft.HybridCompute/machines"), // ID: to.Ptr("/subscriptions/{subscription-id}/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/machines/myMachine2"), // Location: to.Ptr("westus2"), // Identity: &armhybridcompute.Identity{ // Type: to.Ptr("SystemAssigned"), // PrincipalID: to.Ptr("e7a068cc-b0b8-46e8-a203-22f301a62a8f"), // TenantID: to.Ptr("c4098cc-91b8-46c2-a205-d82ab1a62a8f"), // }, // Properties: &armhybridcompute.MachineProperties{ // AgentConfiguration: &armhybridcompute.AgentConfiguration{ // ConfigMode: to.Ptr(armhybridcompute.AgentConfigurationModeFull), // ExtensionsEnabled: to.Ptr("true"), // GuestConfigurationEnabled: to.Ptr("true"), // IncomingConnectionsPorts: []*string{ // to.Ptr("22"), // to.Ptr("23")}, // ProxyBypass: []*string{ // to.Ptr("proxy1"), // to.Ptr("proxy2")}, // ProxyURL: to.Ptr("https://test.test"), // }, // ClientPublicKey: to.Ptr("string"), // DetectedProperties: map[string]*string{ // "cloudprovider": to.Ptr("N/A"), // "manufacturer": to.Ptr("Microsoft Corporation"), // "model": to.Ptr("Surfacebook"), // }, // LicenseProfile: &armhybridcompute.LicenseProfileMachineInstanceView{ // EsuProfile: &armhybridcompute.LicenseProfileMachineInstanceViewEsuProperties{ // EsuKeys: []*armhybridcompute.EsuKey{ // { // LicenseStatus: to.Ptr[int32](1), // SKU: to.Ptr("skuNumber1"), // }, // { // LicenseStatus: to.Ptr[int32](1), // SKU: to.Ptr("skuNumber2"), // }}, // EsuEligibility: to.Ptr(armhybridcompute.EsuEligibilityIneligible), // EsuKeyState: to.Ptr(armhybridcompute.EsuKeyStateInactive), // ServerType: to.Ptr(armhybridcompute.EsuServerTypeStandard), // LicenseAssignmentState: to.Ptr(armhybridcompute.LicenseAssignmentStateAssigned), // }, // LicenseChannel: to.Ptr("PSG"), // LicenseStatus: to.Ptr(armhybridcompute.LicenseStatusLicensed), // ProductProfile: &armhybridcompute.LicenseProfileArmProductProfileProperties{ // BillingEndDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // BillingStartDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // DisenrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // EnrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // ProductFeatures: []*armhybridcompute.ProductFeature{ // { // Name: to.Ptr("Hotpatch"), // BillingEndDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // BillingStartDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // DisenrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // EnrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // SubscriptionStatus: to.Ptr(armhybridcompute.LicenseProfileSubscriptionStatusEnabled), // }}, // ProductType: to.Ptr(armhybridcompute.LicenseProfileProductTypeWindowsServer), // SubscriptionStatus: to.Ptr(armhybridcompute.LicenseProfileSubscriptionStatusEnabled), // }, // SoftwareAssurance: &armhybridcompute.LicenseProfileMachineInstanceViewSoftwareAssurance{ // SoftwareAssuranceCustomer: to.Ptr(true), // }, // }, // LocationData: &armhybridcompute.LocationData{ // Name: to.Ptr("Redmond"), // }, // MssqlDiscovered: to.Ptr("true"), // OSEdition: to.Ptr("Standard"), // OSProfile: &armhybridcompute.OSProfile{ // LinuxConfiguration: &armhybridcompute.OSProfileLinuxConfiguration{ // PatchSettings: &armhybridcompute.PatchSettings{ // }, // }, // WindowsConfiguration: &armhybridcompute.OSProfileWindowsConfiguration{ // PatchSettings: &armhybridcompute.PatchSettings{ // EnableHotpatching: to.Ptr(true), // Status: &armhybridcompute.PatchSettingsStatus{ // HotpatchEnablementStatus: to.Ptr(armhybridcompute.HotpatchEnablementStatusEnabled), // }, // }, // }, // }, // ParentClusterResourceID: to.Ptr("{AzureStackHCIResourceId}"), // PrivateLinkScopeResourceID: to.Ptr("/subscriptions/{subscriptionId}/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/privateLinkScopes/privateLinkScopeName"), // ProvisioningState: to.Ptr("Succeeded"), // VMID: to.Ptr("a4a098cc-b0b8-46e8-a205-62f301a62a8f"), // }, // }}, // } }
Output:
func (*MachinesClient) NewListBySubscriptionPager ¶
func (client *MachinesClient) NewListBySubscriptionPager(options *MachinesClientListBySubscriptionOptions) *runtime.Pager[MachinesClientListBySubscriptionResponse]
NewListBySubscriptionPager - Lists all the hybrid machines in the specified subscription. Use the nextLink property in the response to get the next page of hybrid machines.
Generated from API version 2024-07-10
- options - MachinesClientListBySubscriptionOptions contains the optional parameters for the MachinesClient.NewListBySubscriptionPager method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/machine/Machines_ListBySubscription.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } pager := clientFactory.NewMachinesClient().NewListBySubscriptionPager(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.MachineListResult = armhybridcompute.MachineListResult{ // Value: []*armhybridcompute.Machine{ // { // Name: to.Ptr("myMachine"), // Type: to.Ptr("Microsoft.HybridCompute/machines"), // ID: to.Ptr("/subscriptions/{subscriptionId}/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/machines/myMachine"), // Location: to.Ptr("eastus2euap"), // Identity: &armhybridcompute.Identity{ // Type: to.Ptr("SystemAssigned"), // PrincipalID: to.Ptr("string"), // TenantID: to.Ptr("string"), // }, // Properties: &armhybridcompute.MachineProperties{ // AgentConfiguration: &armhybridcompute.AgentConfiguration{ // ConfigMode: to.Ptr(armhybridcompute.AgentConfigurationModeFull), // ExtensionsEnabled: to.Ptr("true"), // GuestConfigurationEnabled: to.Ptr("true"), // IncomingConnectionsPorts: []*string{ // to.Ptr("22"), // to.Ptr("23")}, // ProxyBypass: []*string{ // to.Ptr("proxy1"), // to.Ptr("proxy2")}, // ProxyURL: to.Ptr("https://test.test"), // }, // ClientPublicKey: to.Ptr("string"), // DetectedProperties: map[string]*string{ // "cloudprovider": to.Ptr("N/A"), // "manufacturer": to.Ptr("Microsoft Corporation"), // "model": to.Ptr("Virtual Machine"), // }, // LicenseProfile: &armhybridcompute.LicenseProfileMachineInstanceView{ // EsuProfile: &armhybridcompute.LicenseProfileMachineInstanceViewEsuProperties{ // EsuKeys: []*armhybridcompute.EsuKey{ // { // LicenseStatus: to.Ptr[int32](1), // SKU: to.Ptr("skuNumber1"), // }, // { // LicenseStatus: to.Ptr[int32](1), // SKU: to.Ptr("skuNumber2"), // }}, // EsuEligibility: to.Ptr(armhybridcompute.EsuEligibilityIneligible), // EsuKeyState: to.Ptr(armhybridcompute.EsuKeyStateInactive), // ServerType: to.Ptr(armhybridcompute.EsuServerTypeStandard), // LicenseAssignmentState: to.Ptr(armhybridcompute.LicenseAssignmentStateAssigned), // }, // LicenseChannel: to.Ptr("PSG"), // LicenseStatus: to.Ptr(armhybridcompute.LicenseStatusLicensed), // ProductProfile: &armhybridcompute.LicenseProfileArmProductProfileProperties{ // BillingEndDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // BillingStartDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // DisenrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // EnrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // ProductFeatures: []*armhybridcompute.ProductFeature{ // { // Name: to.Ptr("Hotpatch"), // BillingEndDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // BillingStartDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // DisenrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // EnrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // SubscriptionStatus: to.Ptr(armhybridcompute.LicenseProfileSubscriptionStatusEnabled), // }}, // ProductType: to.Ptr(armhybridcompute.LicenseProfileProductTypeWindowsServer), // SubscriptionStatus: to.Ptr(armhybridcompute.LicenseProfileSubscriptionStatusEnabled), // }, // SoftwareAssurance: &armhybridcompute.LicenseProfileMachineInstanceViewSoftwareAssurance{ // SoftwareAssuranceCustomer: to.Ptr(true), // }, // }, // LocationData: &armhybridcompute.LocationData{ // Name: to.Ptr("Redmond"), // }, // MssqlDiscovered: to.Ptr("false"), // OSEdition: to.Ptr("Standard"), // OSProfile: &armhybridcompute.OSProfile{ // LinuxConfiguration: &armhybridcompute.OSProfileLinuxConfiguration{ // PatchSettings: &armhybridcompute.PatchSettings{ // }, // }, // WindowsConfiguration: &armhybridcompute.OSProfileWindowsConfiguration{ // PatchSettings: &armhybridcompute.PatchSettings{ // EnableHotpatching: to.Ptr(true), // Status: &armhybridcompute.PatchSettingsStatus{ // HotpatchEnablementStatus: to.Ptr(armhybridcompute.HotpatchEnablementStatusEnabled), // }, // }, // }, // }, // PrivateLinkScopeResourceID: to.Ptr("/subscriptions/{subscriptionId}/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/privateLinkScopes/privateLinkScopeName"), // ProvisioningState: to.Ptr("Succeeded"), // VMID: to.Ptr("b7a098cc-b0b8-46e8-a205-62f301a62a8f"), // }, // }, // { // Name: to.Ptr("myMachine2"), // Type: to.Ptr("Microsoft.HybridCompute/machines"), // ID: to.Ptr("/subscriptions/{subscriptionId}/resourceGroups/myResourceGroup2/providers/Microsoft.HybridCompute/machines/myMachine2"), // Location: to.Ptr("westus2"), // Identity: &armhybridcompute.Identity{ // Type: to.Ptr("SystemAssigned"), // PrincipalID: to.Ptr("e7a068cc-b0b8-46e8-a203-22f301a62a8f"), // TenantID: to.Ptr("c4098cc-91b8-46c2-a205-d82ab1a62a8f"), // }, // Properties: &armhybridcompute.MachineProperties{ // AgentConfiguration: &armhybridcompute.AgentConfiguration{ // ConfigMode: to.Ptr(armhybridcompute.AgentConfigurationModeFull), // ExtensionsEnabled: to.Ptr("true"), // GuestConfigurationEnabled: to.Ptr("true"), // IncomingConnectionsPorts: []*string{ // to.Ptr("22"), // to.Ptr("23")}, // ProxyBypass: []*string{ // to.Ptr("proxy1"), // to.Ptr("proxy2")}, // ProxyURL: to.Ptr("https://test.test"), // }, // ClientPublicKey: to.Ptr("string"), // DetectedProperties: map[string]*string{ // "cloudprovider": to.Ptr("N/A"), // "manufacturer": to.Ptr("Microsoft Corporation"), // "model": to.Ptr("Surfacebook"), // }, // LicenseProfile: &armhybridcompute.LicenseProfileMachineInstanceView{ // EsuProfile: &armhybridcompute.LicenseProfileMachineInstanceViewEsuProperties{ // EsuKeys: []*armhybridcompute.EsuKey{ // { // LicenseStatus: to.Ptr[int32](1), // SKU: to.Ptr("skuNumber1"), // }, // { // LicenseStatus: to.Ptr[int32](1), // SKU: to.Ptr("skuNumber2"), // }}, // EsuEligibility: to.Ptr(armhybridcompute.EsuEligibilityIneligible), // EsuKeyState: to.Ptr(armhybridcompute.EsuKeyStateInactive), // ServerType: to.Ptr(armhybridcompute.EsuServerTypeStandard), // LicenseAssignmentState: to.Ptr(armhybridcompute.LicenseAssignmentStateAssigned), // }, // LicenseChannel: to.Ptr("PSG"), // LicenseStatus: to.Ptr(armhybridcompute.LicenseStatusLicensed), // ProductProfile: &armhybridcompute.LicenseProfileArmProductProfileProperties{ // BillingEndDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // BillingStartDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // DisenrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // EnrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // ProductFeatures: []*armhybridcompute.ProductFeature{ // { // Name: to.Ptr("Hotpatch"), // BillingEndDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // BillingStartDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // DisenrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // EnrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // SubscriptionStatus: to.Ptr(armhybridcompute.LicenseProfileSubscriptionStatusEnabled), // }}, // ProductType: to.Ptr(armhybridcompute.LicenseProfileProductTypeWindowsServer), // SubscriptionStatus: to.Ptr(armhybridcompute.LicenseProfileSubscriptionStatusEnabled), // }, // SoftwareAssurance: &armhybridcompute.LicenseProfileMachineInstanceViewSoftwareAssurance{ // SoftwareAssuranceCustomer: to.Ptr(true), // }, // }, // LocationData: &armhybridcompute.LocationData{ // Name: to.Ptr("Redmond"), // }, // MssqlDiscovered: to.Ptr("true"), // OSEdition: to.Ptr("Standard"), // OSProfile: &armhybridcompute.OSProfile{ // LinuxConfiguration: &armhybridcompute.OSProfileLinuxConfiguration{ // PatchSettings: &armhybridcompute.PatchSettings{ // }, // }, // WindowsConfiguration: &armhybridcompute.OSProfileWindowsConfiguration{ // PatchSettings: &armhybridcompute.PatchSettings{ // EnableHotpatching: to.Ptr(true), // Status: &armhybridcompute.PatchSettingsStatus{ // HotpatchEnablementStatus: to.Ptr(armhybridcompute.HotpatchEnablementStatusEnabled), // }, // }, // }, // }, // ParentClusterResourceID: to.Ptr("{AzureStackHCIResourceId}"), // ProvisioningState: to.Ptr("Succeeded"), // VMID: to.Ptr("a4a098cc-b0b8-46e8-a205-62f301a62a8f"), // }, // }}, // } }
Output:
func (*MachinesClient) Update ¶
func (client *MachinesClient) Update(ctx context.Context, resourceGroupName string, machineName string, parameters MachineUpdate, options *MachinesClientUpdateOptions) (MachinesClientUpdateResponse, error)
Update - The operation to update a hybrid machine. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group. The name is case insensitive.
- machineName - The name of the hybrid machine.
- parameters - Parameters supplied to the Update hybrid machine operation.
- options - MachinesClientUpdateOptions contains the optional parameters for the MachinesClient.Update method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/machine/Machines_Update.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := clientFactory.NewMachinesClient().Update(ctx, "myResourceGroup", "myMachine", armhybridcompute.MachineUpdate{ Identity: &armhybridcompute.Identity{ Type: to.Ptr("SystemAssigned"), }, Properties: &armhybridcompute.MachineUpdateProperties{ LocationData: &armhybridcompute.LocationData{ Name: to.Ptr("Redmond"), }, OSProfile: &armhybridcompute.OSProfile{ LinuxConfiguration: &armhybridcompute.OSProfileLinuxConfiguration{ PatchSettings: &armhybridcompute.PatchSettings{ AssessmentMode: to.Ptr(armhybridcompute.AssessmentModeTypesImageDefault), PatchMode: to.Ptr(armhybridcompute.PatchModeTypesManual), }, }, WindowsConfiguration: &armhybridcompute.OSProfileWindowsConfiguration{ PatchSettings: &armhybridcompute.PatchSettings{ AssessmentMode: to.Ptr(armhybridcompute.AssessmentModeTypesImageDefault), EnableHotpatching: to.Ptr(true), PatchMode: to.Ptr(armhybridcompute.PatchModeTypesAutomaticByPlatform), }, }, }, ParentClusterResourceID: to.Ptr("{AzureStackHCIResourceId}"), PrivateLinkScopeResourceID: to.Ptr("/subscriptions/{subscriptionId}/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/privateLinkScopes/privateLinkScopeName"), }, }, 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.Machine = armhybridcompute.Machine{ // Name: to.Ptr("myMachine"), // Type: to.Ptr("Microsoft.HybridCompute/machines"), // ID: to.Ptr("/subscriptions/{subscriptionId}/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/machines/myMachine"), // Location: to.Ptr("eastus2euap"), // Identity: &armhybridcompute.Identity{ // Type: to.Ptr("SystemAssigned"), // PrincipalID: to.Ptr("string"), // TenantID: to.Ptr("string"), // }, // Properties: &armhybridcompute.MachineProperties{ // ClientPublicKey: to.Ptr("string"), // LicenseProfile: &armhybridcompute.LicenseProfileMachineInstanceView{ // EsuProfile: &armhybridcompute.LicenseProfileMachineInstanceViewEsuProperties{ // EsuKeys: []*armhybridcompute.EsuKey{ // { // LicenseStatus: to.Ptr[int32](1), // SKU: to.Ptr("skuNumber1"), // }, // { // LicenseStatus: to.Ptr[int32](1), // SKU: to.Ptr("skuNumber2"), // }}, // EsuEligibility: to.Ptr(armhybridcompute.EsuEligibilityIneligible), // EsuKeyState: to.Ptr(armhybridcompute.EsuKeyStateInactive), // ServerType: to.Ptr(armhybridcompute.EsuServerTypeStandard), // LicenseAssignmentState: to.Ptr(armhybridcompute.LicenseAssignmentStateAssigned), // }, // LicenseChannel: to.Ptr("PSG"), // LicenseStatus: to.Ptr(armhybridcompute.LicenseStatusLicensed), // ProductProfile: &armhybridcompute.LicenseProfileArmProductProfileProperties{ // BillingEndDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // BillingStartDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // DisenrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // EnrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // ProductFeatures: []*armhybridcompute.ProductFeature{ // { // Name: to.Ptr("Hotpatch"), // BillingEndDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // BillingStartDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // DisenrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-11-05T20:36:49.745Z"); return t}()), // EnrollmentDate: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-10-05T20:36:49.745Z"); return t}()), // SubscriptionStatus: to.Ptr(armhybridcompute.LicenseProfileSubscriptionStatusEnabled), // }}, // ProductType: to.Ptr(armhybridcompute.LicenseProfileProductTypeWindowsServer), // SubscriptionStatus: to.Ptr(armhybridcompute.LicenseProfileSubscriptionStatusEnabled), // }, // SoftwareAssurance: &armhybridcompute.LicenseProfileMachineInstanceViewSoftwareAssurance{ // SoftwareAssuranceCustomer: to.Ptr(true), // }, // }, // LocationData: &armhybridcompute.LocationData{ // Name: to.Ptr("Redmond"), // }, // OSEdition: to.Ptr("Standard"), // OSProfile: &armhybridcompute.OSProfile{ // LinuxConfiguration: &armhybridcompute.OSProfileLinuxConfiguration{ // PatchSettings: &armhybridcompute.PatchSettings{ // AssessmentMode: to.Ptr(armhybridcompute.AssessmentModeTypesImageDefault), // PatchMode: to.Ptr(armhybridcompute.PatchModeTypesManual), // }, // }, // WindowsConfiguration: &armhybridcompute.OSProfileWindowsConfiguration{ // PatchSettings: &armhybridcompute.PatchSettings{ // AssessmentMode: to.Ptr(armhybridcompute.AssessmentModeTypesImageDefault), // EnableHotpatching: to.Ptr(true), // PatchMode: to.Ptr(armhybridcompute.PatchModeTypesAutomaticByPlatform), // Status: &armhybridcompute.PatchSettingsStatus{ // HotpatchEnablementStatus: to.Ptr(armhybridcompute.HotpatchEnablementStatusPendingEvaluation), // }, // }, // }, // }, // ParentClusterResourceID: to.Ptr("{AzureStackHCIResourceId}"), // PrivateLinkScopeResourceID: to.Ptr("/subscriptions/{subscriptionId}/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/privateLinkScopes/privateLinkScopeName"), // ProvisioningState: to.Ptr("Succeeded"), // VMID: to.Ptr("b7a098cc-b0b8-46e8-a205-62f301a62a8f"), // }, // }
Output:
type MachinesClientAssessPatchesResponse ¶
type MachinesClientAssessPatchesResponse struct { // Describes the properties of an AssessPatches result. MachineAssessPatchesResult }
MachinesClientAssessPatchesResponse contains the response from method MachinesClient.BeginAssessPatches.
type MachinesClientBeginAssessPatchesOptions ¶
type MachinesClientBeginAssessPatchesOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
MachinesClientBeginAssessPatchesOptions contains the optional parameters for the MachinesClient.BeginAssessPatches method.
type MachinesClientBeginInstallPatchesOptions ¶
type MachinesClientBeginInstallPatchesOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
MachinesClientBeginInstallPatchesOptions contains the optional parameters for the MachinesClient.BeginInstallPatches method.
type MachinesClientCreateOrUpdateOptions ¶
type MachinesClientCreateOrUpdateOptions struct { // Expands referenced resources. Expand *string }
MachinesClientCreateOrUpdateOptions contains the optional parameters for the MachinesClient.CreateOrUpdate method.
type MachinesClientCreateOrUpdateResponse ¶
type MachinesClientCreateOrUpdateResponse struct { // Describes a hybrid machine. Machine }
MachinesClientCreateOrUpdateResponse contains the response from method MachinesClient.CreateOrUpdate.
type MachinesClientDeleteOptions ¶
type MachinesClientDeleteOptions struct { }
MachinesClientDeleteOptions contains the optional parameters for the MachinesClient.Delete method.
type MachinesClientDeleteResponse ¶
type MachinesClientDeleteResponse struct { }
MachinesClientDeleteResponse contains the response from method MachinesClient.Delete.
type MachinesClientGetOptions ¶
type MachinesClientGetOptions struct { // The expand expression to apply on the operation. Expand *InstanceViewTypes }
MachinesClientGetOptions contains the optional parameters for the MachinesClient.Get method.
type MachinesClientGetResponse ¶
type MachinesClientGetResponse struct { // Describes a hybrid machine. Machine }
MachinesClientGetResponse contains the response from method MachinesClient.Get.
type MachinesClientInstallPatchesResponse ¶
type MachinesClientInstallPatchesResponse struct { // The result summary of an installation operation. MachineInstallPatchesResult }
MachinesClientInstallPatchesResponse contains the response from method MachinesClient.BeginInstallPatches.
type MachinesClientListByResourceGroupOptions ¶
type MachinesClientListByResourceGroupOptions struct { // Expands referenced resources. Expand *string }
MachinesClientListByResourceGroupOptions contains the optional parameters for the MachinesClient.NewListByResourceGroupPager method.
type MachinesClientListByResourceGroupResponse ¶
type MachinesClientListByResourceGroupResponse struct { // The List hybrid machine operation response. MachineListResult }
MachinesClientListByResourceGroupResponse contains the response from method MachinesClient.NewListByResourceGroupPager.
type MachinesClientListBySubscriptionOptions ¶
type MachinesClientListBySubscriptionOptions struct { }
MachinesClientListBySubscriptionOptions contains the optional parameters for the MachinesClient.NewListBySubscriptionPager method.
type MachinesClientListBySubscriptionResponse ¶
type MachinesClientListBySubscriptionResponse struct { // The List hybrid machine operation response. MachineListResult }
MachinesClientListBySubscriptionResponse contains the response from method MachinesClient.NewListBySubscriptionPager.
type MachinesClientUpdateOptions ¶
type MachinesClientUpdateOptions struct { }
MachinesClientUpdateOptions contains the optional parameters for the MachinesClient.Update method.
type MachinesClientUpdateResponse ¶
type MachinesClientUpdateResponse struct { // Describes a hybrid machine. Machine }
MachinesClientUpdateResponse contains the response from method MachinesClient.Update.
type ManagementClient ¶
type ManagementClient struct {
// contains filtered or unexported fields
}
ManagementClient contains the methods for the HybridComputeManagementClient group. Don't use this type directly, use NewManagementClient() instead.
func NewManagementClient ¶
func NewManagementClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*ManagementClient, error)
NewManagementClient creates a new instance of ManagementClient with the specified values.
- subscriptionID - The ID of the target subscription.
- credential - used to authorize requests. Usually a credential from azidentity.
- options - pass nil to accept the default values.
func (*ManagementClient) BeginUpgradeExtensions ¶
func (client *ManagementClient) BeginUpgradeExtensions(ctx context.Context, resourceGroupName string, machineName string, extensionUpgradeParameters MachineExtensionUpgrade, options *ManagementClientBeginUpgradeExtensionsOptions) (*runtime.Poller[ManagementClientUpgradeExtensionsResponse], error)
BeginUpgradeExtensions - The operation to Upgrade Machine Extensions. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group. The name is case insensitive.
- machineName - The name of the hybrid machine.
- extensionUpgradeParameters - Parameters supplied to the Upgrade Extensions operation.
- options - ManagementClientBeginUpgradeExtensionsOptions contains the optional parameters for the ManagementClient.BeginUpgradeExtensions method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/extension/Extensions_Upgrade.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewManagementClient().BeginUpgradeExtensions(ctx, "myResourceGroup", "myMachine", armhybridcompute.MachineExtensionUpgrade{ ExtensionTargets: map[string]*armhybridcompute.ExtensionTargetProperties{ "Microsoft.Azure.Monitoring": { TargetVersion: to.Ptr("2.0"), }, "Microsoft.Compute.CustomScriptExtension": { TargetVersion: to.Ptr("1.10"), }, }, }, nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) } _, err = poller.PollUntilDone(ctx, nil) if err != nil { log.Fatalf("failed to pull the result: %v", err) }
Output:
type ManagementClientBeginUpgradeExtensionsOptions ¶
type ManagementClientBeginUpgradeExtensionsOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
ManagementClientBeginUpgradeExtensionsOptions contains the optional parameters for the ManagementClient.BeginUpgradeExtensions method.
type ManagementClientUpgradeExtensionsResponse ¶
type ManagementClientUpgradeExtensionsResponse struct { }
ManagementClientUpgradeExtensionsResponse contains the response from method ManagementClient.BeginUpgradeExtensions.
type NetworkInterface ¶
type NetworkInterface struct { // The list of IP addresses in this interface. IPAddresses []*IPAddress }
NetworkInterface - Describes a network interface.
func (NetworkInterface) MarshalJSON ¶
func (n NetworkInterface) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type NetworkInterface.
func (*NetworkInterface) UnmarshalJSON ¶
func (n *NetworkInterface) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type NetworkInterface.
type NetworkProfile ¶
type NetworkProfile struct { // The list of network interfaces. NetworkInterfaces []*NetworkInterface }
NetworkProfile - Describes the network information on this machine.
func (NetworkProfile) MarshalJSON ¶
func (n NetworkProfile) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type NetworkProfile.
func (*NetworkProfile) UnmarshalJSON ¶
func (n *NetworkProfile) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type NetworkProfile.
type NetworkProfileClient ¶
type NetworkProfileClient struct {
// contains filtered or unexported fields
}
NetworkProfileClient contains the methods for the NetworkProfile group. Don't use this type directly, use NewNetworkProfileClient() instead.
func NewNetworkProfileClient ¶
func NewNetworkProfileClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*NetworkProfileClient, error)
NewNetworkProfileClient creates a new instance of NetworkProfileClient with the specified values.
- subscriptionID - The ID of the target subscription.
- credential - used to authorize requests. Usually a credential from azidentity.
- options - pass nil to accept the default values.
func (*NetworkProfileClient) Get ¶
func (client *NetworkProfileClient) Get(ctx context.Context, resourceGroupName string, machineName string, options *NetworkProfileClientGetOptions) (NetworkProfileClientGetResponse, error)
Get - The operation to get network information of hybrid machine If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group. The name is case insensitive.
- machineName - The name of the hybrid machine.
- options - NetworkProfileClientGetOptions contains the optional parameters for the NetworkProfileClient.Get method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/NetworkProfile_Get.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := clientFactory.NewNetworkProfileClient().Get(ctx, "myResourceGroup", "myMachine", 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.NetworkProfile = armhybridcompute.NetworkProfile{ // NetworkInterfaces: []*armhybridcompute.NetworkInterface{ // { // IPAddresses: []*armhybridcompute.IPAddress{ // { // Address: to.Ptr("192.168.12.345"), // IPAddressVersion: to.Ptr("IPv4"), // Subnet: &armhybridcompute.Subnet{ // AddressPrefix: to.Ptr("192.168.12.0/24"), // }, // }}, // }, // { // IPAddresses: []*armhybridcompute.IPAddress{ // { // Address: to.Ptr("1001:0:34aa:5000:1234:aaaa:bbbb:cccc"), // IPAddressVersion: to.Ptr("IPv6"), // Subnet: &armhybridcompute.Subnet{ // AddressPrefix: to.Ptr("1001:0:34aa:5000::/64"), // }, // }}, // }}, // }
Output:
type NetworkProfileClientGetOptions ¶
type NetworkProfileClientGetOptions struct { }
NetworkProfileClientGetOptions contains the optional parameters for the NetworkProfileClient.Get method.
type NetworkProfileClientGetResponse ¶
type NetworkProfileClientGetResponse struct { // Describes the network information on this machine. NetworkProfile }
NetworkProfileClientGetResponse contains the response from method NetworkProfileClient.Get.
type NetworkSecurityPerimeter ¶
type NetworkSecurityPerimeter struct { // READ-ONLY; Azure resource Id ID *string // READ-ONLY; Regional location of the perimeter Location *string // READ-ONLY; Guid of the Network Security Perimeter PerimeterGUID *string }
NetworkSecurityPerimeter - Properties that define a Network Security Perimeter resource.
func (NetworkSecurityPerimeter) MarshalJSON ¶
func (n NetworkSecurityPerimeter) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type NetworkSecurityPerimeter.
func (*NetworkSecurityPerimeter) UnmarshalJSON ¶
func (n *NetworkSecurityPerimeter) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type NetworkSecurityPerimeter.
type NetworkSecurityPerimeterConfiguration ¶
type NetworkSecurityPerimeterConfiguration struct { // Properties that define a Network Security Perimeter resource. Properties *NetworkSecurityPerimeterConfigurationProperties // READ-ONLY; Azure resource Id ID *string // READ-ONLY; Azure resource name Name *string // READ-ONLY; Azure resource type Type *string }
NetworkSecurityPerimeterConfiguration - Properties that define a Network Security Perimeter resource.
func (NetworkSecurityPerimeterConfiguration) MarshalJSON ¶
func (n NetworkSecurityPerimeterConfiguration) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type NetworkSecurityPerimeterConfiguration.
func (*NetworkSecurityPerimeterConfiguration) UnmarshalJSON ¶
func (n *NetworkSecurityPerimeterConfiguration) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type NetworkSecurityPerimeterConfiguration.
type NetworkSecurityPerimeterConfigurationListResult ¶
type NetworkSecurityPerimeterConfigurationListResult struct { // READ-ONLY; Link to retrieve next page of results. NextLink *string // READ-ONLY; Array of results. Value []*NetworkSecurityPerimeterConfiguration }
NetworkSecurityPerimeterConfigurationListResult - A list of network security perimeter configurations.
func (NetworkSecurityPerimeterConfigurationListResult) MarshalJSON ¶
func (n NetworkSecurityPerimeterConfigurationListResult) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type NetworkSecurityPerimeterConfigurationListResult.
func (*NetworkSecurityPerimeterConfigurationListResult) UnmarshalJSON ¶
func (n *NetworkSecurityPerimeterConfigurationListResult) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type NetworkSecurityPerimeterConfigurationListResult.
type NetworkSecurityPerimeterConfigurationProperties ¶
type NetworkSecurityPerimeterConfigurationProperties struct { // The Network Security Perimeter associated with this configuration. NetworkSecurityPerimeter *NetworkSecurityPerimeter // Network Security Perimeter profile Profile *NetworkSecurityPerimeterProfile // The Resource Association. ResourceAssociation *ResourceAssociation // READ-ONLY; Provisioning issues. ProvisioningIssues []*ProvisioningIssue // READ-ONLY; Current state of this NetworkSecurityPerimeter: whether or not is has been provisioned within the resource group // it is defined. Users cannot change this value but are able to read from it. Values will // include Provisioning ,Succeeded, Canceled and Failed. ProvisioningState *string }
NetworkSecurityPerimeterConfigurationProperties - Properties that define a Network Security Perimeter resource.
func (NetworkSecurityPerimeterConfigurationProperties) MarshalJSON ¶
func (n NetworkSecurityPerimeterConfigurationProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type NetworkSecurityPerimeterConfigurationProperties.
func (*NetworkSecurityPerimeterConfigurationProperties) UnmarshalJSON ¶
func (n *NetworkSecurityPerimeterConfigurationProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type NetworkSecurityPerimeterConfigurationProperties.
type NetworkSecurityPerimeterConfigurationReconcileResult ¶
type NetworkSecurityPerimeterConfigurationReconcileResult struct { // The URL of the resource used to check the status of the asynchronous operation. Location *string }
NetworkSecurityPerimeterConfigurationReconcileResult - Result of network security perimeter configurations.
func (NetworkSecurityPerimeterConfigurationReconcileResult) MarshalJSON ¶
func (n NetworkSecurityPerimeterConfigurationReconcileResult) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type NetworkSecurityPerimeterConfigurationReconcileResult.
func (*NetworkSecurityPerimeterConfigurationReconcileResult) UnmarshalJSON ¶
func (n *NetworkSecurityPerimeterConfigurationReconcileResult) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type NetworkSecurityPerimeterConfigurationReconcileResult.
type NetworkSecurityPerimeterConfigurationsClient ¶
type NetworkSecurityPerimeterConfigurationsClient struct {
// contains filtered or unexported fields
}
NetworkSecurityPerimeterConfigurationsClient contains the methods for the NetworkSecurityPerimeterConfigurations group. Don't use this type directly, use NewNetworkSecurityPerimeterConfigurationsClient() instead.
func NewNetworkSecurityPerimeterConfigurationsClient ¶
func NewNetworkSecurityPerimeterConfigurationsClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*NetworkSecurityPerimeterConfigurationsClient, error)
NewNetworkSecurityPerimeterConfigurationsClient creates a new instance of NetworkSecurityPerimeterConfigurationsClient with the specified values.
- subscriptionID - The ID of the target subscription.
- credential - used to authorize requests. Usually a credential from azidentity.
- options - pass nil to accept the default values.
func (*NetworkSecurityPerimeterConfigurationsClient) BeginReconcileForPrivateLinkScope ¶
func (client *NetworkSecurityPerimeterConfigurationsClient) BeginReconcileForPrivateLinkScope(ctx context.Context, resourceGroupName string, scopeName string, perimeterName string, options *NetworkSecurityPerimeterConfigurationsClientBeginReconcileForPrivateLinkScopeOptions) (*runtime.Poller[NetworkSecurityPerimeterConfigurationsClientReconcileForPrivateLinkScopeResponse], error)
BeginReconcileForPrivateLinkScope - Forces the network security perimeter configuration to refresh for a private link scope. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group. The name is case insensitive.
- scopeName - The name of the Azure Arc PrivateLinkScope resource.
- perimeterName - The name, in the format {perimeterGuid}.{associationName}, of the Network Security Perimeter resource.
- options - NetworkSecurityPerimeterConfigurationsClientBeginReconcileForPrivateLinkScopeOptions contains the optional parameters for the NetworkSecurityPerimeterConfigurationsClient.BeginReconcileForPrivateLinkScope method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/networkSecurityPerimeterConfiguration/NetworkSecurityPerimeterConfigurationReconcile.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewNetworkSecurityPerimeterConfigurationsClient().BeginReconcileForPrivateLinkScope(ctx, "my-resource-group", "my-privatelinkscope", "aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee.myAssociation", nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) } res, err := poller.PollUntilDone(ctx, nil) if err != nil { log.Fatalf("failed to pull the result: %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.NetworkSecurityPerimeterConfigurationReconcileResult = armhybridcompute.NetworkSecurityPerimeterConfigurationReconcileResult{ // Location: to.Ptr("{callbackUrl}"), // }
Output:
func (*NetworkSecurityPerimeterConfigurationsClient) GetByPrivateLinkScope ¶
func (client *NetworkSecurityPerimeterConfigurationsClient) GetByPrivateLinkScope(ctx context.Context, resourceGroupName string, scopeName string, perimeterName string, options *NetworkSecurityPerimeterConfigurationsClientGetByPrivateLinkScopeOptions) (NetworkSecurityPerimeterConfigurationsClientGetByPrivateLinkScopeResponse, error)
GetByPrivateLinkScope - Gets the network security perimeter configuration for a private link scope. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group. The name is case insensitive.
- scopeName - The name of the Azure Arc PrivateLinkScope resource.
- perimeterName - The name, in the format {perimeterGuid}.{associationName}, of the Network Security Perimeter resource.
- options - NetworkSecurityPerimeterConfigurationsClientGetByPrivateLinkScopeOptions contains the optional parameters for the NetworkSecurityPerimeterConfigurationsClient.GetByPrivateLinkScope method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/networkSecurityPerimeterConfiguration/NetworkSecurityPerimeterConfigurationGet.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := clientFactory.NewNetworkSecurityPerimeterConfigurationsClient().GetByPrivateLinkScope(ctx, "my-resource-group", "my-privatelinkscope", "aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee.myAssociation", 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.NetworkSecurityPerimeterConfiguration = armhybridcompute.NetworkSecurityPerimeterConfiguration{ // Name: to.Ptr("aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee.myAssociation"), // Type: to.Ptr("Microsoft.HybridCompute/privateLinkScopes/networkSecurityPerimeterConfigurations"), // ID: to.Ptr("/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/my-resource-group/providers/Microsoft.HybridCompute/privateLinkScopes/my-privatelinkscope/networkSecurityPerimeterConfigurations/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee.myAssociation"), // Properties: &armhybridcompute.NetworkSecurityPerimeterConfigurationProperties{ // NetworkSecurityPerimeter: &armhybridcompute.NetworkSecurityPerimeter{ // ID: to.Ptr("/subscriptions/55555555-6666-7777-8888-999999999999/resourceGroups/Default-Network/providers/Microsoft.Network/networkSecurityPerimeters/myPerimeter"), // Location: to.Ptr("westus"), // PerimeterGUID: to.Ptr("aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee"), // }, // Profile: &armhybridcompute.NetworkSecurityPerimeterProfile{ // Name: to.Ptr("myProfile"), // AccessRules: []*armhybridcompute.AccessRule{ // { // Name: to.Ptr("myAccessRule"), // Properties: &armhybridcompute.AccessRuleProperties{ // AddressPrefixes: []*string{ // to.Ptr("148.0.0.0/8"), // to.Ptr("152.4.6.0/24"), // to.Ptr("...")}, // Direction: to.Ptr(armhybridcompute.AccessRuleDirectionInbound), // }, // }}, // AccessRulesVersion: to.Ptr[int32](1), // DiagnosticSettingsVersion: to.Ptr[int32](1), // EnabledLogCategories: []*string{ // }, // }, // ProvisioningIssues: []*armhybridcompute.ProvisioningIssue{ // }, // ProvisioningState: to.Ptr("Succeeded"), // ResourceAssociation: &armhybridcompute.ResourceAssociation{ // Name: to.Ptr("myAssociation"), // AccessMode: to.Ptr(armhybridcompute.AccessModeEnforced), // }, // }, // }
Output:
func (*NetworkSecurityPerimeterConfigurationsClient) NewListByPrivateLinkScopePager ¶
func (client *NetworkSecurityPerimeterConfigurationsClient) NewListByPrivateLinkScopePager(resourceGroupName string, scopeName string, options *NetworkSecurityPerimeterConfigurationsClientListByPrivateLinkScopeOptions) *runtime.Pager[NetworkSecurityPerimeterConfigurationsClientListByPrivateLinkScopeResponse]
NewListByPrivateLinkScopePager - Lists the network security perimeter configurations for a private link scope.
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group. The name is case insensitive.
- scopeName - The name of the Azure Arc PrivateLinkScope resource.
- options - NetworkSecurityPerimeterConfigurationsClientListByPrivateLinkScopeOptions contains the optional parameters for the NetworkSecurityPerimeterConfigurationsClient.NewListByPrivateLinkScopePager method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/networkSecurityPerimeterConfiguration/NetworkSecurityPerimeterConfigurationList.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } pager := clientFactory.NewNetworkSecurityPerimeterConfigurationsClient().NewListByPrivateLinkScopePager("my-resource-group", "my-privatelinkscope", 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.NetworkSecurityPerimeterConfigurationListResult = armhybridcompute.NetworkSecurityPerimeterConfigurationListResult{ // Value: []*armhybridcompute.NetworkSecurityPerimeterConfiguration{ // { // Name: to.Ptr("aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee.myAssociation"), // Type: to.Ptr("Microsoft.HybridCompute/privateLinkScopes/networkSecurityPerimeterConfigurations"), // ID: to.Ptr("/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/my-resource-group/providers/Microsoft.HybridCompute/privateLinkScopes/my-privatelinkscope/networkSecurityPerimeterConfigurations/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee.myAssociation"), // Properties: &armhybridcompute.NetworkSecurityPerimeterConfigurationProperties{ // NetworkSecurityPerimeter: &armhybridcompute.NetworkSecurityPerimeter{ // ID: to.Ptr("/subscriptions/55555555-6666-7777-8888-999999999999/resourceGroups/Default-Network/providers/Microsoft.Network/networkSecurityPerimeters/myPerimeter"), // Location: to.Ptr("westus"), // PerimeterGUID: to.Ptr("aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee"), // }, // Profile: &armhybridcompute.NetworkSecurityPerimeterProfile{ // Name: to.Ptr("myProfile"), // AccessRules: []*armhybridcompute.AccessRule{ // { // Name: to.Ptr("myAccessRule"), // Properties: &armhybridcompute.AccessRuleProperties{ // AddressPrefixes: []*string{ // to.Ptr("148.0.0.0/8"), // to.Ptr("152.4.6.0/24"), // to.Ptr("...")}, // Direction: to.Ptr(armhybridcompute.AccessRuleDirectionInbound), // }, // }}, // AccessRulesVersion: to.Ptr[int32](1), // DiagnosticSettingsVersion: to.Ptr[int32](1), // EnabledLogCategories: []*string{ // }, // }, // ProvisioningIssues: []*armhybridcompute.ProvisioningIssue{ // }, // ProvisioningState: to.Ptr("Succeeded"), // ResourceAssociation: &armhybridcompute.ResourceAssociation{ // Name: to.Ptr("myAssociation"), // AccessMode: to.Ptr(armhybridcompute.AccessModeEnforced), // }, // }, // }, // { // Name: to.Ptr("aaaaaaaa-0000-cccc-1111-eeeeeeeeeeee.myAssociation2"), // Type: to.Ptr("Microsoft.HybridCompute/privateLinkScopes/networkSecurityPerimeterConfigurations"), // ID: to.Ptr("/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/my-resource-group/providers/Microsoft.HybridCompute/privateLinkScopes/my-privatelinkscope/networkSecurityPerimeterConfigurations/37364608-77ea-4c2a-bdc3-4b0b1cdfab15.myAssociation2"), // Properties: &armhybridcompute.NetworkSecurityPerimeterConfigurationProperties{ // NetworkSecurityPerimeter: &armhybridcompute.NetworkSecurityPerimeter{ // ID: to.Ptr("/subscriptions/55555555-6666-7777-8888-999999999999/resourceGroups/Default-Network/providers/Microsoft.Network/networkSecurityPerimeters/myOtherPerimeter"), // Location: to.Ptr("westus"), // PerimeterGUID: to.Ptr("aaaaaaaa-0000-cccc-1111-eeeeeeeeeeee"), // }, // Profile: &armhybridcompute.NetworkSecurityPerimeterProfile{ // Name: to.Ptr("myProfile"), // AccessRules: []*armhybridcompute.AccessRule{ // { // Name: to.Ptr("myAccessRule"), // Properties: &armhybridcompute.AccessRuleProperties{ // AddressPrefixes: []*string{ // to.Ptr("122.0.0.0/8"), // to.Ptr("144.4.6.0/24"), // to.Ptr("...")}, // Direction: to.Ptr(armhybridcompute.AccessRuleDirectionInbound), // }, // }}, // AccessRulesVersion: to.Ptr[int32](1), // DiagnosticSettingsVersion: to.Ptr[int32](1), // EnabledLogCategories: []*string{ // }, // }, // ProvisioningIssues: []*armhybridcompute.ProvisioningIssue{ // }, // ProvisioningState: to.Ptr("Succeeded"), // ResourceAssociation: &armhybridcompute.ResourceAssociation{ // Name: to.Ptr("myAssociation"), // AccessMode: to.Ptr(armhybridcompute.AccessModeLearning), // }, // }, // }}, // } }
Output:
type NetworkSecurityPerimeterConfigurationsClientBeginReconcileForPrivateLinkScopeOptions ¶
type NetworkSecurityPerimeterConfigurationsClientBeginReconcileForPrivateLinkScopeOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
NetworkSecurityPerimeterConfigurationsClientBeginReconcileForPrivateLinkScopeOptions contains the optional parameters for the NetworkSecurityPerimeterConfigurationsClient.BeginReconcileForPrivateLinkScope method.
type NetworkSecurityPerimeterConfigurationsClientGetByPrivateLinkScopeOptions ¶
type NetworkSecurityPerimeterConfigurationsClientGetByPrivateLinkScopeOptions struct { }
NetworkSecurityPerimeterConfigurationsClientGetByPrivateLinkScopeOptions contains the optional parameters for the NetworkSecurityPerimeterConfigurationsClient.GetByPrivateLinkScope method.
type NetworkSecurityPerimeterConfigurationsClientGetByPrivateLinkScopeResponse ¶
type NetworkSecurityPerimeterConfigurationsClientGetByPrivateLinkScopeResponse struct { // Properties that define a Network Security Perimeter resource. NetworkSecurityPerimeterConfiguration }
NetworkSecurityPerimeterConfigurationsClientGetByPrivateLinkScopeResponse contains the response from method NetworkSecurityPerimeterConfigurationsClient.GetByPrivateLinkScope.
type NetworkSecurityPerimeterConfigurationsClientListByPrivateLinkScopeOptions ¶
type NetworkSecurityPerimeterConfigurationsClientListByPrivateLinkScopeOptions struct { }
NetworkSecurityPerimeterConfigurationsClientListByPrivateLinkScopeOptions contains the optional parameters for the NetworkSecurityPerimeterConfigurationsClient.NewListByPrivateLinkScopePager method.
type NetworkSecurityPerimeterConfigurationsClientListByPrivateLinkScopeResponse ¶
type NetworkSecurityPerimeterConfigurationsClientListByPrivateLinkScopeResponse struct { // A list of network security perimeter configurations. NetworkSecurityPerimeterConfigurationListResult }
NetworkSecurityPerimeterConfigurationsClientListByPrivateLinkScopeResponse contains the response from method NetworkSecurityPerimeterConfigurationsClient.NewListByPrivateLinkScopePager.
type NetworkSecurityPerimeterConfigurationsClientReconcileForPrivateLinkScopeResponse ¶
type NetworkSecurityPerimeterConfigurationsClientReconcileForPrivateLinkScopeResponse struct { // Result of network security perimeter configurations. NetworkSecurityPerimeterConfigurationReconcileResult }
NetworkSecurityPerimeterConfigurationsClientReconcileForPrivateLinkScopeResponse contains the response from method NetworkSecurityPerimeterConfigurationsClient.BeginReconcileForPrivateLinkScope.
type NetworkSecurityPerimeterProfile ¶
type NetworkSecurityPerimeterProfile struct { // READ-ONLY; Collection of access rules for the profile AccessRules []*AccessRule // READ-ONLY; Access rules version number AccessRulesVersion *int32 // READ-ONLY; Diagnostic settings version number DiagnosticSettingsVersion *int32 // READ-ONLY; Collection of enabled log categories for the profile EnabledLogCategories []*string // READ-ONLY; Name of the resource Name *string }
NetworkSecurityPerimeterProfile - Network Security Perimeter profile
func (NetworkSecurityPerimeterProfile) MarshalJSON ¶
func (n NetworkSecurityPerimeterProfile) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type NetworkSecurityPerimeterProfile.
func (*NetworkSecurityPerimeterProfile) UnmarshalJSON ¶
func (n *NetworkSecurityPerimeterProfile) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type NetworkSecurityPerimeterProfile.
type OSProfile ¶
type OSProfile struct { // Specifies the linux configuration for update management. LinuxConfiguration *OSProfileLinuxConfiguration // Specifies the windows configuration for update management. WindowsConfiguration *OSProfileWindowsConfiguration // READ-ONLY; Specifies the host OS name of the hybrid machine. ComputerName *string }
OSProfile - Specifies the operating system settings for the hybrid machine.
func (OSProfile) MarshalJSON ¶
MarshalJSON implements the json.Marshaller interface for type OSProfile.
func (*OSProfile) UnmarshalJSON ¶
UnmarshalJSON implements the json.Unmarshaller interface for type OSProfile.
type OSProfileLinuxConfiguration ¶
type OSProfileLinuxConfiguration struct { // Specifies the patch settings. PatchSettings *PatchSettings }
OSProfileLinuxConfiguration - Specifies the linux configuration for update management.
func (OSProfileLinuxConfiguration) MarshalJSON ¶
func (o OSProfileLinuxConfiguration) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type OSProfileLinuxConfiguration.
func (*OSProfileLinuxConfiguration) UnmarshalJSON ¶
func (o *OSProfileLinuxConfiguration) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type OSProfileLinuxConfiguration.
type OSProfileWindowsConfiguration ¶
type OSProfileWindowsConfiguration struct { // Specifies the patch settings. PatchSettings *PatchSettings }
OSProfileWindowsConfiguration - Specifies the windows configuration for update management.
func (OSProfileWindowsConfiguration) MarshalJSON ¶
func (o OSProfileWindowsConfiguration) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type OSProfileWindowsConfiguration.
func (*OSProfileWindowsConfiguration) UnmarshalJSON ¶
func (o *OSProfileWindowsConfiguration) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type OSProfileWindowsConfiguration.
type OperationListResult ¶
type OperationListResult struct { // READ-ONLY; The list of compute operations Value []*OperationValue }
OperationListResult - The List Compute Operation operation response.
func (OperationListResult) MarshalJSON ¶
func (o OperationListResult) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type OperationListResult.
func (*OperationListResult) UnmarshalJSON ¶
func (o *OperationListResult) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type OperationListResult.
type OperationValue ¶
type OperationValue struct { // Display properties Display *OperationValueDisplay // READ-ONLY; This property indicates if the operation is an action or a data action IsDataAction *bool // READ-ONLY; The name of the compute operation. Name *string // READ-ONLY; The origin of the compute operation. Origin *string }
OperationValue - Describes the properties of a Compute Operation value.
func (OperationValue) MarshalJSON ¶
func (o OperationValue) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type OperationValue.
func (*OperationValue) UnmarshalJSON ¶
func (o *OperationValue) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type OperationValue.
type OperationValueDisplay ¶
type OperationValueDisplay struct { // READ-ONLY; The description of the operation. Description *string // READ-ONLY; The display name of the compute operation. Operation *string // READ-ONLY; The resource provider for the operation. Provider *string // READ-ONLY; The display name of the resource the operation applies to. Resource *string }
OperationValueDisplay - Describes the properties of a Hybrid Compute Operation Value Display.
func (OperationValueDisplay) MarshalJSON ¶
func (o OperationValueDisplay) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type OperationValueDisplay.
func (*OperationValueDisplay) UnmarshalJSON ¶
func (o *OperationValueDisplay) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type OperationValueDisplay.
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 - Gets a list of hybrid compute operations.
Generated from API version 2024-07-10
- 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/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/Operations_List.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.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.OperationListResult = armhybridcompute.OperationListResult{ // Value: []*armhybridcompute.OperationValue{ // { // Name: to.Ptr("Microsoft.HybridCompute/operations/read"), // Display: &armhybridcompute.OperationValueDisplay{ // Description: to.Ptr("Read all Operations for Azure Arc for Servers"), // Operation: to.Ptr("Read all Operations"), // Provider: to.Ptr("Microsoft HybridCompute"), // Resource: to.Ptr("Microsoft.HybridCompute Resource Provider"), // }, // IsDataAction: to.Ptr(true), // Origin: to.Ptr("user,system"), // }, // { // Name: to.Ptr("Microsoft.HybridCompute/register/action"), // Display: &armhybridcompute.OperationValueDisplay{ // Description: to.Ptr("Registers the subscription for the Microsoft.HybridCompute Resource Provider"), // Operation: to.Ptr("Register Subscription for Azure Arc for Servers"), // Provider: to.Ptr("Microsoft HybridCompute"), // Resource: to.Ptr("Microsoft.HybridCompute Resource Provider"), // }, // IsDataAction: to.Ptr(true), // Origin: to.Ptr("user,system"), // }}, // } }
Output:
type OperationsClientListOptions ¶
type OperationsClientListOptions struct { }
OperationsClientListOptions contains the optional parameters for the OperationsClient.NewListPager method.
type OperationsClientListResponse ¶
type OperationsClientListResponse struct { // The List Compute Operation operation response. OperationListResult }
OperationsClientListResponse contains the response from method OperationsClient.NewListPager.
type OsType ¶
type OsType string
OsType - The operating system type of the machine.
func PossibleOsTypeValues ¶
func PossibleOsTypeValues() []OsType
PossibleOsTypeValues returns the possible values for the OsType const type.
type PatchModeTypes ¶
type PatchModeTypes string
PatchModeTypes - Specifies the patch mode.
const ( PatchModeTypesAutomaticByOS PatchModeTypes = "AutomaticByOS" PatchModeTypesAutomaticByPlatform PatchModeTypes = "AutomaticByPlatform" PatchModeTypesImageDefault PatchModeTypes = "ImageDefault" PatchModeTypesManual PatchModeTypes = "Manual" )
func PossiblePatchModeTypesValues ¶
func PossiblePatchModeTypesValues() []PatchModeTypes
PossiblePatchModeTypesValues returns the possible values for the PatchModeTypes const type.
type PatchOperationStartedBy ¶
type PatchOperationStartedBy string
PatchOperationStartedBy - Indicates if operation was triggered by user or by platform.
const ( PatchOperationStartedByPlatform PatchOperationStartedBy = "Platform" PatchOperationStartedByUser PatchOperationStartedBy = "User" )
func PossiblePatchOperationStartedByValues ¶
func PossiblePatchOperationStartedByValues() []PatchOperationStartedBy
PossiblePatchOperationStartedByValues returns the possible values for the PatchOperationStartedBy const type.
type PatchOperationStatus ¶
type PatchOperationStatus string
PatchOperationStatus - The overall success or failure status of the operation. It remains "InProgress" until the operation completes. At that point it will become "Unknown", "Failed", "Succeeded", or "CompletedWithWarnings."
const ( PatchOperationStatusCompletedWithWarnings PatchOperationStatus = "CompletedWithWarnings" PatchOperationStatusFailed PatchOperationStatus = "Failed" PatchOperationStatusInProgress PatchOperationStatus = "InProgress" PatchOperationStatusSucceeded PatchOperationStatus = "Succeeded" PatchOperationStatusUnknown PatchOperationStatus = "Unknown" )
func PossiblePatchOperationStatusValues ¶
func PossiblePatchOperationStatusValues() []PatchOperationStatus
PossiblePatchOperationStatusValues returns the possible values for the PatchOperationStatus const type.
type PatchServiceUsed ¶
type PatchServiceUsed string
PatchServiceUsed - Specifies the patch service used for the operation.
const ( PatchServiceUsedAPT PatchServiceUsed = "APT" PatchServiceUsedUnknown PatchServiceUsed = "Unknown" PatchServiceUsedWU PatchServiceUsed = "WU" PatchServiceUsedWUWSUS PatchServiceUsed = "WU_WSUS" PatchServiceUsedYUM PatchServiceUsed = "YUM" PatchServiceUsedZypper PatchServiceUsed = "Zypper" )
func PossiblePatchServiceUsedValues ¶
func PossiblePatchServiceUsedValues() []PatchServiceUsed
PossiblePatchServiceUsedValues returns the possible values for the PatchServiceUsed const type.
type PatchSettings ¶
type PatchSettings struct { // Specifies the assessment mode. AssessmentMode *AssessmentModeTypes // Captures the hotpatch capability enrollment intent of the customers, which enables customers to patch their Windows machines // without requiring a reboot. EnableHotpatching *bool // Specifies the patch mode. PatchMode *PatchModeTypes // READ-ONLY; Status of the hotpatch capability enrollment or disenrollment. Status *PatchSettingsStatus }
PatchSettings - Specifies the patch settings.
func (PatchSettings) MarshalJSON ¶
func (p PatchSettings) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type PatchSettings.
func (*PatchSettings) UnmarshalJSON ¶
func (p *PatchSettings) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type PatchSettings.
type PatchSettingsStatus ¶
type PatchSettingsStatus struct { // Indicates the current status of the hotpatch being enabled or disabled. HotpatchEnablementStatus *HotpatchEnablementStatus // READ-ONLY; The errors that were encountered during the hotpatch capability enrollment or disenrollment. Error *ErrorDetail }
PatchSettingsStatus - Status of the hotpatch capability enrollment or disenrollment.
func (PatchSettingsStatus) MarshalJSON ¶
func (p PatchSettingsStatus) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type PatchSettingsStatus.
func (*PatchSettingsStatus) UnmarshalJSON ¶
func (p *PatchSettingsStatus) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type PatchSettingsStatus.
type PrivateEndpointConnection ¶
type PrivateEndpointConnection struct { // Resource properties. Properties *PrivateEndpointConnectionProperties // READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string // READ-ONLY; The name of the resource Name *string // READ-ONLY; Azure Resource Manager metadata containing createdBy and modifiedBy information. SystemData *SystemData // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string }
PrivateEndpointConnection - A private endpoint connection
func (PrivateEndpointConnection) MarshalJSON ¶
func (p PrivateEndpointConnection) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type PrivateEndpointConnection.
func (*PrivateEndpointConnection) UnmarshalJSON ¶
func (p *PrivateEndpointConnection) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type PrivateEndpointConnection.
type PrivateEndpointConnectionDataModel ¶
type PrivateEndpointConnectionDataModel struct { // The Private Endpoint Connection properties. Properties *PrivateEndpointConnectionProperties // READ-ONLY; The ARM Resource Id of the Private Endpoint. ID *string // READ-ONLY; The Name of the Private Endpoint. Name *string // READ-ONLY; Azure resource type Type *string }
PrivateEndpointConnectionDataModel - The Data Model for a Private Endpoint Connection associated with a Private Link Scope
func (PrivateEndpointConnectionDataModel) MarshalJSON ¶
func (p PrivateEndpointConnectionDataModel) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type PrivateEndpointConnectionDataModel.
func (*PrivateEndpointConnectionDataModel) UnmarshalJSON ¶
func (p *PrivateEndpointConnectionDataModel) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type PrivateEndpointConnectionDataModel.
type PrivateEndpointConnectionListResult ¶
type PrivateEndpointConnectionListResult struct { // READ-ONLY; Link to retrieve next page of results. NextLink *string // READ-ONLY; Array of results. Value []*PrivateEndpointConnection }
PrivateEndpointConnectionListResult - A list of private endpoint connections.
func (PrivateEndpointConnectionListResult) MarshalJSON ¶
func (p PrivateEndpointConnectionListResult) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type PrivateEndpointConnectionListResult.
func (*PrivateEndpointConnectionListResult) UnmarshalJSON ¶
func (p *PrivateEndpointConnectionListResult) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type PrivateEndpointConnectionListResult.
type PrivateEndpointConnectionProperties ¶
type PrivateEndpointConnectionProperties struct { // Private endpoint which the connection belongs to. PrivateEndpoint *PrivateEndpointProperty // Connection state of the private endpoint connection. PrivateLinkServiceConnectionState *PrivateLinkServiceConnectionStateProperty // READ-ONLY; List of group IDs. GroupIDs []*string // READ-ONLY; State of the private endpoint connection. ProvisioningState *string }
PrivateEndpointConnectionProperties - Properties of a private endpoint connection.
func (PrivateEndpointConnectionProperties) MarshalJSON ¶
func (p PrivateEndpointConnectionProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type PrivateEndpointConnectionProperties.
func (*PrivateEndpointConnectionProperties) UnmarshalJSON ¶
func (p *PrivateEndpointConnectionProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type PrivateEndpointConnectionProperties.
type PrivateEndpointConnectionsClient ¶
type PrivateEndpointConnectionsClient struct {
// contains filtered or unexported fields
}
PrivateEndpointConnectionsClient contains the methods for the PrivateEndpointConnections group. Don't use this type directly, use NewPrivateEndpointConnectionsClient() instead.
func NewPrivateEndpointConnectionsClient ¶
func NewPrivateEndpointConnectionsClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*PrivateEndpointConnectionsClient, error)
NewPrivateEndpointConnectionsClient creates a new instance of PrivateEndpointConnectionsClient with the specified values.
- subscriptionID - The ID of the target subscription.
- credential - used to authorize requests. Usually a credential from azidentity.
- options - pass nil to accept the default values.
func (*PrivateEndpointConnectionsClient) BeginCreateOrUpdate ¶
func (client *PrivateEndpointConnectionsClient) BeginCreateOrUpdate(ctx context.Context, resourceGroupName string, scopeName string, privateEndpointConnectionName string, parameters PrivateEndpointConnection, options *PrivateEndpointConnectionsClientBeginCreateOrUpdateOptions) (*runtime.Poller[PrivateEndpointConnectionsClientCreateOrUpdateResponse], error)
BeginCreateOrUpdate - Approve or reject a private endpoint connection with a given name. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group. The name is case insensitive.
- scopeName - The name of the Azure Arc PrivateLinkScope resource.
- privateEndpointConnectionName - The name of the private endpoint connection.
- options - PrivateEndpointConnectionsClientBeginCreateOrUpdateOptions contains the optional parameters for the PrivateEndpointConnectionsClient.BeginCreateOrUpdate method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/privateEndpoint/PrivateEndpointConnection_Update.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewPrivateEndpointConnectionsClient().BeginCreateOrUpdate(ctx, "myResourceGroup", "myPrivateLinkScope", "private-endpoint-connection-name", armhybridcompute.PrivateEndpointConnection{ Properties: &armhybridcompute.PrivateEndpointConnectionProperties{ PrivateLinkServiceConnectionState: &armhybridcompute.PrivateLinkServiceConnectionStateProperty{ Description: to.Ptr("Approved by johndoe@contoso.com"), Status: to.Ptr("Approved"), }, }, }, nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) } res, err := poller.PollUntilDone(ctx, nil) if err != nil { log.Fatalf("failed to pull the result: %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.PrivateEndpointConnection = armhybridcompute.PrivateEndpointConnection{ // Name: to.Ptr("private-endpoint-connection-name"), // Type: to.Ptr("Microsoft.HybridCompute/privateLinkScopes/privateEndpointConnections"), // ID: to.Ptr("/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/privateLinkScopes/myPrivateLinkScope/privateEndpointConnections/private-endpoint-connection-name"), // Properties: &armhybridcompute.PrivateEndpointConnectionProperties{ // GroupIDs: []*string{ // to.Ptr("hybridcompute")}, // PrivateEndpoint: &armhybridcompute.PrivateEndpointProperty{ // ID: to.Ptr("/subscriptions/55555555-6666-7777-8888-999999999999/resourceGroups/Default-Network/providers/Microsoft.Network/privateEndpoints/private-endpoint-name"), // }, // PrivateLinkServiceConnectionState: &armhybridcompute.PrivateLinkServiceConnectionStateProperty{ // Description: to.Ptr("Approved by johndoe@contoso.com"), // ActionsRequired: to.Ptr("None"), // Status: to.Ptr("Approved"), // }, // ProvisioningState: to.Ptr("Succeeded"), // }, // }
Output:
func (*PrivateEndpointConnectionsClient) BeginDelete ¶
func (client *PrivateEndpointConnectionsClient) BeginDelete(ctx context.Context, resourceGroupName string, scopeName string, privateEndpointConnectionName string, options *PrivateEndpointConnectionsClientBeginDeleteOptions) (*runtime.Poller[PrivateEndpointConnectionsClientDeleteResponse], error)
BeginDelete - Deletes a private endpoint connection with a given name. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group. The name is case insensitive.
- scopeName - The name of the Azure Arc PrivateLinkScope resource.
- privateEndpointConnectionName - The name of the private endpoint connection.
- options - PrivateEndpointConnectionsClientBeginDeleteOptions contains the optional parameters for the PrivateEndpointConnectionsClient.BeginDelete method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/privateEndpoint/PrivateEndpointConnection_Delete.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewPrivateEndpointConnectionsClient().BeginDelete(ctx, "myResourceGroup", "myPrivateLinkScope", "private-endpoint-connection-name", nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) } _, err = poller.PollUntilDone(ctx, nil) if err != nil { log.Fatalf("failed to pull the result: %v", err) }
Output:
func (*PrivateEndpointConnectionsClient) Get ¶
func (client *PrivateEndpointConnectionsClient) Get(ctx context.Context, resourceGroupName string, scopeName string, privateEndpointConnectionName string, options *PrivateEndpointConnectionsClientGetOptions) (PrivateEndpointConnectionsClientGetResponse, error)
Get - Gets a private endpoint connection. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group. The name is case insensitive.
- scopeName - The name of the Azure Arc PrivateLinkScope resource.
- privateEndpointConnectionName - The name of the private endpoint connection.
- options - PrivateEndpointConnectionsClientGetOptions contains the optional parameters for the PrivateEndpointConnectionsClient.Get method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/privateEndpoint/PrivateEndpointConnection_Get.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := clientFactory.NewPrivateEndpointConnectionsClient().Get(ctx, "myResourceGroup", "myPrivateLinkScope", "private-endpoint-connection-name", 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.PrivateEndpointConnection = armhybridcompute.PrivateEndpointConnection{ // Name: to.Ptr("private-endpoint-connection-name"), // Type: to.Ptr("Microsoft.HybridCompute/privateLinkScopes/privateEndpointConnections"), // ID: to.Ptr("/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/privateLinkScopes/myPrivateLinkScope/privateEndpointConnections/private-endpoint-connection-name"), // Properties: &armhybridcompute.PrivateEndpointConnectionProperties{ // GroupIDs: []*string{ // to.Ptr("hybridcompute")}, // PrivateEndpoint: &armhybridcompute.PrivateEndpointProperty{ // ID: to.Ptr("/subscriptions/55555555-6666-7777-8888-999999999999/resourceGroups/Default-Network/providers/Microsoft.Network/privateEndpoints/private-endpoint-name"), // }, // PrivateLinkServiceConnectionState: &armhybridcompute.PrivateLinkServiceConnectionStateProperty{ // Description: to.Ptr("Auto-approved"), // ActionsRequired: to.Ptr("None"), // Status: to.Ptr("Approved"), // }, // ProvisioningState: to.Ptr("Succeeded"), // }, // }
Output:
func (*PrivateEndpointConnectionsClient) NewListByPrivateLinkScopePager ¶
func (client *PrivateEndpointConnectionsClient) NewListByPrivateLinkScopePager(resourceGroupName string, scopeName string, options *PrivateEndpointConnectionsClientListByPrivateLinkScopeOptions) *runtime.Pager[PrivateEndpointConnectionsClientListByPrivateLinkScopeResponse]
NewListByPrivateLinkScopePager - Gets all private endpoint connections on a private link scope.
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group. The name is case insensitive.
- scopeName - The name of the Azure Arc PrivateLinkScope resource.
- options - PrivateEndpointConnectionsClientListByPrivateLinkScopeOptions contains the optional parameters for the PrivateEndpointConnectionsClient.NewListByPrivateLinkScopePager method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/privateEndpoint/PrivateEndpointConnection_List.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } pager := clientFactory.NewPrivateEndpointConnectionsClient().NewListByPrivateLinkScopePager("myResourceGroup", "myPrivateLinkScope", 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.PrivateEndpointConnectionListResult = armhybridcompute.PrivateEndpointConnectionListResult{ // Value: []*armhybridcompute.PrivateEndpointConnection{ // { // Name: to.Ptr("private-endpoint-connection-name"), // Type: to.Ptr("Microsoft.HybridCompute/privateLinkScopes/privateEndpointConnections"), // ID: to.Ptr("/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/privateLinkScopes/myPrivateLinkScope/privateEndpointConnections/private-endpoint-connection-name-2"), // Properties: &armhybridcompute.PrivateEndpointConnectionProperties{ // GroupIDs: []*string{ // to.Ptr("hybridcompute")}, // PrivateEndpoint: &armhybridcompute.PrivateEndpointProperty{ // ID: to.Ptr("/subscriptions/55555555-6666-7777-8888-999999999999/resourceGroups/Default-Network/providers/Microsoft.Network/privateEndpoints/private-endpoint-name"), // }, // PrivateLinkServiceConnectionState: &armhybridcompute.PrivateLinkServiceConnectionStateProperty{ // Description: to.Ptr("Auto-approved"), // ActionsRequired: to.Ptr("None"), // Status: to.Ptr("Approved"), // }, // ProvisioningState: to.Ptr("Succeeded"), // }, // }, // { // Name: to.Ptr("private-endpoint-connection-name-2"), // Type: to.Ptr("Microsoft.HybridCompute/privateLinkScopes/privateEndpointConnections"), // ID: to.Ptr("/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/privateLinkScopes/myPrivateLinkScope/privateEndpointConnections/private-endpoint-connection-name-2"), // Properties: &armhybridcompute.PrivateEndpointConnectionProperties{ // GroupIDs: []*string{ // to.Ptr("hybridcompute")}, // PrivateEndpoint: &armhybridcompute.PrivateEndpointProperty{ // ID: to.Ptr("/subscriptions/55555555-6666-7777-8888-999999999999/resourceGroups/Default-Network/providers/Microsoft.Network/privateEndpoints/private-endpoint-name-2"), // }, // PrivateLinkServiceConnectionState: &armhybridcompute.PrivateLinkServiceConnectionStateProperty{ // Description: to.Ptr("Please approve my connection."), // ActionsRequired: to.Ptr("None"), // Status: to.Ptr("Pending"), // }, // ProvisioningState: to.Ptr("Succeeded"), // }, // }}, // } }
Output:
type PrivateEndpointConnectionsClientBeginCreateOrUpdateOptions ¶
type PrivateEndpointConnectionsClientBeginCreateOrUpdateOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
PrivateEndpointConnectionsClientBeginCreateOrUpdateOptions contains the optional parameters for the PrivateEndpointConnectionsClient.BeginCreateOrUpdate method.
type PrivateEndpointConnectionsClientBeginDeleteOptions ¶
type PrivateEndpointConnectionsClientBeginDeleteOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
PrivateEndpointConnectionsClientBeginDeleteOptions contains the optional parameters for the PrivateEndpointConnectionsClient.BeginDelete method.
type PrivateEndpointConnectionsClientCreateOrUpdateResponse ¶
type PrivateEndpointConnectionsClientCreateOrUpdateResponse struct { // A private endpoint connection PrivateEndpointConnection }
PrivateEndpointConnectionsClientCreateOrUpdateResponse contains the response from method PrivateEndpointConnectionsClient.BeginCreateOrUpdate.
type PrivateEndpointConnectionsClientDeleteResponse ¶
type PrivateEndpointConnectionsClientDeleteResponse struct { }
PrivateEndpointConnectionsClientDeleteResponse contains the response from method PrivateEndpointConnectionsClient.BeginDelete.
type PrivateEndpointConnectionsClientGetOptions ¶
type PrivateEndpointConnectionsClientGetOptions struct { }
PrivateEndpointConnectionsClientGetOptions contains the optional parameters for the PrivateEndpointConnectionsClient.Get method.
type PrivateEndpointConnectionsClientGetResponse ¶
type PrivateEndpointConnectionsClientGetResponse struct { // A private endpoint connection PrivateEndpointConnection }
PrivateEndpointConnectionsClientGetResponse contains the response from method PrivateEndpointConnectionsClient.Get.
type PrivateEndpointConnectionsClientListByPrivateLinkScopeOptions ¶
type PrivateEndpointConnectionsClientListByPrivateLinkScopeOptions struct { }
PrivateEndpointConnectionsClientListByPrivateLinkScopeOptions contains the optional parameters for the PrivateEndpointConnectionsClient.NewListByPrivateLinkScopePager method.
type PrivateEndpointConnectionsClientListByPrivateLinkScopeResponse ¶
type PrivateEndpointConnectionsClientListByPrivateLinkScopeResponse struct { // A list of private endpoint connections. PrivateEndpointConnectionListResult }
PrivateEndpointConnectionsClientListByPrivateLinkScopeResponse contains the response from method PrivateEndpointConnectionsClient.NewListByPrivateLinkScopePager.
type PrivateEndpointProperty ¶
type PrivateEndpointProperty struct { // Resource id of the private endpoint. ID *string }
PrivateEndpointProperty - Private endpoint which the connection belongs to.
func (PrivateEndpointProperty) MarshalJSON ¶
func (p PrivateEndpointProperty) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type PrivateEndpointProperty.
func (*PrivateEndpointProperty) UnmarshalJSON ¶
func (p *PrivateEndpointProperty) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type PrivateEndpointProperty.
type PrivateLinkResource ¶
type PrivateLinkResource struct { // Resource properties. Properties *PrivateLinkResourceProperties // READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} ID *string // READ-ONLY; The name of the resource Name *string // READ-ONLY; Azure Resource Manager metadata containing createdBy and modifiedBy information. SystemData *SystemData // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string }
PrivateLinkResource - A private link resource
func (PrivateLinkResource) MarshalJSON ¶
func (p PrivateLinkResource) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type PrivateLinkResource.
func (*PrivateLinkResource) UnmarshalJSON ¶
func (p *PrivateLinkResource) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type PrivateLinkResource.
type PrivateLinkResourceListResult ¶
type PrivateLinkResourceListResult struct { // READ-ONLY; Link to retrieve next page of results. NextLink *string // READ-ONLY; Array of results. Value []*PrivateLinkResource }
PrivateLinkResourceListResult - A list of private link resources
func (PrivateLinkResourceListResult) MarshalJSON ¶
func (p PrivateLinkResourceListResult) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type PrivateLinkResourceListResult.
func (*PrivateLinkResourceListResult) UnmarshalJSON ¶
func (p *PrivateLinkResourceListResult) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type PrivateLinkResourceListResult.
type PrivateLinkResourceProperties ¶
type PrivateLinkResourceProperties struct { // READ-ONLY; The private link resource group id. GroupID *string // READ-ONLY; The private link resource required member names. RequiredMembers []*string // READ-ONLY; Required DNS zone names of the the private link resource. RequiredZoneNames []*string }
PrivateLinkResourceProperties - Properties of a private link resource.
func (PrivateLinkResourceProperties) MarshalJSON ¶
func (p PrivateLinkResourceProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type PrivateLinkResourceProperties.
func (*PrivateLinkResourceProperties) UnmarshalJSON ¶
func (p *PrivateLinkResourceProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type PrivateLinkResourceProperties.
type PrivateLinkResourcesClient ¶
type PrivateLinkResourcesClient struct {
// contains filtered or unexported fields
}
PrivateLinkResourcesClient contains the methods for the PrivateLinkResources group. Don't use this type directly, use NewPrivateLinkResourcesClient() instead.
func NewPrivateLinkResourcesClient ¶
func NewPrivateLinkResourcesClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*PrivateLinkResourcesClient, error)
NewPrivateLinkResourcesClient creates a new instance of PrivateLinkResourcesClient with the specified values.
- subscriptionID - The ID of the target subscription.
- credential - used to authorize requests. Usually a credential from azidentity.
- options - pass nil to accept the default values.
func (*PrivateLinkResourcesClient) Get ¶
func (client *PrivateLinkResourcesClient) Get(ctx context.Context, resourceGroupName string, scopeName string, groupName string, options *PrivateLinkResourcesClientGetOptions) (PrivateLinkResourcesClientGetResponse, error)
Get - Gets the private link resources that need to be created for a Azure Monitor PrivateLinkScope. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group. The name is case insensitive.
- scopeName - The name of the Azure Arc PrivateLinkScope resource.
- groupName - The name of the private link resource.
- options - PrivateLinkResourcesClientGetOptions contains the optional parameters for the PrivateLinkResourcesClient.Get method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/privateLinkScope/PrivateLinkScopePrivateLinkResource_Get.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := clientFactory.NewPrivateLinkResourcesClient().Get(ctx, "myResourceGroup", "myPrivateLinkScope", "hybridcompute", 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.PrivateLinkResource = armhybridcompute.PrivateLinkResource{ // Name: to.Ptr("hybridcompute"), // Type: to.Ptr("Microsoft.HybridCompute/privateLinkScopes/privateLinkResources"), // ID: to.Ptr("/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/privateLinkScopes/myPrivateLinkScope/privateLinkResources/hybridcompute"), // Properties: &armhybridcompute.PrivateLinkResourceProperties{ // GroupID: to.Ptr("hybridcompute"), // RequiredMembers: []*string{ // to.Ptr("HybridCompute.Server"), // to.Ptr("HybridCompute.K8sConfiguration"), // to.Ptr("GuestConfig.DP")}, // RequiredZoneNames: []*string{ // to.Ptr("privatelink.his.arc.azure.com"), // to.Ptr("privatelink.kubernetesconfiguration.azure.com"), // to.Ptr("privatelink.Guestconfiguration.azure.com")}, // }, // }
Output:
func (*PrivateLinkResourcesClient) NewListByPrivateLinkScopePager ¶
func (client *PrivateLinkResourcesClient) NewListByPrivateLinkScopePager(resourceGroupName string, scopeName string, options *PrivateLinkResourcesClientListByPrivateLinkScopeOptions) *runtime.Pager[PrivateLinkResourcesClientListByPrivateLinkScopeResponse]
NewListByPrivateLinkScopePager - Gets the private link resources that need to be created for a Azure Monitor PrivateLinkScope.
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group. The name is case insensitive.
- scopeName - The name of the Azure Arc PrivateLinkScope resource.
- options - PrivateLinkResourcesClientListByPrivateLinkScopeOptions contains the optional parameters for the PrivateLinkResourcesClient.NewListByPrivateLinkScopePager method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/privateLinkScope/PrivateLinkScopePrivateLinkResource_ListGet.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } pager := clientFactory.NewPrivateLinkResourcesClient().NewListByPrivateLinkScopePager("myResourceGroup", "myPrivateLinkScope", 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.PrivateLinkResourceListResult = armhybridcompute.PrivateLinkResourceListResult{ // Value: []*armhybridcompute.PrivateLinkResource{ // { // Name: to.Ptr("hybridcompute"), // Type: to.Ptr("Microsoft.HybridCompute/privateLinkScopes/privateLinkResources"), // ID: to.Ptr("/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/privateLinkScopes/myPrivateLinkScope/privateLinkResources/hybridcompute"), // Properties: &armhybridcompute.PrivateLinkResourceProperties{ // GroupID: to.Ptr("hybridcompute"), // RequiredMembers: []*string{ // to.Ptr("HybridCompute.ServerDP"), // to.Ptr("HybridCompute.K8sConfigurationDP"), // to.Ptr("HybridCompute.GuestConfigDP")}, // RequiredZoneNames: []*string{ // to.Ptr("privatelink.his.arc.azure.com"), // to.Ptr("privatelink.kubernetesconfiguration.azure.com"), // to.Ptr("privatelink.Guestconfiguration.azure.com")}, // }, // }}, // } }
Output:
type PrivateLinkResourcesClientGetOptions ¶
type PrivateLinkResourcesClientGetOptions struct { }
PrivateLinkResourcesClientGetOptions contains the optional parameters for the PrivateLinkResourcesClient.Get method.
type PrivateLinkResourcesClientGetResponse ¶
type PrivateLinkResourcesClientGetResponse struct { // A private link resource PrivateLinkResource }
PrivateLinkResourcesClientGetResponse contains the response from method PrivateLinkResourcesClient.Get.
type PrivateLinkResourcesClientListByPrivateLinkScopeOptions ¶
type PrivateLinkResourcesClientListByPrivateLinkScopeOptions struct { }
PrivateLinkResourcesClientListByPrivateLinkScopeOptions contains the optional parameters for the PrivateLinkResourcesClient.NewListByPrivateLinkScopePager method.
type PrivateLinkResourcesClientListByPrivateLinkScopeResponse ¶
type PrivateLinkResourcesClientListByPrivateLinkScopeResponse struct { // A list of private link resources PrivateLinkResourceListResult }
PrivateLinkResourcesClientListByPrivateLinkScopeResponse contains the response from method PrivateLinkResourcesClient.NewListByPrivateLinkScopePager.
type PrivateLinkScope ¶
type PrivateLinkScope struct { // REQUIRED; Resource location Location *string // Properties that define a Azure Arc PrivateLinkScope resource. Properties *PrivateLinkScopeProperties // Resource tags Tags map[string]*string // READ-ONLY; Azure resource Id ID *string // READ-ONLY; Azure resource name Name *string // READ-ONLY; The system meta data relating to this resource. SystemData *SystemData // READ-ONLY; Azure resource type Type *string }
PrivateLinkScope - An Azure Arc PrivateLinkScope definition.
func (PrivateLinkScope) MarshalJSON ¶
func (p PrivateLinkScope) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type PrivateLinkScope.
func (*PrivateLinkScope) UnmarshalJSON ¶
func (p *PrivateLinkScope) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type PrivateLinkScope.
type PrivateLinkScopeListResult ¶
type PrivateLinkScopeListResult struct { // REQUIRED; List of Azure Arc PrivateLinkScope definitions. Value []*PrivateLinkScope // The URI to get the next set of Azure Arc PrivateLinkScope definitions if too many PrivateLinkScopes where returned in the // result set. NextLink *string }
PrivateLinkScopeListResult - Describes the list of Azure Arc PrivateLinkScope resources.
func (PrivateLinkScopeListResult) MarshalJSON ¶
func (p PrivateLinkScopeListResult) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type PrivateLinkScopeListResult.
func (*PrivateLinkScopeListResult) UnmarshalJSON ¶
func (p *PrivateLinkScopeListResult) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type PrivateLinkScopeListResult.
type PrivateLinkScopeProperties ¶
type PrivateLinkScopeProperties struct { // Indicates whether machines associated with the private link scope can also use public Azure Arc service endpoints. PublicNetworkAccess *PublicNetworkAccessType // READ-ONLY; The collection of associated Private Endpoint Connections. PrivateEndpointConnections []*PrivateEndpointConnectionDataModel // READ-ONLY; The Guid id of the private link scope. PrivateLinkScopeID *string // READ-ONLY; Current state of this PrivateLinkScope: whether or not is has been provisioned within the resource group it // is defined. Users cannot change this value but are able to read from it. Values will include // Provisioning ,Succeeded, Canceled and Failed. ProvisioningState *string }
PrivateLinkScopeProperties - Properties that define a Azure Arc PrivateLinkScope resource.
func (PrivateLinkScopeProperties) MarshalJSON ¶
func (p PrivateLinkScopeProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type PrivateLinkScopeProperties.
func (*PrivateLinkScopeProperties) UnmarshalJSON ¶
func (p *PrivateLinkScopeProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type PrivateLinkScopeProperties.
type PrivateLinkScopeValidationDetails ¶
type PrivateLinkScopeValidationDetails struct { // List of Private Endpoint Connection details. ConnectionDetails []*ConnectionDetail // Indicates whether machines associated with the private link scope can also use public Azure Arc service endpoints. PublicNetworkAccess *PublicNetworkAccessType // READ-ONLY; Azure resource Id ID *string }
func (PrivateLinkScopeValidationDetails) MarshalJSON ¶
func (p PrivateLinkScopeValidationDetails) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type PrivateLinkScopeValidationDetails.
func (*PrivateLinkScopeValidationDetails) UnmarshalJSON ¶
func (p *PrivateLinkScopeValidationDetails) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type PrivateLinkScopeValidationDetails.
type PrivateLinkScopesClient ¶
type PrivateLinkScopesClient struct {
// contains filtered or unexported fields
}
PrivateLinkScopesClient contains the methods for the PrivateLinkScopes group. Don't use this type directly, use NewPrivateLinkScopesClient() instead.
func NewPrivateLinkScopesClient ¶
func NewPrivateLinkScopesClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*PrivateLinkScopesClient, error)
NewPrivateLinkScopesClient creates a new instance of PrivateLinkScopesClient with the specified values.
- subscriptionID - The ID of the target subscription.
- credential - used to authorize requests. Usually a credential from azidentity.
- options - pass nil to accept the default values.
func (*PrivateLinkScopesClient) BeginDelete ¶
func (client *PrivateLinkScopesClient) BeginDelete(ctx context.Context, resourceGroupName string, scopeName string, options *PrivateLinkScopesClientBeginDeleteOptions) (*runtime.Poller[PrivateLinkScopesClientDeleteResponse], error)
BeginDelete - Deletes a Azure Arc PrivateLinkScope. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group. The name is case insensitive.
- scopeName - The name of the Azure Arc PrivateLinkScope resource.
- options - PrivateLinkScopesClientBeginDeleteOptions contains the optional parameters for the PrivateLinkScopesClient.BeginDelete method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/privateLinkScope/PrivateLinkScopes_Delete.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewPrivateLinkScopesClient().BeginDelete(ctx, "my-resource-group", "my-privatelinkscope", nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) } _, err = poller.PollUntilDone(ctx, nil) if err != nil { log.Fatalf("failed to pull the result: %v", err) }
Output:
func (*PrivateLinkScopesClient) CreateOrUpdate ¶
func (client *PrivateLinkScopesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, scopeName string, parameters PrivateLinkScope, options *PrivateLinkScopesClientCreateOrUpdateOptions) (PrivateLinkScopesClientCreateOrUpdateResponse, error)
CreateOrUpdate - Creates (or updates) a Azure Arc PrivateLinkScope. Note: You cannot specify a different value for InstrumentationKey nor AppId in the Put operation. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group. The name is case insensitive.
- scopeName - The name of the Azure Arc PrivateLinkScope resource.
- parameters - Properties that need to be specified to create or update a Azure Arc for Servers and Clusters PrivateLinkScope.
- options - PrivateLinkScopesClientCreateOrUpdateOptions contains the optional parameters for the PrivateLinkScopesClient.CreateOrUpdate method.
Example (PrivateLinkScopeCreate) ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/privateLinkScope/PrivateLinkScopes_Create.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := clientFactory.NewPrivateLinkScopesClient().CreateOrUpdate(ctx, "my-resource-group", "my-privatelinkscope", armhybridcompute.PrivateLinkScope{ Location: to.Ptr("westus"), }, 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.PrivateLinkScope = armhybridcompute.PrivateLinkScope{ // Name: to.Ptr("my-privatelinkscope"), // Type: to.Ptr("Microsoft.HybridCompute/privateLinkScopes"), // ID: to.Ptr("/subscriptions/86dc51d3-92ed-4d7e-947a-775ea79b4919/resourceGroups/my-resource-group/providers/microsoft.hybridcompute/privateLinkScopes/my-privatelinkscope"), // Location: to.Ptr("westus"), // Tags: map[string]*string{ // }, // Properties: &armhybridcompute.PrivateLinkScopeProperties{ // PrivateEndpointConnections: []*armhybridcompute.PrivateEndpointConnectionDataModel{ // { // Name: to.Ptr("private-endpoint-connection-name"), // Type: to.Ptr("Microsoft.HybridCompute/privateLinkScopes/privateEndpointConnections"), // ID: to.Ptr("/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/privateLinkScopes/myPrivateLinkScope/privateEndpointConnections/private-endpoint-connection-name"), // Properties: &armhybridcompute.PrivateEndpointConnectionProperties{ // PrivateEndpoint: &armhybridcompute.PrivateEndpointProperty{ // ID: to.Ptr("/subscriptions/55555555-6666-7777-8888-999999999999/resourceGroups/Default-Network/providers/Microsoft.Network/privateEndpoints/private-endpoint-name"), // }, // PrivateLinkServiceConnectionState: &armhybridcompute.PrivateLinkServiceConnectionStateProperty{ // Description: to.Ptr("Auto-approved"), // ActionsRequired: to.Ptr("None"), // Status: to.Ptr("Approved"), // }, // ProvisioningState: to.Ptr("Succeeded"), // }, // }}, // PrivateLinkScopeID: to.Ptr("e5dc51d3-92ed-4d7e-947a-775ea79b4919"), // ProvisioningState: to.Ptr("Succeeded"), // PublicNetworkAccess: to.Ptr(armhybridcompute.PublicNetworkAccessTypeDisabled), // }, // }
Output:
Example (PrivateLinkScopeUpdate) ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/privateLinkScope/PrivateLinkScopes_Update.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := clientFactory.NewPrivateLinkScopesClient().CreateOrUpdate(ctx, "my-resource-group", "my-privatelinkscope", armhybridcompute.PrivateLinkScope{ Location: to.Ptr("westus"), Tags: map[string]*string{ "Tag1": to.Ptr("Value1"), }, }, 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.PrivateLinkScope = armhybridcompute.PrivateLinkScope{ // Name: to.Ptr("my-privatelinkscope"), // Type: to.Ptr("Microsoft.HybridCompute/privateLinkScopes"), // ID: to.Ptr("/subscriptions/86dc51d3-92ed-4d7e-947a-775ea79b4919/resourceGroups/my-resource-group/providers/microsoft.hybridCompute/privateLinkScopes/my-privatelinkscope"), // Location: to.Ptr("westus"), // Tags: map[string]*string{ // "Tag1": to.Ptr("Value1"), // }, // Properties: &armhybridcompute.PrivateLinkScopeProperties{ // PrivateEndpointConnections: []*armhybridcompute.PrivateEndpointConnectionDataModel{ // { // Name: to.Ptr("private-endpoint-connection-name"), // Type: to.Ptr("Microsoft.HybridCompute/privateLinkScopes/privateEndpointConnections"), // ID: to.Ptr("/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/privateLinkScopes/myPrivateLinkScope/privateEndpointConnections/private-endpoint-connection-name"), // Properties: &armhybridcompute.PrivateEndpointConnectionProperties{ // PrivateEndpoint: &armhybridcompute.PrivateEndpointProperty{ // ID: to.Ptr("/subscriptions/55555555-6666-7777-8888-999999999999/resourceGroups/Default-Network/providers/Microsoft.Network/privateEndpoints/private-endpoint-name"), // }, // PrivateLinkServiceConnectionState: &armhybridcompute.PrivateLinkServiceConnectionStateProperty{ // Description: to.Ptr("Auto-approved"), // ActionsRequired: to.Ptr("None"), // Status: to.Ptr("Approved"), // }, // ProvisioningState: to.Ptr("Succeeded"), // }, // }}, // PrivateLinkScopeID: to.Ptr("e5dc51d3-92ed-4d7e-947a-775ea79b4919"), // ProvisioningState: to.Ptr("Succeeded"), // PublicNetworkAccess: to.Ptr(armhybridcompute.PublicNetworkAccessTypeDisabled), // }, // }
Output:
func (*PrivateLinkScopesClient) Get ¶
func (client *PrivateLinkScopesClient) Get(ctx context.Context, resourceGroupName string, scopeName string, options *PrivateLinkScopesClientGetOptions) (PrivateLinkScopesClientGetResponse, error)
Get - Returns a Azure Arc PrivateLinkScope. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group. The name is case insensitive.
- scopeName - The name of the Azure Arc PrivateLinkScope resource.
- options - PrivateLinkScopesClientGetOptions contains the optional parameters for the PrivateLinkScopesClient.Get method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/privateLinkScope/PrivateLinkScopes_Get.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := clientFactory.NewPrivateLinkScopesClient().Get(ctx, "my-resource-group", "my-privatelinkscope", 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.PrivateLinkScope = armhybridcompute.PrivateLinkScope{ // Name: to.Ptr("my-privatelinkscope"), // Type: to.Ptr("Microsoft.HybridCompute/privateLinkScopes"), // ID: to.Ptr("/subscriptions/86dc51d3-92ed-4d7e-947a-775ea79b4919/resourceGroups/my-resource-group/providers/microsoft.hybridcompute/privateLinkScopes/my-privatelinkscope"), // Location: to.Ptr("westus"), // Tags: map[string]*string{ // }, // Properties: &armhybridcompute.PrivateLinkScopeProperties{ // PrivateEndpointConnections: []*armhybridcompute.PrivateEndpointConnectionDataModel{ // { // Name: to.Ptr("private-endpoint-connection-name"), // Type: to.Ptr("Microsoft.HybridCompute/privateLinkScopes/privateEndpointConnections"), // ID: to.Ptr("/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/privateLinkScopes/myPrivateLinkScope/privateEndpointConnections/private-endpoint-connection-name"), // Properties: &armhybridcompute.PrivateEndpointConnectionProperties{ // PrivateEndpoint: &armhybridcompute.PrivateEndpointProperty{ // ID: to.Ptr("/subscriptions/55555555-6666-7777-8888-999999999999/resourceGroups/Default-Network/providers/Microsoft.Network/privateEndpoints/private-endpoint-name"), // }, // PrivateLinkServiceConnectionState: &armhybridcompute.PrivateLinkServiceConnectionStateProperty{ // Description: to.Ptr("Auto-approved"), // ActionsRequired: to.Ptr("None"), // Status: to.Ptr("Approved"), // }, // ProvisioningState: to.Ptr("Succeeded"), // }, // }}, // PrivateLinkScopeID: to.Ptr("f5dc51d3-92ed-4d7e-947a-775ea79b4919"), // ProvisioningState: to.Ptr("Succeeded"), // PublicNetworkAccess: to.Ptr(armhybridcompute.PublicNetworkAccessTypeDisabled), // }, // }
Output:
func (*PrivateLinkScopesClient) GetValidationDetails ¶
func (client *PrivateLinkScopesClient) GetValidationDetails(ctx context.Context, location string, privateLinkScopeID string, options *PrivateLinkScopesClientGetValidationDetailsOptions) (PrivateLinkScopesClientGetValidationDetailsResponse, error)
GetValidationDetails - Returns a Azure Arc PrivateLinkScope's validation details. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-07-10
- location - The location of the target resource.
- privateLinkScopeID - The id (Guid) of the Azure Arc PrivateLinkScope resource.
- options - PrivateLinkScopesClientGetValidationDetailsOptions contains the optional parameters for the PrivateLinkScopesClient.GetValidationDetails method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/privateLinkScope/PrivateLinkScopes_GetValidation.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := clientFactory.NewPrivateLinkScopesClient().GetValidationDetails(ctx, "wus2", "f5dc51d3-92ed-4d7e-947a-775ea79b4919", 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.PrivateLinkScopeValidationDetails = armhybridcompute.PrivateLinkScopeValidationDetails{ // ConnectionDetails: []*armhybridcompute.ConnectionDetail{ // { // GroupID: to.Ptr("groupId"), // ID: to.Ptr("id"), // LinkIdentifier: to.Ptr("linkId"), // MemberName: to.Ptr("memberName"), // PrivateIPAddress: to.Ptr("ip"), // }}, // ID: to.Ptr("/subscriptions/86dc51d3-92ed-4d7e-947a-775ea79b4919/resourceGroups/my-resource-group/providers/microsoft.hybridcompute/privateLinkScopes/my-privatelinkscope"), // PublicNetworkAccess: to.Ptr(armhybridcompute.PublicNetworkAccessTypeDisabled), // }
Output:
func (*PrivateLinkScopesClient) GetValidationDetailsForMachine ¶
func (client *PrivateLinkScopesClient) GetValidationDetailsForMachine(ctx context.Context, resourceGroupName string, machineName string, options *PrivateLinkScopesClientGetValidationDetailsForMachineOptions) (PrivateLinkScopesClientGetValidationDetailsForMachineResponse, error)
GetValidationDetailsForMachine - Returns a Azure Arc PrivateLinkScope's validation details for a given machine. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group. The name is case insensitive.
- machineName - The name of the target machine to get the private link scope validation details for.
- options - PrivateLinkScopesClientGetValidationDetailsForMachineOptions contains the optional parameters for the PrivateLinkScopesClient.GetValidationDetailsForMachine method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/privateLinkScope/PrivateLinkScopes_GetValidationForMachine.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := clientFactory.NewPrivateLinkScopesClient().GetValidationDetailsForMachine(ctx, "my-resource-group", "machineName", 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.PrivateLinkScopeValidationDetails = armhybridcompute.PrivateLinkScopeValidationDetails{ // ConnectionDetails: []*armhybridcompute.ConnectionDetail{ // { // GroupID: to.Ptr("groupId"), // ID: to.Ptr("id"), // LinkIdentifier: to.Ptr("linkId"), // MemberName: to.Ptr("memberName"), // PrivateIPAddress: to.Ptr("ip"), // }}, // ID: to.Ptr("/subscriptions/86dc51d3-92ed-4d7e-947a-775ea79b4919/resourceGroups/my-resource-group/providers/microsoft.hybridcompute/privateLinkScopes/my-privatelinkscope"), // PublicNetworkAccess: to.Ptr(armhybridcompute.PublicNetworkAccessTypeDisabled), // }
Output:
func (*PrivateLinkScopesClient) NewListByResourceGroupPager ¶
func (client *PrivateLinkScopesClient) NewListByResourceGroupPager(resourceGroupName string, options *PrivateLinkScopesClientListByResourceGroupOptions) *runtime.Pager[PrivateLinkScopesClientListByResourceGroupResponse]
NewListByResourceGroupPager - Gets a list of Azure Arc PrivateLinkScopes within a resource group.
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group. The name is case insensitive.
- options - PrivateLinkScopesClientListByResourceGroupOptions contains the optional parameters for the PrivateLinkScopesClient.NewListByResourceGroupPager method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/privateLinkScope/PrivateLinkScopes_ListByResourceGroup.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } pager := clientFactory.NewPrivateLinkScopesClient().NewListByResourceGroupPager("my-resource-group", 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.PrivateLinkScopeListResult = armhybridcompute.PrivateLinkScopeListResult{ // Value: []*armhybridcompute.PrivateLinkScope{ // { // Name: to.Ptr("my-privatelinkscope"), // Type: to.Ptr("Microsoft.HybridCompute/privateLinkScopes"), // ID: to.Ptr("/subscriptions/86dc51d3-92ed-4d7e-947a-775ea79b4919/resourceGroups/my-resource-group/providers/microsoft.hybridcompute/privateLinkScopes/my-privatelinkscope"), // Location: to.Ptr("westus"), // Tags: map[string]*string{ // }, // Properties: &armhybridcompute.PrivateLinkScopeProperties{ // PrivateEndpointConnections: []*armhybridcompute.PrivateEndpointConnectionDataModel{ // { // Name: to.Ptr("private-endpoint-connection-name"), // Type: to.Ptr("Microsoft.HybridCompute/privateLinkScopes/privateEndpointConnections"), // ID: to.Ptr("/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/privateLinkScopes/myPrivateLinkScope/privateEndpointConnections/private-endpoint-connection-name"), // Properties: &armhybridcompute.PrivateEndpointConnectionProperties{ // PrivateEndpoint: &armhybridcompute.PrivateEndpointProperty{ // ID: to.Ptr("/subscriptions/55555555-6666-7777-8888-999999999999/resourceGroups/Default-Network/providers/Microsoft.Network/privateEndpoints/private-endpoint-name"), // }, // PrivateLinkServiceConnectionState: &armhybridcompute.PrivateLinkServiceConnectionStateProperty{ // Description: to.Ptr("Auto-approved"), // ActionsRequired: to.Ptr("None"), // Status: to.Ptr("Approved"), // }, // ProvisioningState: to.Ptr("Succeeded"), // }, // }}, // PrivateLinkScopeID: to.Ptr("f5dc51d3-92ed-4d7e-947a-775ea79b4919"), // ProvisioningState: to.Ptr("Succeeded"), // PublicNetworkAccess: to.Ptr(armhybridcompute.PublicNetworkAccessTypeDisabled), // }, // }, // { // Name: to.Ptr("my-other-privatelinkscope"), // Type: to.Ptr("Microsoft.HybridCompute/privateLinkScopes"), // ID: to.Ptr("/subscriptions/86dc51d3-92ed-4d7e-947a-775ea79b4919/resourceGroups/my-resource-group/providers/microsoft.hybridcompute/privateLinkScopes/my-other-privatelinkscope"), // Location: to.Ptr("westus"), // Tags: map[string]*string{ // }, // Properties: &armhybridcompute.PrivateLinkScopeProperties{ // PrivateEndpointConnections: []*armhybridcompute.PrivateEndpointConnectionDataModel{ // { // Name: to.Ptr("private-endpoint-connection-name"), // Type: to.Ptr("Microsoft.HybridCompute/privateLinkScopes/privateEndpointConnections"), // ID: to.Ptr("/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/privateLinkScopes/myPrivateLinkScope/privateEndpointConnections/private-endpoint-connection-name"), // Properties: &armhybridcompute.PrivateEndpointConnectionProperties{ // PrivateEndpoint: &armhybridcompute.PrivateEndpointProperty{ // ID: to.Ptr("/subscriptions/55555555-6666-7777-8888-999999999999/resourceGroups/Default-Network/providers/Microsoft.Network/privateEndpoints/private-endpoint-name"), // }, // PrivateLinkServiceConnectionState: &armhybridcompute.PrivateLinkServiceConnectionStateProperty{ // Description: to.Ptr("Auto-approved"), // ActionsRequired: to.Ptr("None"), // Status: to.Ptr("Approved"), // }, // ProvisioningState: to.Ptr("Succeeded"), // }, // }}, // PrivateLinkScopeID: to.Ptr("a5dc51d3-92ed-4d7e-947a-775ea79b4919"), // ProvisioningState: to.Ptr("Succeeded"), // PublicNetworkAccess: to.Ptr(armhybridcompute.PublicNetworkAccessTypeDisabled), // }, // }}, // } }
Output:
func (*PrivateLinkScopesClient) NewListPager ¶
func (client *PrivateLinkScopesClient) NewListPager(options *PrivateLinkScopesClientListOptions) *runtime.Pager[PrivateLinkScopesClientListResponse]
NewListPager - Gets a list of all Azure Arc PrivateLinkScopes within a subscription.
Generated from API version 2024-07-10
- options - PrivateLinkScopesClientListOptions contains the optional parameters for the PrivateLinkScopesClient.NewListPager method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/privateLinkScope/PrivateLinkScopes_List.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } pager := clientFactory.NewPrivateLinkScopesClient().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.PrivateLinkScopeListResult = armhybridcompute.PrivateLinkScopeListResult{ // Value: []*armhybridcompute.PrivateLinkScope{ // { // Name: to.Ptr("my-privatelinkscope"), // Type: to.Ptr("Microsoft.HybridCompute/privateLinkScopes"), // ID: to.Ptr("/subscriptions/86dc51d3-92ed-4d7e-947a-775ea79b4919/resourceGroups/my-resource-group/providers/microsoft.hybridcompute/privateLinkScopes/my-privatelinkscope"), // Location: to.Ptr("westus"), // Tags: map[string]*string{ // }, // Properties: &armhybridcompute.PrivateLinkScopeProperties{ // PrivateLinkScopeID: to.Ptr("e5dc51d3-92ed-4d7e-947a-775ea79b4919"), // ProvisioningState: to.Ptr("Succeeded"), // PublicNetworkAccess: to.Ptr(armhybridcompute.PublicNetworkAccessTypeDisabled), // }, // }, // { // Name: to.Ptr("my-other-privatelinkscope"), // Type: to.Ptr("Microsoft.HybridCompute/privateLinkScopes"), // ID: to.Ptr("/subscriptions/86dc51d3-92ed-4d7e-947a-775ea79b4919/resourceGroups/my-resource-group/providers/microsoft.hybridcompute/privateLinkScopes/my-other-privatelinkscope"), // Location: to.Ptr("westus"), // Tags: map[string]*string{ // }, // Properties: &armhybridcompute.PrivateLinkScopeProperties{ // PrivateEndpointConnections: []*armhybridcompute.PrivateEndpointConnectionDataModel{ // { // Name: to.Ptr("private-endpoint-connection-name"), // Type: to.Ptr("Microsoft.HybridCompute/privateLinkScopes/privateEndpointConnections"), // ID: to.Ptr("/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/privateLinkScopes/myPrivateLinkScope/privateEndpointConnections/private-endpoint-connection-name"), // Properties: &armhybridcompute.PrivateEndpointConnectionProperties{ // PrivateEndpoint: &armhybridcompute.PrivateEndpointProperty{ // ID: to.Ptr("/subscriptions/55555555-6666-7777-8888-999999999999/resourceGroups/Default-Network/providers/Microsoft.Network/privateEndpoints/private-endpoint-name"), // }, // PrivateLinkServiceConnectionState: &armhybridcompute.PrivateLinkServiceConnectionStateProperty{ // Description: to.Ptr("Auto-approved"), // ActionsRequired: to.Ptr("None"), // Status: to.Ptr("Approved"), // }, // ProvisioningState: to.Ptr("Succeeded"), // }, // }}, // PrivateLinkScopeID: to.Ptr("f5dc51d3-92ed-4d7e-947a-775ea79b4919"), // ProvisioningState: to.Ptr("Succeeded"), // PublicNetworkAccess: to.Ptr(armhybridcompute.PublicNetworkAccessTypeDisabled), // }, // }}, // } }
Output:
func (*PrivateLinkScopesClient) UpdateTags ¶
func (client *PrivateLinkScopesClient) UpdateTags(ctx context.Context, resourceGroupName string, scopeName string, privateLinkScopeTags TagsResource, options *PrivateLinkScopesClientUpdateTagsOptions) (PrivateLinkScopesClientUpdateTagsResponse, error)
UpdateTags - Updates an existing PrivateLinkScope's tags. To update other fields use the CreateOrUpdate method. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-07-10
- resourceGroupName - The name of the resource group. The name is case insensitive.
- scopeName - The name of the Azure Arc PrivateLinkScope resource.
- privateLinkScopeTags - Updated tag information to set into the PrivateLinkScope instance.
- options - PrivateLinkScopesClientUpdateTagsOptions contains the optional parameters for the PrivateLinkScopesClient.UpdateTags method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/f41d0c9332078cb2ef07b749081d94915255ada5/specification/hybridcompute/resource-manager/Microsoft.HybridCompute/stable/2024-07-10/examples/privateLinkScope/PrivateLinkScopes_UpdateTagsOnly.json
cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armhybridcompute.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := clientFactory.NewPrivateLinkScopesClient().UpdateTags(ctx, "my-resource-group", "my-privatelinkscope", armhybridcompute.TagsResource{ Tags: map[string]*string{ "Tag1": to.Ptr("Value1"), "Tag2": to.Ptr("Value2"), }, }, 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.PrivateLinkScope = armhybridcompute.PrivateLinkScope{ // Name: to.Ptr("my-privatelinkscope"), // Type: to.Ptr("Microsoft.HybridCompute/privateLinkScopes"), // ID: to.Ptr("/subscriptions/subid/resourceGroups/my-resource-group/providers/microsoft.hybridcompute/privateLinkScopes/my-privatelinkscope"), // Location: to.Ptr("westus"), // Tags: map[string]*string{ // "Tag1": to.Ptr("Value1"), // "Tag2": to.Ptr("Value2"), // }, // Properties: &armhybridcompute.PrivateLinkScopeProperties{ // PrivateEndpointConnections: []*armhybridcompute.PrivateEndpointConnectionDataModel{ // { // Name: to.Ptr("private-endpoint-connection-name"), // Type: to.Ptr("Microsoft.HybridCompute/privateLinkScopes/privateEndpointConnections"), // ID: to.Ptr("/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/privateLinkScopes/myPrivateLinkScope/privateEndpointConnections/private-endpoint-connection-name"), // Properties: &armhybridcompute.PrivateEndpointConnectionProperties{ // PrivateEndpoint: &armhybridcompute.PrivateEndpointProperty{ // ID: to.Ptr("/subscriptions/55555555-6666-7777-8888-999999999999/resourceGroups/Default-Network/providers/Microsoft.Network/privateEndpoints/private-endpoint-name"), // }, // PrivateLinkServiceConnectionState: &armhybridcompute.PrivateLinkServiceConnectionStateProperty{ // Description: to.Ptr("Auto-approved"), // ActionsRequired: to.Ptr("None"), // Status: to.Ptr("Approved"), // }, // ProvisioningState: to.Ptr("Succeeded"), // }, // }}, // PrivateLinkScopeID: to.Ptr("e5dc51d3-92ed-4d7e-947a-775ea79b4919"), // ProvisioningState: to.Ptr("Succeeded"), // PublicNetworkAccess: to.Ptr(armhybridcompute.PublicNetworkAccessTypeDisabled), // }, // }
Output:
type PrivateLinkScopesClientBeginDeleteOptions ¶
type PrivateLinkScopesClientBeginDeleteOptions struct { // Resumes the LRO from the provided token. ResumeToken string }
PrivateLinkScopesClientBeginDeleteOptions contains the optional parameters for the PrivateLinkScopesClient.BeginDelete method.
type PrivateLinkScopesClientCreateOrUpdateOptions ¶
type PrivateLinkScopesClientCreateOrUpdateOptions struct { }
PrivateLinkScopesClientCreateOrUpdateOptions contains the optional parameters for the PrivateLinkScopesClient.CreateOrUpdate method.
type PrivateLinkScopesClientCreateOrUpdateResponse ¶
type PrivateLinkScopesClientCreateOrUpdateResponse struct { // An Azure Arc PrivateLinkScope definition. PrivateLinkScope }
PrivateLinkScopesClientCreateOrUpdateResponse contains the response from method PrivateLinkScopesClient.CreateOrUpdate.
type PrivateLinkScopesClientDeleteResponse ¶
type PrivateLinkScopesClientDeleteResponse struct { }
PrivateLinkScopesClientDeleteResponse contains the response from method PrivateLinkScopesClient.BeginDelete.
type PrivateLinkScopesClientGetOptions ¶
type PrivateLinkScopesClientGetOptions struct { }
PrivateLinkScopesClientGetOptions contains the optional parameters for the PrivateLinkScopesClient.Get method.
type PrivateLinkScopesClientGetResponse ¶
type PrivateLinkScopesClientGetResponse struct { // An Azure Arc PrivateLinkScope definition. PrivateLinkScope }
PrivateLinkScopesClientGetResponse contains the response from method PrivateLinkScopesClient.Get.
type PrivateLinkScopesClientGetValidationDetailsForMachineOptions ¶
type PrivateLinkScopesClientGetValidationDetailsForMachineOptions struct { }
PrivateLinkScopesClientGetValidationDetailsForMachineOptions contains the optional parameters for the PrivateLinkScopesClient.GetValidationDetailsForMachine method.
type PrivateLinkScopesClientGetValidationDetailsForMachineResponse ¶
type PrivateLinkScopesClientGetValidationDetailsForMachineResponse struct {
PrivateLinkScopeValidationDetails
}
PrivateLinkScopesClientGetValidationDetailsForMachineResponse contains the response from method PrivateLinkScopesClient.GetValidationDetailsForMachine.
type PrivateLinkScopesClientGetValidationDetailsOptions ¶
type PrivateLinkScopesClientGetValidationDetailsOptions struct { }
PrivateLinkScopesClientGetValidationDetailsOptions contains the optional parameters for the PrivateLinkScopesClient.GetValidationDetails method.
type PrivateLinkScopesClientGetValidationDetailsResponse ¶
type PrivateLinkScopesClientGetValidationDetailsResponse struct {
PrivateLinkScopeValidationDetails
}
PrivateLinkScopesClientGetValidationDetailsResponse contains the response from method PrivateLinkScopesClient.GetValidationDetails.
type PrivateLinkScopesClientListByResourceGroupOptions ¶
type PrivateLinkScopesClientListByResourceGroupOptions struct { }
PrivateLinkScopesClientListByResourceGroupOptions contains the optional parameters for the PrivateLinkScopesClient.NewListByResourceGroupPager method.
type PrivateLinkScopesClientListByResourceGroupResponse ¶
type PrivateLinkScopesClientListByResourceGroupResponse struct { // Describes the list of Azure Arc PrivateLinkScope resources. PrivateLinkScopeListResult }
PrivateLinkScopesClientListByResourceGroupResponse contains the response from method PrivateLinkScopesClient.NewListByResourceGroupPager.
type PrivateLinkScopesClientListOptions ¶
type PrivateLinkScopesClientListOptions struct { }
PrivateLinkScopesClientListOptions contains the optional parameters for the PrivateLinkScopesClient.NewListPager method.
type PrivateLinkScopesClientListResponse ¶
type PrivateLinkScopesClientListResponse struct { // Describes the list of Azure Arc PrivateLinkScope resources. PrivateLinkScopeListResult }
PrivateLinkScopesClientListResponse contains the response from method PrivateLinkScopesClient.NewListPager.
type PrivateLinkScopesClientUpdateTagsOptions ¶
type PrivateLinkScopesClientUpdateTagsOptions struct { }
PrivateLinkScopesClientUpdateTagsOptions contains the optional parameters for the PrivateLinkScopesClient.UpdateTags method.
type PrivateLinkScopesClientUpdateTagsResponse ¶
type PrivateLinkScopesClientUpdateTagsResponse struct { // An Azure Arc PrivateLinkScope definition. PrivateLinkScope }
PrivateLinkScopesClientUpdateTagsResponse contains the response from method PrivateLinkScopesClient.UpdateTags.
type PrivateLinkServiceConnectionStateProperty ¶
type PrivateLinkServiceConnectionStateProperty struct { // REQUIRED; The private link service connection description. Description *string // REQUIRED; The private link service connection status. Status *string // READ-ONLY; The actions required for private link service connection. ActionsRequired *string }
PrivateLinkServiceConnectionStateProperty - State of the private endpoint connection.
func (PrivateLinkServiceConnectionStateProperty) MarshalJSON ¶
func (p PrivateLinkServiceConnectionStateProperty) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type PrivateLinkServiceConnectionStateProperty.
func (*PrivateLinkServiceConnectionStateProperty) UnmarshalJSON ¶
func (p *PrivateLinkServiceConnectionStateProperty) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type PrivateLinkServiceConnectionStateProperty.
type ProductFeature ¶
type ProductFeature struct { // Product feature name. Name *string // Indicates the current status of the product features. SubscriptionStatus *LicenseProfileSubscriptionStatus // READ-ONLY; The timestamp in UTC when the billing ends. BillingEndDate *time.Time // READ-ONLY; The timestamp in UTC when the billing starts. BillingStartDate *time.Time // READ-ONLY; The timestamp in UTC when the user disenrolled the feature. DisenrollmentDate *time.Time // READ-ONLY; The timestamp in UTC when the user enrolls the feature. EnrollmentDate *time.Time // READ-ONLY; The errors that were encountered during the feature enrollment or disenrollment. Error *ErrorDetail }
ProductFeature - Product Feature
func (ProductFeature) MarshalJSON ¶
func (p ProductFeature) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ProductFeature.
func (*ProductFeature) UnmarshalJSON ¶
func (p *ProductFeature) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ProductFeature.
type ProductFeatureUpdate ¶
type ProductFeatureUpdate struct { // Product feature name. Name *string // Indicates the new status of the product feature. SubscriptionStatus *LicenseProfileSubscriptionStatusUpdate }
ProductFeatureUpdate - Product Feature
func (ProductFeatureUpdate) MarshalJSON ¶
func (p ProductFeatureUpdate) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ProductFeatureUpdate.
func (*ProductFeatureUpdate) UnmarshalJSON ¶
func (p *ProductFeatureUpdate) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ProductFeatureUpdate.
type ProductProfileUpdateProperties ¶
type ProductProfileUpdateProperties struct { // The list of product feature updates. ProductFeatures []*ProductFeatureUpdate // Indicates the product type of the license. ProductType *LicenseProfileProductType // Indicates the subscription status of the product. SubscriptionStatus *LicenseProfileSubscriptionStatusUpdate }
ProductProfileUpdateProperties - Describes the Update properties of a Product Profile.
func (ProductProfileUpdateProperties) MarshalJSON ¶
func (p ProductProfileUpdateProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ProductProfileUpdateProperties.
func (*ProductProfileUpdateProperties) UnmarshalJSON ¶
func (p *ProductProfileUpdateProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ProductProfileUpdateProperties.
type ProgramYear ¶
type ProgramYear string
ProgramYear - Describes the program year the volume license is for.
const ( ProgramYearYear1 ProgramYear = "Year 1" ProgramYearYear2 ProgramYear = "Year 2" ProgramYearYear3 ProgramYear = "Year 3" )
func PossibleProgramYearValues ¶
func PossibleProgramYearValues() []ProgramYear
PossibleProgramYearValues returns the possible values for the ProgramYear const type.
type ProvisioningIssue ¶
type ProvisioningIssue struct { // READ-ONLY; Name of the provisioning issue. Name *string // READ-ONLY; Provisioning issue properties Properties *ProvisioningIssueProperties }
ProvisioningIssue - Details on issues that occurred during provisioning.
func (ProvisioningIssue) MarshalJSON ¶
func (p ProvisioningIssue) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ProvisioningIssue.
func (*ProvisioningIssue) UnmarshalJSON ¶
func (p *ProvisioningIssue) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ProvisioningIssue.
type ProvisioningIssueProperties ¶
type ProvisioningIssueProperties struct { // READ-ONLY; Description of the provisioning issue. Description *string // READ-ONLY; Issue type IssueType *ProvisioningIssueType // READ-ONLY; Severity of the provisioning issue. Severity *ProvisioningIssueSeverity // READ-ONLY; Access rules that can be added to the perimeter to remediate the issue SuggestedAccessRules []*AccessRule // READ-ONLY; ARM Ids of the resources that can be associated to the same perimeter to remediate the issue SuggestedResourceIDs []*string }
ProvisioningIssueProperties - Properties of a provisioning issue.
func (ProvisioningIssueProperties) MarshalJSON ¶
func (p ProvisioningIssueProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ProvisioningIssueProperties.
func (*ProvisioningIssueProperties) UnmarshalJSON ¶
func (p *ProvisioningIssueProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ProvisioningIssueProperties.
type ProvisioningIssueSeverity ¶
type ProvisioningIssueSeverity string
ProvisioningIssueSeverity - Severity of the provisioning issue.
const ( // ProvisioningIssueSeverityError - Errors will cause association provisioning to fail. ProvisioningIssueSeverityError ProvisioningIssueSeverity = "Error" // ProvisioningIssueSeverityWarning - Warnings can cause connectivity issues after provisioning succeeds. ProvisioningIssueSeverityWarning ProvisioningIssueSeverity = "Warning" )
func PossibleProvisioningIssueSeverityValues ¶
func PossibleProvisioningIssueSeverityValues() []ProvisioningIssueSeverity
PossibleProvisioningIssueSeverityValues returns the possible values for the ProvisioningIssueSeverity const type.
type ProvisioningIssueType ¶
type ProvisioningIssueType string
ProvisioningIssueType - Type of provisioning issue.
const ( // ProvisioningIssueTypeConfigurationPropagationFailure - Configuration failed to propagate. ProvisioningIssueTypeConfigurationPropagationFailure ProvisioningIssueType = "ConfigurationPropagationFailure" // ProvisioningIssueTypeMissingIdentityConfiguration - Identity configuration is missing. ProvisioningIssueTypeMissingIdentityConfiguration ProvisioningIssueType = "MissingIdentityConfiguration" // ProvisioningIssueTypeMissingPerimeterConfiguration - Perimeter configuration is missing. ProvisioningIssueTypeMissingPerimeterConfiguration ProvisioningIssueType = "MissingPerimeterConfiguration" // ProvisioningIssueTypeOther - Other failure. ProvisioningIssueTypeOther ProvisioningIssueType = "Other" )
func PossibleProvisioningIssueTypeValues ¶
func PossibleProvisioningIssueTypeValues() []ProvisioningIssueType
PossibleProvisioningIssueTypeValues returns the possible values for the ProvisioningIssueType const type.
type ProvisioningState ¶
type ProvisioningState string
ProvisioningState - The provisioning state, which only appears in the response.
const ( ProvisioningStateAccepted ProvisioningState = "Accepted" ProvisioningStateCanceled ProvisioningState = "Canceled" ProvisioningStateCreating ProvisioningState = "Creating" ProvisioningStateDeleted ProvisioningState = "Deleted" ProvisioningStateDeleting ProvisioningState = "Deleting" ProvisioningStateFailed ProvisioningState = "Failed" ProvisioningStateSucceeded ProvisioningState = "Succeeded" ProvisioningStateUpdating ProvisioningState = "Updating" )
func PossibleProvisioningStateValues ¶
func PossibleProvisioningStateValues() []ProvisioningState
PossibleProvisioningStateValues returns the possible values for the ProvisioningState const type.
type PublicNetworkAccessType ¶
type PublicNetworkAccessType string
PublicNetworkAccessType - The network access policy to determine if Azure Arc agents can use public Azure Arc service endpoints. Defaults to disabled (access to Azure Arc services only via private link).
const ( // PublicNetworkAccessTypeDisabled - Does not allow Azure Arc agents to communicate with Azure Arc services over public (internet) // endpoints. The agents must use the private link. PublicNetworkAccessTypeDisabled PublicNetworkAccessType = "Disabled" // PublicNetworkAccessTypeEnabled - Allows Azure Arc agents to communicate with Azure Arc services over both public (internet) // and private endpoints. PublicNetworkAccessTypeEnabled PublicNetworkAccessType = "Enabled" // PublicNetworkAccessTypeSecuredByPerimeter - Azure Arc agent communication with Azure Arc services over public (internet) // is enforced by Network Security Perimeter (NSP) PublicNetworkAccessTypeSecuredByPerimeter PublicNetworkAccessType = "SecuredByPerimeter" )
func PossiblePublicNetworkAccessTypeValues ¶
func PossiblePublicNetworkAccessTypeValues() []PublicNetworkAccessType
PossiblePublicNetworkAccessTypeValues returns the possible values for the PublicNetworkAccessType const type.
type ResourceAssociation ¶
type ResourceAssociation struct { // READ-ONLY; The access mode AccessMode *AccessMode // READ-ONLY; Name of the Resource Association Name *string }
ResourceAssociation - Properties that define a Resource Association.
func (ResourceAssociation) MarshalJSON ¶
func (r ResourceAssociation) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ResourceAssociation.
func (*ResourceAssociation) UnmarshalJSON ¶
func (r *ResourceAssociation) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ResourceAssociation.
type ServiceStatus ¶
type ServiceStatus struct { // The behavior of the service when the Arc-enabled machine starts up. StartupType *string // The current status of the service. Status *string }
ServiceStatus - Describes the status and behavior of a service.
func (ServiceStatus) MarshalJSON ¶
func (s ServiceStatus) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ServiceStatus.
func (*ServiceStatus) UnmarshalJSON ¶
func (s *ServiceStatus) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ServiceStatus.
type ServiceStatuses ¶
type ServiceStatuses struct { // The state of the extension service on the Arc-enabled machine. ExtensionService *ServiceStatus // The state of the guest configuration service on the Arc-enabled machine. GuestConfigurationService *ServiceStatus }
ServiceStatuses - Reports the state and behavior of dependent services.
func (ServiceStatuses) MarshalJSON ¶
func (s ServiceStatuses) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ServiceStatuses.
func (*ServiceStatuses) UnmarshalJSON ¶
func (s *ServiceStatuses) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ServiceStatuses.
type StatusLevelTypes ¶
type StatusLevelTypes string
StatusLevelTypes - The level code.
const ( StatusLevelTypesError StatusLevelTypes = "Error" StatusLevelTypesInfo StatusLevelTypes = "Info" StatusLevelTypesWarning StatusLevelTypes = "Warning" )
func PossibleStatusLevelTypesValues ¶
func PossibleStatusLevelTypesValues() []StatusLevelTypes
PossibleStatusLevelTypesValues returns the possible values for the StatusLevelTypes const type.
type StatusTypes ¶
type StatusTypes string
StatusTypes - The status of the hybrid machine agent.
const ( StatusTypesConnected StatusTypes = "Connected" StatusTypesDisconnected StatusTypes = "Disconnected" StatusTypesError StatusTypes = "Error" )
func PossibleStatusTypesValues ¶
func PossibleStatusTypesValues() []StatusTypes
PossibleStatusTypesValues returns the possible values for the StatusTypes const type.
type Subnet ¶
type Subnet struct { // Represents address prefix. AddressPrefix *string }
Subnet - Describes the subnet.
func (Subnet) MarshalJSON ¶
MarshalJSON implements the json.Marshaller interface for type Subnet.
func (*Subnet) UnmarshalJSON ¶
UnmarshalJSON implements the json.Unmarshaller interface for type Subnet.
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 TagsResource ¶
TagsResource - A container holding only the Tags for a resource, allowing the user to update the tags on a PrivateLinkScope instance.
func (TagsResource) MarshalJSON ¶
func (t TagsResource) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type TagsResource.
func (*TagsResource) UnmarshalJSON ¶
func (t *TagsResource) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type TagsResource.
type VMGuestPatchClassificationLinux ¶
type VMGuestPatchClassificationLinux string
const ( VMGuestPatchClassificationLinuxCritical VMGuestPatchClassificationLinux = "Critical" VMGuestPatchClassificationLinuxOther VMGuestPatchClassificationLinux = "Other" VMGuestPatchClassificationLinuxSecurity VMGuestPatchClassificationLinux = "Security" )
func PossibleVMGuestPatchClassificationLinuxValues ¶
func PossibleVMGuestPatchClassificationLinuxValues() []VMGuestPatchClassificationLinux
PossibleVMGuestPatchClassificationLinuxValues returns the possible values for the VMGuestPatchClassificationLinux const type.
type VMGuestPatchClassificationWindows ¶
type VMGuestPatchClassificationWindows string
const ( VMGuestPatchClassificationWindowsCritical VMGuestPatchClassificationWindows = "Critical" VMGuestPatchClassificationWindowsDefinition VMGuestPatchClassificationWindows = "Definition" VMGuestPatchClassificationWindowsFeaturePack VMGuestPatchClassificationWindows = "FeaturePack" VMGuestPatchClassificationWindowsSecurity VMGuestPatchClassificationWindows = "Security" VMGuestPatchClassificationWindowsServicePack VMGuestPatchClassificationWindows = "ServicePack" VMGuestPatchClassificationWindowsTools VMGuestPatchClassificationWindows = "Tools" VMGuestPatchClassificationWindowsUpdateRollUp VMGuestPatchClassificationWindows = "UpdateRollUp" VMGuestPatchClassificationWindowsUpdates VMGuestPatchClassificationWindows = "Updates" )
func PossibleVMGuestPatchClassificationWindowsValues ¶
func PossibleVMGuestPatchClassificationWindowsValues() []VMGuestPatchClassificationWindows
PossibleVMGuestPatchClassificationWindowsValues returns the possible values for the VMGuestPatchClassificationWindows const type.
type VMGuestPatchRebootSetting ¶
type VMGuestPatchRebootSetting string
VMGuestPatchRebootSetting - Defines when it is acceptable to reboot a VM during a software update operation.
const ( VMGuestPatchRebootSettingAlways VMGuestPatchRebootSetting = "Always" VMGuestPatchRebootSettingIfRequired VMGuestPatchRebootSetting = "IfRequired" VMGuestPatchRebootSettingNever VMGuestPatchRebootSetting = "Never" )
func PossibleVMGuestPatchRebootSettingValues ¶
func PossibleVMGuestPatchRebootSettingValues() []VMGuestPatchRebootSetting
PossibleVMGuestPatchRebootSettingValues returns the possible values for the VMGuestPatchRebootSetting const type.
type VMGuestPatchRebootStatus ¶
type VMGuestPatchRebootStatus string
VMGuestPatchRebootStatus - The reboot state of the VM following completion of the operation.
const ( VMGuestPatchRebootStatusCompleted VMGuestPatchRebootStatus = "Completed" VMGuestPatchRebootStatusFailed VMGuestPatchRebootStatus = "Failed" VMGuestPatchRebootStatusNotNeeded VMGuestPatchRebootStatus = "NotNeeded" VMGuestPatchRebootStatusRequired VMGuestPatchRebootStatus = "Required" VMGuestPatchRebootStatusStarted VMGuestPatchRebootStatus = "Started" VMGuestPatchRebootStatusUnknown VMGuestPatchRebootStatus = "Unknown" )
func PossibleVMGuestPatchRebootStatusValues ¶
func PossibleVMGuestPatchRebootStatusValues() []VMGuestPatchRebootStatus
PossibleVMGuestPatchRebootStatusValues returns the possible values for the VMGuestPatchRebootStatus const type.
type VolumeLicenseDetails ¶
type VolumeLicenseDetails struct { // The invoice id for the volume license. InvoiceID *string // Describes the program year the volume license is for. ProgramYear *ProgramYear }
func (VolumeLicenseDetails) MarshalJSON ¶
func (v VolumeLicenseDetails) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type VolumeLicenseDetails.
func (*VolumeLicenseDetails) UnmarshalJSON ¶
func (v *VolumeLicenseDetails) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type VolumeLicenseDetails.
type WindowsParameters ¶
type WindowsParameters struct { // The update classifications to select when installing patches for Windows. ClassificationsToInclude []*VMGuestPatchClassificationWindows // Filters out Kbs that don't have an InstallationRebootBehavior of 'NeverReboots' when this is set to true. ExcludeKbsRequiringReboot *bool // Kbs to exclude in the patch operation KbNumbersToExclude []*string // Kbs to include in the patch operation KbNumbersToInclude []*string // This is used to install patches that were published on or before this given max published date. MaxPatchPublishDate *time.Time }
WindowsParameters - Input for InstallPatches on a Windows VM, as directly received by the API
func (WindowsParameters) MarshalJSON ¶
func (w WindowsParameters) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type WindowsParameters.
func (*WindowsParameters) UnmarshalJSON ¶
func (w *WindowsParameters) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type WindowsParameters.
Source Files ¶
- build.go
- client_factory.go
- constants.go
- extensionmetadata_client.go
- licenseprofiles_client.go
- licenses_client.go
- machineextensions_client.go
- machines_client.go
- management_client.go
- models.go
- models_serde.go
- networkprofile_client.go
- networksecurityperimeterconfigurations_client.go
- operations_client.go
- options.go
- privateendpointconnections_client.go
- privatelinkresources_client.go
- privatelinkscopes_client.go
- responses.go
- time_rfc3339.go