Example usage for com.amazonaws.services.ec2 AmazonEC2AsyncClient authorizeSecurityGroupEgress

List of usage examples for com.amazonaws.services.ec2 AmazonEC2AsyncClient authorizeSecurityGroupEgress

Introduction

In this page you can find the example usage for com.amazonaws.services.ec2 AmazonEC2AsyncClient authorizeSecurityGroupEgress.

Prototype

AuthorizeSecurityGroupEgressResult authorizeSecurityGroupEgress(
        AuthorizeSecurityGroupEgressRequest authorizeSecurityGroupEgressRequest);

Source Link

Document

[VPC only] Adds the specified egress rules to a security group for use with a VPC.

Usage

From source file:com.vmware.photon.controller.model.adapters.awsadapter.AWSFirewallService.java

License:Open Source License

public void updateEgressRules(AmazonEC2AsyncClient client, String groupId, List<IpPermission> rules) {
    AuthorizeSecurityGroupEgressRequest req = new AuthorizeSecurityGroupEgressRequest().withGroupId(groupId)
            .withIpPermissions(rules);//from   ww  w  .  ja v  a 2s .  com
    client.authorizeSecurityGroupEgress(req);
}