Alibaba Cloud v3.66.0 published on Friday, Nov 15, 2024 by Pulumi
alicloud.ecs.getEcsNetworkInterfacePermissions
Explore with Pulumi AI
This data source provides the Ecs Network Interface Permissions of the current Alibaba Cloud user.
NOTE: Available in v1.166.0+.
Example Usage
Basic Usage
import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";
const ids = alicloud.ecs.getEcsNetworkInterfacePermissions({
ids: ["example_value"],
networkInterfaceId: "example_value",
});
export const ecsNetworkInterfacePermissionId1 = ids.then(ids => ids.permissions?.[0]?.id);
import pulumi
import pulumi_alicloud as alicloud
ids = alicloud.ecs.get_ecs_network_interface_permissions(ids=["example_value"],
network_interface_id="example_value")
pulumi.export("ecsNetworkInterfacePermissionId1", ids.permissions[0].id)
package main
import (
"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/ecs"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
ids, err := ecs.GetEcsNetworkInterfacePermissions(ctx, &ecs.GetEcsNetworkInterfacePermissionsArgs{
Ids: []string{
"example_value",
},
NetworkInterfaceId: "example_value",
}, nil)
if err != nil {
return err
}
ctx.Export("ecsNetworkInterfacePermissionId1", ids.Permissions[0].Id)
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AliCloud = Pulumi.AliCloud;
return await Deployment.RunAsync(() =>
{
var ids = AliCloud.Ecs.GetEcsNetworkInterfacePermissions.Invoke(new()
{
Ids = new[]
{
"example_value",
},
NetworkInterfaceId = "example_value",
});
return new Dictionary<string, object?>
{
["ecsNetworkInterfacePermissionId1"] = ids.Apply(getEcsNetworkInterfacePermissionsResult => getEcsNetworkInterfacePermissionsResult.Permissions[0]?.Id),
};
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.ecs.EcsFunctions;
import com.pulumi.alicloud.ecs.inputs.GetEcsNetworkInterfacePermissionsArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
final var ids = EcsFunctions.getEcsNetworkInterfacePermissions(GetEcsNetworkInterfacePermissionsArgs.builder()
.ids("example_value")
.networkInterfaceId("example_value")
.build());
ctx.export("ecsNetworkInterfacePermissionId1", ids.applyValue(getEcsNetworkInterfacePermissionsResult -> getEcsNetworkInterfacePermissionsResult.permissions()[0].id()));
}
}
variables:
ids:
fn::invoke:
Function: alicloud:ecs:getEcsNetworkInterfacePermissions
Arguments:
ids:
- example_value
networkInterfaceId: example_value
outputs:
ecsNetworkInterfacePermissionId1: ${ids.permissions[0].id}
Using getEcsNetworkInterfacePermissions
Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.
function getEcsNetworkInterfacePermissions(args: GetEcsNetworkInterfacePermissionsArgs, opts?: InvokeOptions): Promise<GetEcsNetworkInterfacePermissionsResult>
function getEcsNetworkInterfacePermissionsOutput(args: GetEcsNetworkInterfacePermissionsOutputArgs, opts?: InvokeOptions): Output<GetEcsNetworkInterfacePermissionsResult>
def get_ecs_network_interface_permissions(ids: Optional[Sequence[str]] = None,
network_interface_id: Optional[str] = None,
output_file: Optional[str] = None,
page_number: Optional[int] = None,
page_size: Optional[int] = None,
status: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetEcsNetworkInterfacePermissionsResult
def get_ecs_network_interface_permissions_output(ids: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
network_interface_id: Optional[pulumi.Input[str]] = None,
output_file: Optional[pulumi.Input[str]] = None,
page_number: Optional[pulumi.Input[int]] = None,
page_size: Optional[pulumi.Input[int]] = None,
status: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetEcsNetworkInterfacePermissionsResult]
func GetEcsNetworkInterfacePermissions(ctx *Context, args *GetEcsNetworkInterfacePermissionsArgs, opts ...InvokeOption) (*GetEcsNetworkInterfacePermissionsResult, error)
func GetEcsNetworkInterfacePermissionsOutput(ctx *Context, args *GetEcsNetworkInterfacePermissionsOutputArgs, opts ...InvokeOption) GetEcsNetworkInterfacePermissionsResultOutput
> Note: This function is named GetEcsNetworkInterfacePermissions
in the Go SDK.
public static class GetEcsNetworkInterfacePermissions
{
public static Task<GetEcsNetworkInterfacePermissionsResult> InvokeAsync(GetEcsNetworkInterfacePermissionsArgs args, InvokeOptions? opts = null)
public static Output<GetEcsNetworkInterfacePermissionsResult> Invoke(GetEcsNetworkInterfacePermissionsInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetEcsNetworkInterfacePermissionsResult> getEcsNetworkInterfacePermissions(GetEcsNetworkInterfacePermissionsArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: alicloud:ecs/getEcsNetworkInterfacePermissions:getEcsNetworkInterfacePermissions
arguments:
# arguments dictionary
The following arguments are supported:
- Network
Interface stringId - The ID of the network interface.
- Ids List<string>
- A list of Network Interface Permission IDs.
- Output
File string - File name where to save data source results (after running
pulumi preview
). - Page
Number int - Page
Size int - Status string
- The Status of the Network Interface Permissions. Valid values:
Granted
,Pending
,Revoked
,Revoking
.
- Network
Interface stringId - The ID of the network interface.
- Ids []string
- A list of Network Interface Permission IDs.
- Output
File string - File name where to save data source results (after running
pulumi preview
). - Page
Number int - Page
Size int - Status string
- The Status of the Network Interface Permissions. Valid values:
Granted
,Pending
,Revoked
,Revoking
.
- network
Interface StringId - The ID of the network interface.
- ids List<String>
- A list of Network Interface Permission IDs.
- output
File String - File name where to save data source results (after running
pulumi preview
). - page
Number Integer - page
Size Integer - status String
- The Status of the Network Interface Permissions. Valid values:
Granted
,Pending
,Revoked
,Revoking
.
- network
Interface stringId - The ID of the network interface.
- ids string[]
- A list of Network Interface Permission IDs.
- output
File string - File name where to save data source results (after running
pulumi preview
). - page
Number number - page
Size number - status string
- The Status of the Network Interface Permissions. Valid values:
Granted
,Pending
,Revoked
,Revoking
.
- network_
interface_ strid - The ID of the network interface.
- ids Sequence[str]
- A list of Network Interface Permission IDs.
- output_
file str - File name where to save data source results (after running
pulumi preview
). - page_
number int - page_
size int - status str
- The Status of the Network Interface Permissions. Valid values:
Granted
,Pending
,Revoked
,Revoking
.
- network
Interface StringId - The ID of the network interface.
- ids List<String>
- A list of Network Interface Permission IDs.
- output
File String - File name where to save data source results (after running
pulumi preview
). - page
Number Number - page
Size Number - status String
- The Status of the Network Interface Permissions. Valid values:
Granted
,Pending
,Revoked
,Revoking
.
getEcsNetworkInterfacePermissions Result
The following output properties are available:
- Id string
- The provider-assigned unique ID for this managed resource.
- Ids List<string>
- Network
Interface stringId - Permissions
List<Pulumi.
Ali Cloud. Ecs. Outputs. Get Ecs Network Interface Permissions Permission> - Total
Count int - Output
File string - Page
Number int - Page
Size int - Status string
- Id string
- The provider-assigned unique ID for this managed resource.
- Ids []string
- Network
Interface stringId - Permissions
[]Get
Ecs Network Interface Permissions Permission - Total
Count int - Output
File string - Page
Number int - Page
Size int - Status string
- id String
- The provider-assigned unique ID for this managed resource.
- ids List<String>
- network
Interface StringId - permissions
List<Get
Ecs Network Interface Permissions Permission> - total
Count Integer - output
File String - page
Number Integer - page
Size Integer - status String
- id string
- The provider-assigned unique ID for this managed resource.
- ids string[]
- network
Interface stringId - permissions
Get
Ecs Network Interface Permissions Permission[] - total
Count number - output
File string - page
Number number - page
Size number - status string
- id str
- The provider-assigned unique ID for this managed resource.
- ids Sequence[str]
- network_
interface_ strid - permissions
Sequence[Get
Ecs Network Interface Permissions Permission] - total_
count int - output_
file str - page_
number int - page_
size int - status str
- id String
- The provider-assigned unique ID for this managed resource.
- ids List<String>
- network
Interface StringId - permissions List<Property Map>
- total
Count Number - output
File String - page
Number Number - page
Size Number - status String
Supporting Types
GetEcsNetworkInterfacePermissionsPermission
- Account
Id string - Alibaba Cloud Partner (Certified ISV) account ID or individual user ID.
- Id string
- The ID of the Network Interface Permission.
- Network
Interface stringId - The ID of the network interface.
- Network
Interface stringPermission Id - The ID of the Network Interface Permissions.
- Permission string
- The permissions of the Network Interface.
- Service
Name string - Alibaba Cloud service name.
- Status string
- The Status of the Network Interface Permissions.
- Account
Id string - Alibaba Cloud Partner (Certified ISV) account ID or individual user ID.
- Id string
- The ID of the Network Interface Permission.
- Network
Interface stringId - The ID of the network interface.
- Network
Interface stringPermission Id - The ID of the Network Interface Permissions.
- Permission string
- The permissions of the Network Interface.
- Service
Name string - Alibaba Cloud service name.
- Status string
- The Status of the Network Interface Permissions.
- account
Id String - Alibaba Cloud Partner (Certified ISV) account ID or individual user ID.
- id String
- The ID of the Network Interface Permission.
- network
Interface StringId - The ID of the network interface.
- network
Interface StringPermission Id - The ID of the Network Interface Permissions.
- permission String
- The permissions of the Network Interface.
- service
Name String - Alibaba Cloud service name.
- status String
- The Status of the Network Interface Permissions.
- account
Id string - Alibaba Cloud Partner (Certified ISV) account ID or individual user ID.
- id string
- The ID of the Network Interface Permission.
- network
Interface stringId - The ID of the network interface.
- network
Interface stringPermission Id - The ID of the Network Interface Permissions.
- permission string
- The permissions of the Network Interface.
- service
Name string - Alibaba Cloud service name.
- status string
- The Status of the Network Interface Permissions.
- account_
id str - Alibaba Cloud Partner (Certified ISV) account ID or individual user ID.
- id str
- The ID of the Network Interface Permission.
- network_
interface_ strid - The ID of the network interface.
- network_
interface_ strpermission_ id - The ID of the Network Interface Permissions.
- permission str
- The permissions of the Network Interface.
- service_
name str - Alibaba Cloud service name.
- status str
- The Status of the Network Interface Permissions.
- account
Id String - Alibaba Cloud Partner (Certified ISV) account ID or individual user ID.
- id String
- The ID of the Network Interface Permission.
- network
Interface StringId - The ID of the network interface.
- network
Interface StringPermission Id - The ID of the Network Interface Permissions.
- permission String
- The permissions of the Network Interface.
- service
Name String - Alibaba Cloud service name.
- status String
- The Status of the Network Interface Permissions.
Package Details
- Repository
- Alibaba Cloud pulumi/pulumi-alicloud
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
alicloud
Terraform Provider.