1. Packages
  2. OVH
  3. API Docs
  4. StorageEfsShareAcl
OVHCloud v2.7.3 published on Thursday, Aug 28, 2025 by OVHcloud

ovh.StorageEfsShareAcl

Explore with Pulumi AI

ovh logo
OVHCloud v2.7.3 published on Thursday, Aug 28, 2025 by OVHcloud

    Creates an ACL rule for an EFS share.

    Please take a look at the list of available access_level values in the Required section in order to know the list of supported access level configurations.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as ovh from "@ovhcloud/pulumi-ovh";
    
    const efs = ovh.getStorageEfs({
        serviceName: "XXX",
    });
    const share = new ovh.StorageEfsShare("share", {
        serviceName: efs.then(efs => efs.serviceName),
        name: "share",
        description: "My share",
        protocol: "NFS",
        size: 100,
    });
    const acl = new ovh.StorageEfsShareAcl("acl", {
        serviceName: efs.then(efs => efs.serviceName),
        shareId: share.id,
        accessLevel: "ro",
        accessTo: "10.0.0.1",
    });
    
    import pulumi
    import pulumi_ovh as ovh
    
    efs = ovh.get_storage_efs(service_name="XXX")
    share = ovh.StorageEfsShare("share",
        service_name=efs.service_name,
        name="share",
        description="My share",
        protocol="NFS",
        size=100)
    acl = ovh.StorageEfsShareAcl("acl",
        service_name=efs.service_name,
        share_id=share.id,
        access_level="ro",
        access_to="10.0.0.1")
    
    package main
    
    import (
    	"github.com/ovh/pulumi-ovh/sdk/v2/go/ovh"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		efs, err := ovh.GetStorageEfs(ctx, &ovh.GetStorageEfsArgs{
    			ServiceName: "XXX",
    		}, nil)
    		if err != nil {
    			return err
    		}
    		share, err := ovh.NewStorageEfsShare(ctx, "share", &ovh.StorageEfsShareArgs{
    			ServiceName: pulumi.String(efs.ServiceName),
    			Name:        pulumi.String("share"),
    			Description: pulumi.String("My share"),
    			Protocol:    pulumi.String("NFS"),
    			Size:        pulumi.Float64(100),
    		})
    		if err != nil {
    			return err
    		}
    		_, err = ovh.NewStorageEfsShareAcl(ctx, "acl", &ovh.StorageEfsShareAclArgs{
    			ServiceName: pulumi.String(efs.ServiceName),
    			ShareId:     share.ID(),
    			AccessLevel: pulumi.String("ro"),
    			AccessTo:    pulumi.String("10.0.0.1"),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Ovh = Pulumi.Ovh;
    
    return await Deployment.RunAsync(() => 
    {
        var efs = Ovh.GetStorageEfs.Invoke(new()
        {
            ServiceName = "XXX",
        });
    
        var share = new Ovh.StorageEfsShare("share", new()
        {
            ServiceName = efs.Apply(getStorageEfsResult => getStorageEfsResult.ServiceName),
            Name = "share",
            Description = "My share",
            Protocol = "NFS",
            Size = 100,
        });
    
        var acl = new Ovh.StorageEfsShareAcl("acl", new()
        {
            ServiceName = efs.Apply(getStorageEfsResult => getStorageEfsResult.ServiceName),
            ShareId = share.Id,
            AccessLevel = "ro",
            AccessTo = "10.0.0.1",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.ovh.OvhFunctions;
    import com.pulumi.ovh.inputs.GetStorageEfsArgs;
    import com.ovhcloud.pulumi.ovh.StorageEfsShare;
    import com.ovhcloud.pulumi.ovh.StorageEfsShareArgs;
    import com.ovhcloud.pulumi.ovh.StorageEfsShareAcl;
    import com.ovhcloud.pulumi.ovh.StorageEfsShareAclArgs;
    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 efs = OvhFunctions.getStorageEfs(GetStorageEfsArgs.builder()
                .serviceName("XXX")
                .build());
    
            var share = new StorageEfsShare("share", StorageEfsShareArgs.builder()
                .serviceName(efs.serviceName())
                .name("share")
                .description("My share")
                .protocol("NFS")
                .size(100.0)
                .build());
    
            var acl = new StorageEfsShareAcl("acl", StorageEfsShareAclArgs.builder()
                .serviceName(efs.serviceName())
                .shareId(share.id())
                .accessLevel("ro")
                .accessTo("10.0.0.1")
                .build());
    
        }
    }
    
    resources:
      share:
        type: ovh:StorageEfsShare
        properties:
          serviceName: ${efs.serviceName}
          name: share
          description: My share
          protocol: NFS
          size: 100
      acl:
        type: ovh:StorageEfsShareAcl
        properties:
          serviceName: ${efs.serviceName}
          shareId: ${share.id}
          accessLevel: ro
          accessTo: 10.0.0.1
    variables:
      efs:
        fn::invoke:
          function: ovh:getStorageEfs
          arguments:
            serviceName: XXX
    

    Create StorageEfsShareAcl Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new StorageEfsShareAcl(name: string, args: StorageEfsShareAclArgs, opts?: CustomResourceOptions);
    @overload
    def StorageEfsShareAcl(resource_name: str,
                           args: StorageEfsShareAclArgs,
                           opts: Optional[ResourceOptions] = None)
    
    @overload
    def StorageEfsShareAcl(resource_name: str,
                           opts: Optional[ResourceOptions] = None,
                           access_level: Optional[str] = None,
                           access_to: Optional[str] = None,
                           service_name: Optional[str] = None,
                           share_id: Optional[str] = None)
    func NewStorageEfsShareAcl(ctx *Context, name string, args StorageEfsShareAclArgs, opts ...ResourceOption) (*StorageEfsShareAcl, error)
    public StorageEfsShareAcl(string name, StorageEfsShareAclArgs args, CustomResourceOptions? opts = null)
    public StorageEfsShareAcl(String name, StorageEfsShareAclArgs args)
    public StorageEfsShareAcl(String name, StorageEfsShareAclArgs args, CustomResourceOptions options)
    
    type: ovh:StorageEfsShareAcl
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args StorageEfsShareAclArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args StorageEfsShareAclArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args StorageEfsShareAclArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args StorageEfsShareAclArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args StorageEfsShareAclArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var storageEfsShareAclResource = new Ovh.StorageEfsShareAcl("storageEfsShareAclResource", new()
    {
        AccessLevel = "string",
        AccessTo = "string",
        ServiceName = "string",
        ShareId = "string",
    });
    
    example, err := ovh.NewStorageEfsShareAcl(ctx, "storageEfsShareAclResource", &ovh.StorageEfsShareAclArgs{
    	AccessLevel: pulumi.String("string"),
    	AccessTo:    pulumi.String("string"),
    	ServiceName: pulumi.String("string"),
    	ShareId:     pulumi.String("string"),
    })
    
    var storageEfsShareAclResource = new StorageEfsShareAcl("storageEfsShareAclResource", StorageEfsShareAclArgs.builder()
        .accessLevel("string")
        .accessTo("string")
        .serviceName("string")
        .shareId("string")
        .build());
    
    storage_efs_share_acl_resource = ovh.StorageEfsShareAcl("storageEfsShareAclResource",
        access_level="string",
        access_to="string",
        service_name="string",
        share_id="string")
    
    const storageEfsShareAclResource = new ovh.StorageEfsShareAcl("storageEfsShareAclResource", {
        accessLevel: "string",
        accessTo: "string",
        serviceName: "string",
        shareId: "string",
    });
    
    type: ovh:StorageEfsShareAcl
    properties:
        accessLevel: string
        accessTo: string
        serviceName: string
        shareId: string
    

    StorageEfsShareAcl Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

    The StorageEfsShareAcl resource accepts the following input properties:

    AccessLevel string
    Rule access level
    AccessTo string
    Rule destination
    ServiceName string
    Service name
    ShareId string
    Share ID
    AccessLevel string
    Rule access level
    AccessTo string
    Rule destination
    ServiceName string
    Service name
    ShareId string
    Share ID
    accessLevel String
    Rule access level
    accessTo String
    Rule destination
    serviceName String
    Service name
    shareId String
    Share ID
    accessLevel string
    Rule access level
    accessTo string
    Rule destination
    serviceName string
    Service name
    shareId string
    Share ID
    access_level str
    Rule access level
    access_to str
    Rule destination
    service_name str
    Service name
    share_id str
    Share ID
    accessLevel String
    Rule access level
    accessTo String
    Rule destination
    serviceName String
    Service name
    shareId String
    Share ID

    Outputs

    All input properties are implicitly available as output properties. Additionally, the StorageEfsShareAcl resource produces the following output properties:

    AccessType string
    Rule access type
    CreatedAt string
    Rule creation date
    Id string
    The provider-assigned unique ID for this managed resource.
    Status string
    Rule status
    AccessType string
    Rule access type
    CreatedAt string
    Rule creation date
    Id string
    The provider-assigned unique ID for this managed resource.
    Status string
    Rule status
    accessType String
    Rule access type
    createdAt String
    Rule creation date
    id String
    The provider-assigned unique ID for this managed resource.
    status String
    Rule status
    accessType string
    Rule access type
    createdAt string
    Rule creation date
    id string
    The provider-assigned unique ID for this managed resource.
    status string
    Rule status
    access_type str
    Rule access type
    created_at str
    Rule creation date
    id str
    The provider-assigned unique ID for this managed resource.
    status str
    Rule status
    accessType String
    Rule access type
    createdAt String
    Rule creation date
    id String
    The provider-assigned unique ID for this managed resource.
    status String
    Rule status

    Look up Existing StorageEfsShareAcl Resource

    Get an existing StorageEfsShareAcl resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

    public static get(name: string, id: Input<ID>, state?: StorageEfsShareAclState, opts?: CustomResourceOptions): StorageEfsShareAcl
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            access_level: Optional[str] = None,
            access_to: Optional[str] = None,
            access_type: Optional[str] = None,
            created_at: Optional[str] = None,
            service_name: Optional[str] = None,
            share_id: Optional[str] = None,
            status: Optional[str] = None) -> StorageEfsShareAcl
    func GetStorageEfsShareAcl(ctx *Context, name string, id IDInput, state *StorageEfsShareAclState, opts ...ResourceOption) (*StorageEfsShareAcl, error)
    public static StorageEfsShareAcl Get(string name, Input<string> id, StorageEfsShareAclState? state, CustomResourceOptions? opts = null)
    public static StorageEfsShareAcl get(String name, Output<String> id, StorageEfsShareAclState state, CustomResourceOptions options)
    resources:  _:    type: ovh:StorageEfsShareAcl    get:      id: ${id}
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    AccessLevel string
    Rule access level
    AccessTo string
    Rule destination
    AccessType string
    Rule access type
    CreatedAt string
    Rule creation date
    ServiceName string
    Service name
    ShareId string
    Share ID
    Status string
    Rule status
    AccessLevel string
    Rule access level
    AccessTo string
    Rule destination
    AccessType string
    Rule access type
    CreatedAt string
    Rule creation date
    ServiceName string
    Service name
    ShareId string
    Share ID
    Status string
    Rule status
    accessLevel String
    Rule access level
    accessTo String
    Rule destination
    accessType String
    Rule access type
    createdAt String
    Rule creation date
    serviceName String
    Service name
    shareId String
    Share ID
    status String
    Rule status
    accessLevel string
    Rule access level
    accessTo string
    Rule destination
    accessType string
    Rule access type
    createdAt string
    Rule creation date
    serviceName string
    Service name
    shareId string
    Share ID
    status string
    Rule status
    access_level str
    Rule access level
    access_to str
    Rule destination
    access_type str
    Rule access type
    created_at str
    Rule creation date
    service_name str
    Service name
    share_id str
    Share ID
    status str
    Rule status
    accessLevel String
    Rule access level
    accessTo String
    Rule destination
    accessType String
    Rule access type
    createdAt String
    Rule creation date
    serviceName String
    Service name
    shareId String
    Share ID
    status String
    Rule status

    Package Details

    Repository
    ovh ovh/pulumi-ovh
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the ovh Terraform Provider.
    ovh logo
    OVHCloud v2.7.3 published on Thursday, Aug 28, 2025 by OVHcloud