用于 .Net 的 Azure 库
Thank you for the interest in this package.
If you are looking for the latest packages to interact with Azure resources, please use the following libraries: https://aka.ms/azsdk/dotnet/mgmt
Here is all of the latest packages: https://azure.github.io/azure-sdk/releases/latest/mgmt/dotnet.html
You can refer to this https://aka.ms/dotnet/t2/migration for more details about how to migrate your current code to our new SDK.
This README is based on the released stable version (1.38.1). If you are looking for other releases, see More Information
The Azure Management Libraries for .NET is a higher-level, object-oriented API for managing Azure resources. Libraries are built on the lower-level, request-response style auto generated clients and can run side-by-side with auto generated clients.
:triangular_flag_on_post: as of Version 1.38.1
Service | feature
Available as GA
Available as Preview
Coming soon
Compute
Virtual machines and VM extensions
Virtual machine scale sets Managed disks Azure container service (AKS) + registry + instances Availability Zones More Availability Zones and MSI features
Storage
Storage accounts
Encryption (deprecated) Encryption (Blob) Encryption (File)
SQL Database
Databases
Firewalls and virtual network Elastic pools Import, export, recover and restore dbs Failover groups and replication links DNS aliasing and metrics Sync groups Encryption protectors
More features
Networking
Virtual networks
Network interfaces IP addresses Routing table Network security groups Load balancers Application gateways DNS Traffic managers Network peering Virtual Network Gateway Network watchers Express Route Application Security Groups More application gateway features
More services
Resource Manager
Key Vault Redis CDN Service bus Web apps Function Apps Graph RBAC Cosmos DB Monitor Batch AI Search Event Hub Data Lake More Monitor features Logic Apps Event Grid
Fundamentals
Authentication - core
Async methods Managed Service Identity
Preview features are flagged in documentation comments in libraries. These features are subject to change. They can be modified in any way, or even removed, in the future.
The Azure class is the simplest entry point for creating and interacting with Azure resources.
IAzure azure = Azure.Authenticate(credFile).WithDefaultSubscription();To learn more about authentication in the Azure Libraries for .Net, see AUTH.md.
You can create a virtual machine instance by using a Define() … Create() method chain.
…You can update a virtual machine instance by using an Update() … Apply() method chain.
windowsVM.Update()
.WithNewDataDisk(20, lun, CachingTypes.ReadWrite)
.Apply();You can create a virtual machine scale set instance by using another Define() … Create() method chain.
…Service
Management Scenario
Virtual MachinesManage virtual machines
Manage virtual machines asynchronously
Manage availability set
List virtual machine images
Manage virtual machines using VM extensions
List virtual machine extension images
Create virtual machines from generalized image or specialized VHD
Create virtual machine using custom image from virtual machine
Create virtual machine using custom image from VHD
Create virtual machine by importing a specialized operating system disk VHD
Create virtual machine using specialized VHD from snapshot
Convert virtual machines to use managed disks
Manage virtual machine with unmanaged disks
Manage virtual machine with disks
Manage virtual machine with managed disks
Manage Azure resources from a virtual machine with system assigned managed service identity (MSI)
Manage Azure resources from a virtual machine with managed service identity (MSI) credentials
Manage Azure resources from a virtual machine with system assigned managed service identity (MSI)
Manage virtual machines in availability zones
Manage virtual machine scale sets in availability zones
List compute SKUs
Virtual Machines - parallel executionCreate multiple virtual machines in parallel
Create multiple virtual machines with network in parallel
Create multiple virtual machines across regions in parallel
Virtual Machine Scale SetsManage virtual machine scale sets (behind an Internet facing load balancer)
Manage virtual machine scale sets (behind an Internet facing load balancer) asynchronously
Manage virtual machine scale sets with unmanaged disks
You can create a virtual network by using a define() … create() method chain.
var network = networks.Define("mynetwork")
.WithRegion(Region.USEast)
.WithNewResourceGroup()
.WithAddressSpace("10.0.0.0/28")
.WithSubnet("subnet1", "10.0.0.0/29")
.WithSubnet("subnet2", "10.0.0.8/29")
.Create();You can create a network security group instance by using another Define() … Create() method chain.
…You can create a application gateway instance by using another define() … create() method chain.
…Service
Management Scenario
NetworkingManage virtual network
Manage virtual network asynchronously
Manage network interface
Manage network security group
Manage IP address
Manage Internet facing load balancers
Manage internal load balancers
Create simple Internet facing load balancer
Use net watcher
Manage network peering between two virtual networks
Use network watcher to check connectivity between virtual machines in peered networks
Manage virtual network with site-to-site VPN connection
Manage virtual network to virtual network VPN connection
Manage client to virtual network VPN connection
Create simple Internet facing load balancers
DNSHost and manage domains
Private DNSHost and manage domains with Private DNS
Traffic ManagerManage traffic manager profiles
Application GatewayManage application gateways
Manage application gateways with backend pools
Express RouteCreate and configure Express Route
You can create a Web App instance by using another define() … create() method chain.
var webApp = azure.WebApps.Define(appName)
.WithRegion(Region.USWest)
.WithNewResourceGroup(rgName)
.WithNewWindowsPlan(PricingTier.StandardS1)
.Create();Service
Management Scenario
Web Apps on WindowsManage Web apps
Manage Web apps with custom domains
Configure deployment sources for Web apps
Configure deployment sources for Web apps asynchronously
Manage staging and production slots for Web apps
Scale Web apps
Manage storage connections for Web apps
Manage data connections (such as SQL database and Redis cache) for Web apps
Manage authentication for Web apps
Safeguard Web app secrets in Key Vault
Get logs for Web apps
Web Apps on LinuxManage Web apps
Manage Web apps with custom domains
Configure deployment sources for Web apps
Scale Web apps
Manage storage connections for Web apps
Manage data connections (such as SQL database and Redis cache) for Web apps
FunctionsManage functions
Manage functions with custom domains
Configure deployment sources for functions
Manage authentication for functions
Get function logs
You can create a Cosmos DB account by using a define() … create() method chain.
var documentDBAccount = azure.CosmosDBAccounts.Define(cosmosDBName)
.WithRegion(Region.USEast)
.WithNewResourceGroup(rgName)
.WithKind(DatabaseAccountKind.GlobalDocumentDB)
.WithSessionConsistency()
.WithWriteReplication(Region.USWest)
.WithReadReplication(Region.USCentral)
.Create();You can create a SQL server instance by using another define() … create() method chain.
var sqlServer = azure.SqlServers.Define(sqlServerName)
.WithRegion(Region.USEast)
.WithNewResourceGroup(rgName)
.WithAdministratorLogin(administratorLogin)
.WithAdministratorPassword(administratorPassword)
.WithNewFirewallRule(firewallRuleIpAddress)
.WithNewFirewallRule(firewallRuleStartIpAddress, firewallRuleEndIpAddress)
.Create();Then, you can create a SQL database instance by using another define() … create() method chain.
var database = sqlServer.Databases.Define(databaseName)
.Create();Service
Management Scenario
StorageManage storage accounts
Manage storage accounts asynchronously
Manage network rules of a storage account
SQL DatabaseManage SQL databases
Manage SQL databases in elastic pools
Manage firewalls for SQL databases
Manage SQL databases across regions
Import and export SQL databases
Restore and recover SQL databases
Get SQL Database metrics
Manage SQL Database Failover Groups
Manage SQL Server DNL aliases
Manage SQL secrets (Server Keys) in Azure Key Vault
Manage SQL Virtual Network Rules
Cosmos DBCreate a CosmosDB and configure it for high availability
Create a CosmosDB and configure it with eventual consistency
Create a CosmosDB, configure it for high availability and create a firewall to limit access from an approved set of IP addresses
Create a CosmosDB and get MongoDB connection string
Create a CosmosDB configured with a virtual network rule
Service
Management Scenario
Active DirectoryManage service principals using .NET
Manage users and groups and manage their roles
Manage passwords
Manage Azure resources from a managed service identity (MSI) enabled virtual machine that belongs to an Azure Active Directory (AAD) security group
Container Service
Container Registry and Container Instances
Manage container registry
Manage container registry with Web hooks
Manage Kubernetes cluster (AKS)
Manage container service with Kubernetes orchestration
Manage container service with Docker Swarm orchestration
Create Container Group using images from a private registry
Manage Azure Container Instances with new Azure File Share
Manage Azure Container Instances with an existing Azure File Share
Create Container Group wit
暂无开放 Issues,或尚未同步最近议题。