java - Java Azure SDK,如何删除网络接口中的辅助 IP?
解决方案
关于这个问题,请参考下面的cdoe
创建服务主体并将 Azure RABC 角色分配给Contributor
sp
开发工具包
<dependency>
<groupId>com.microsoft.azure</groupId>
<artifactId>azure</artifactId>
<version>1.38.1</version>
</dependency>
代码
String clientId="232a1***";
String clientSecret="?****";
String tenant="e***";
String subId="e*****";
ApplicationTokenCredentials credentials = new ApplicationTokenCredentials(clientId,
tenant,
clientSecret,
AzureEnvironment.AZURE);
Azure azure= Azure.configure()
.withLogLevel(LogLevel.BODY_AND_HEADERS)
.authenticate(credentials)
.withSubscription(subId);
NetworkInterface nic = azure.networkInterfaces().getByResourceGroup("andywin7","testnic");
nic.update().withoutIPConfiguration("ipconfig2")
.apply();
推荐阅读
- ms-access - 使用 MS-Access 和 VBA 时如何确定 SharePoint 是否在线
- python - url请求Python超出了最大重试次数
- python-3.x - “Image.fromarray”在大尺寸图像中导致“OverflowError:size does not fit in an int”错误
- javascript - 添加和删除子元素
- linux - 如何使用该 Ubuntu 服务器自动/定期将文件从 FTP 服务器复制到不同的 Ubuntu 服务器?
- computational-geometry - 点云更新的最佳数据结构?
- python-3.x - 希望创建一种有效的方式来显示非二叉树结构
- python - TypeError: load() 接受 1 个位置参数,但给出了 2 个。tensorflowjs 转换器错误
- java - 下载的视频无法在 Android 版本 <= 6.1 上播放
- ksh - 制表符完成第二个命令