• [Azure][PowerShell][ASM][12]ACL


    $mySubscriptionName="运维环境"

    Select-AzureSubscription -SubscriptionName $mySubscriptionName 

     

    $myServiceName="云服务名称"

    $myVMName="虚拟机名称"

    $myEndPoint="终结点名称"

    $myACL=New-AzureAclConfig

    $myRemoteSubnet="x.x.x.x/32"

    $myDescription="描述"

    $myID=0

    $myACL = Get-AzureVM -ServiceName $myServiceName -Name $myVMName | Get-AzureAclConfig -EndpointName $myEndPoint

    $myNewACLs=

    ( "x.x.x.x/32","描述"),

    ( "x.x.x.x/32","描述"),

    ( "x.x.x.x/32","描述"),

    ( "x.x.x.x/32","描述"),

    ( "x.x.x.x/32","描述"),

    ( "x.x.x.x/32","描述")

    foreach($myNewACL in $myNewACLs)

    {

    Set-AzureAclConfig -AddRule -ACL $myACL -Order $myID -Action Permit -RemoteSubnet $myNewACL[0] -Description $myNewACL[1]

    $myID=$myID + 1

    }

    #$remoteSubnet="172.0.0.0/8"

    #$description="20"

    # Set-AzureAclConfig -AddRule -ACL $myACL -Order $myID -Action Permit -RemoteSubnet $myRemoteSubnet -Description $myDescription

    Get-AzureVM -ServiceName $myServiceName -Name $myVMName | Set-AzureEndpoint -ACL $myACL -Name $myEndPoint | Update-AzureVM

  • 相关阅读:
    【贪心+前缀】C. Fountains
    优雅降级和渐进增强
    px和em
    src与href
    css 浮动
    CSS权重及样式优先级问题
    css样式初始化
    品字布局设计
    CSS3新特性
    inline-block的简单理解
  • 原文地址:https://www.cnblogs.com/wuzhenzhou/p/6909665.html
Copyright © 2020-2023  润新知