1. Packages
  2. Aiven
  3. API Docs
  4. OpensearchSecurityPluginConfig
Aiven v6.13.0 published on Monday, Mar 25, 2024 by Pulumi

aiven.OpensearchSecurityPluginConfig

Explore with Pulumi AI

aiven logo
Aiven v6.13.0 published on Monday, Mar 25, 2024 by Pulumi

    The OpenSearch Security Plugin Config resource allows the creation and management of AivenOpenSearch Security Plugin config.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as aiven from "@pulumi/aiven";
    
    const fooProject = aiven.getProject({
        project: "example_project",
    });
    const bar = new aiven.OpenSearch("bar", {
        project: fooProject.then(fooProject => fooProject.project),
        cloudName: "google-europe-west1",
        plan: "startup-4",
        serviceName: "example_service_name",
        maintenanceWindowDow: "monday",
        maintenanceWindowTime: "10:00:00",
    });
    const fooOpensearchUser = new aiven.OpensearchUser("fooOpensearchUser", {
        serviceName: bar.serviceName,
        project: fooProject.then(fooProject => fooProject.project),
        username: "user-example",
    });
    const fooOpensearchSecurityPluginConfig = new aiven.OpensearchSecurityPluginConfig("fooOpensearchSecurityPluginConfig", {
        project: fooProject.then(fooProject => fooProject.project),
        serviceName: bar.serviceName,
        adminPassword: "ThisIsATest123^=^",
    });
    
    import pulumi
    import pulumi_aiven as aiven
    
    foo_project = aiven.get_project(project="example_project")
    bar = aiven.OpenSearch("bar",
        project=foo_project.project,
        cloud_name="google-europe-west1",
        plan="startup-4",
        service_name="example_service_name",
        maintenance_window_dow="monday",
        maintenance_window_time="10:00:00")
    foo_opensearch_user = aiven.OpensearchUser("fooOpensearchUser",
        service_name=bar.service_name,
        project=foo_project.project,
        username="user-example")
    foo_opensearch_security_plugin_config = aiven.OpensearchSecurityPluginConfig("fooOpensearchSecurityPluginConfig",
        project=foo_project.project,
        service_name=bar.service_name,
        admin_password="ThisIsATest123^=^")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-aiven/sdk/v6/go/aiven"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		fooProject, err := aiven.LookupProject(ctx, &aiven.LookupProjectArgs{
    			Project: "example_project",
    		}, nil)
    		if err != nil {
    			return err
    		}
    		bar, err := aiven.NewOpenSearch(ctx, "bar", &aiven.OpenSearchArgs{
    			Project:               pulumi.String(fooProject.Project),
    			CloudName:             pulumi.String("google-europe-west1"),
    			Plan:                  pulumi.String("startup-4"),
    			ServiceName:           pulumi.String("example_service_name"),
    			MaintenanceWindowDow:  pulumi.String("monday"),
    			MaintenanceWindowTime: pulumi.String("10:00:00"),
    		})
    		if err != nil {
    			return err
    		}
    		_, err = aiven.NewOpensearchUser(ctx, "fooOpensearchUser", &aiven.OpensearchUserArgs{
    			ServiceName: bar.ServiceName,
    			Project:     pulumi.String(fooProject.Project),
    			Username:    pulumi.String("user-example"),
    		})
    		if err != nil {
    			return err
    		}
    		_, err = aiven.NewOpensearchSecurityPluginConfig(ctx, "fooOpensearchSecurityPluginConfig", &aiven.OpensearchSecurityPluginConfigArgs{
    			Project:       pulumi.String(fooProject.Project),
    			ServiceName:   bar.ServiceName,
    			AdminPassword: pulumi.String("ThisIsATest123^=^"),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Aiven = Pulumi.Aiven;
    
    return await Deployment.RunAsync(() => 
    {
        var fooProject = Aiven.GetProject.Invoke(new()
        {
            Project = "example_project",
        });
    
        var bar = new Aiven.OpenSearch("bar", new()
        {
            Project = fooProject.Apply(getProjectResult => getProjectResult.Project),
            CloudName = "google-europe-west1",
            Plan = "startup-4",
            ServiceName = "example_service_name",
            MaintenanceWindowDow = "monday",
            MaintenanceWindowTime = "10:00:00",
        });
    
        var fooOpensearchUser = new Aiven.OpensearchUser("fooOpensearchUser", new()
        {
            ServiceName = bar.ServiceName,
            Project = fooProject.Apply(getProjectResult => getProjectResult.Project),
            Username = "user-example",
        });
    
        var fooOpensearchSecurityPluginConfig = new Aiven.OpensearchSecurityPluginConfig("fooOpensearchSecurityPluginConfig", new()
        {
            Project = fooProject.Apply(getProjectResult => getProjectResult.Project),
            ServiceName = bar.ServiceName,
            AdminPassword = "ThisIsATest123^=^",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.aiven.AivenFunctions;
    import com.pulumi.aiven.inputs.GetProjectArgs;
    import com.pulumi.aiven.OpenSearch;
    import com.pulumi.aiven.OpenSearchArgs;
    import com.pulumi.aiven.OpensearchUser;
    import com.pulumi.aiven.OpensearchUserArgs;
    import com.pulumi.aiven.OpensearchSecurityPluginConfig;
    import com.pulumi.aiven.OpensearchSecurityPluginConfigArgs;
    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 fooProject = AivenFunctions.getProject(GetProjectArgs.builder()
                .project("example_project")
                .build());
    
            var bar = new OpenSearch("bar", OpenSearchArgs.builder()        
                .project(fooProject.applyValue(getProjectResult -> getProjectResult.project()))
                .cloudName("google-europe-west1")
                .plan("startup-4")
                .serviceName("example_service_name")
                .maintenanceWindowDow("monday")
                .maintenanceWindowTime("10:00:00")
                .build());
    
            var fooOpensearchUser = new OpensearchUser("fooOpensearchUser", OpensearchUserArgs.builder()        
                .serviceName(bar.serviceName())
                .project(fooProject.applyValue(getProjectResult -> getProjectResult.project()))
                .username("user-example")
                .build());
    
            var fooOpensearchSecurityPluginConfig = new OpensearchSecurityPluginConfig("fooOpensearchSecurityPluginConfig", OpensearchSecurityPluginConfigArgs.builder()        
                .project(fooProject.applyValue(getProjectResult -> getProjectResult.project()))
                .serviceName(bar.serviceName())
                .adminPassword("ThisIsATest123^=^")
                .build());
    
        }
    }
    
    resources:
      bar:
        type: aiven:OpenSearch
        properties:
          project: ${fooProject.project}
          cloudName: google-europe-west1
          plan: startup-4
          serviceName: example_service_name
          maintenanceWindowDow: monday
          maintenanceWindowTime: 10:00:00
      fooOpensearchUser:
        type: aiven:OpensearchUser
        properties:
          serviceName: ${bar.serviceName}
          project: ${fooProject.project}
          username: user-example
      fooOpensearchSecurityPluginConfig:
        type: aiven:OpensearchSecurityPluginConfig
        properties:
          project: ${fooProject.project}
          serviceName: ${bar.serviceName}
          adminPassword: ThisIsATest123^=^
    variables:
      fooProject:
        fn::invoke:
          Function: aiven:getProject
          Arguments:
            project: example_project
    

    Create OpensearchSecurityPluginConfig Resource

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

    Constructor syntax

    new OpensearchSecurityPluginConfig(name: string, args: OpensearchSecurityPluginConfigArgs, opts?: CustomResourceOptions);
    @overload
    def OpensearchSecurityPluginConfig(resource_name: str,
                                       args: OpensearchSecurityPluginConfigArgs,
                                       opts: Optional[ResourceOptions] = None)
    
    @overload
    def OpensearchSecurityPluginConfig(resource_name: str,
                                       opts: Optional[ResourceOptions] = None,
                                       admin_password: Optional[str] = None,
                                       project: Optional[str] = None,
                                       service_name: Optional[str] = None)
    func NewOpensearchSecurityPluginConfig(ctx *Context, name string, args OpensearchSecurityPluginConfigArgs, opts ...ResourceOption) (*OpensearchSecurityPluginConfig, error)
    public OpensearchSecurityPluginConfig(string name, OpensearchSecurityPluginConfigArgs args, CustomResourceOptions? opts = null)
    public OpensearchSecurityPluginConfig(String name, OpensearchSecurityPluginConfigArgs args)
    public OpensearchSecurityPluginConfig(String name, OpensearchSecurityPluginConfigArgs args, CustomResourceOptions options)
    
    type: aiven:OpensearchSecurityPluginConfig
    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 OpensearchSecurityPluginConfigArgs
    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 OpensearchSecurityPluginConfigArgs
    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 OpensearchSecurityPluginConfigArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args OpensearchSecurityPluginConfigArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args OpensearchSecurityPluginConfigArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Example

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

    var opensearchSecurityPluginConfigResource = new Aiven.OpensearchSecurityPluginConfig("opensearchSecurityPluginConfigResource", new()
    {
        AdminPassword = "string",
        Project = "string",
        ServiceName = "string",
    });
    
    example, err := aiven.NewOpensearchSecurityPluginConfig(ctx, "opensearchSecurityPluginConfigResource", &aiven.OpensearchSecurityPluginConfigArgs{
    	AdminPassword: pulumi.String("string"),
    	Project:       pulumi.String("string"),
    	ServiceName:   pulumi.String("string"),
    })
    
    var opensearchSecurityPluginConfigResource = new OpensearchSecurityPluginConfig("opensearchSecurityPluginConfigResource", OpensearchSecurityPluginConfigArgs.builder()        
        .adminPassword("string")
        .project("string")
        .serviceName("string")
        .build());
    
    opensearch_security_plugin_config_resource = aiven.OpensearchSecurityPluginConfig("opensearchSecurityPluginConfigResource",
        admin_password="string",
        project="string",
        service_name="string")
    
    const opensearchSecurityPluginConfigResource = new aiven.OpensearchSecurityPluginConfig("opensearchSecurityPluginConfigResource", {
        adminPassword: "string",
        project: "string",
        serviceName: "string",
    });
    
    type: aiven:OpensearchSecurityPluginConfig
    properties:
        adminPassword: string
        project: string
        serviceName: string
    

    OpensearchSecurityPluginConfig Resource Properties

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

    Inputs

    The OpensearchSecurityPluginConfig resource accepts the following input properties:

    AdminPassword string
    The password for the os-sec-admin user.
    Project string
    Identifies the project this resource belongs to. To set up proper dependencies please refer to this variable as a reference. Changing this property forces recreation of the resource.
    ServiceName string
    Specifies the name of the service that this resource belongs to. To set up proper dependencies please refer to this variable as a reference. Changing this property forces recreation of the resource.
    AdminPassword string
    The password for the os-sec-admin user.
    Project string
    Identifies the project this resource belongs to. To set up proper dependencies please refer to this variable as a reference. Changing this property forces recreation of the resource.
    ServiceName string
    Specifies the name of the service that this resource belongs to. To set up proper dependencies please refer to this variable as a reference. Changing this property forces recreation of the resource.
    adminPassword String
    The password for the os-sec-admin user.
    project String
    Identifies the project this resource belongs to. To set up proper dependencies please refer to this variable as a reference. Changing this property forces recreation of the resource.
    serviceName String
    Specifies the name of the service that this resource belongs to. To set up proper dependencies please refer to this variable as a reference. Changing this property forces recreation of the resource.
    adminPassword string
    The password for the os-sec-admin user.
    project string
    Identifies the project this resource belongs to. To set up proper dependencies please refer to this variable as a reference. Changing this property forces recreation of the resource.
    serviceName string
    Specifies the name of the service that this resource belongs to. To set up proper dependencies please refer to this variable as a reference. Changing this property forces recreation of the resource.
    admin_password str
    The password for the os-sec-admin user.
    project str
    Identifies the project this resource belongs to. To set up proper dependencies please refer to this variable as a reference. Changing this property forces recreation of the resource.
    service_name str
    Specifies the name of the service that this resource belongs to. To set up proper dependencies please refer to this variable as a reference. Changing this property forces recreation of the resource.
    adminPassword String
    The password for the os-sec-admin user.
    project String
    Identifies the project this resource belongs to. To set up proper dependencies please refer to this variable as a reference. Changing this property forces recreation of the resource.
    serviceName String
    Specifies the name of the service that this resource belongs to. To set up proper dependencies please refer to this variable as a reference. Changing this property forces recreation of the resource.

    Outputs

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

    AdminEnabled bool
    Whether the os-sec-admin user is enabled. This indicates whether the user management with the security plugin is enabled. This is always true when the os-sec-admin password was set at least once.
    Available bool
    Whether the security plugin is available. This is always true for recently created services.
    Enabled bool
    Whether the security plugin is enabled. This is always true for recently created services.
    Id string
    The provider-assigned unique ID for this managed resource.
    AdminEnabled bool
    Whether the os-sec-admin user is enabled. This indicates whether the user management with the security plugin is enabled. This is always true when the os-sec-admin password was set at least once.
    Available bool
    Whether the security plugin is available. This is always true for recently created services.
    Enabled bool
    Whether the security plugin is enabled. This is always true for recently created services.
    Id string
    The provider-assigned unique ID for this managed resource.
    adminEnabled Boolean
    Whether the os-sec-admin user is enabled. This indicates whether the user management with the security plugin is enabled. This is always true when the os-sec-admin password was set at least once.
    available Boolean
    Whether the security plugin is available. This is always true for recently created services.
    enabled Boolean
    Whether the security plugin is enabled. This is always true for recently created services.
    id String
    The provider-assigned unique ID for this managed resource.
    adminEnabled boolean
    Whether the os-sec-admin user is enabled. This indicates whether the user management with the security plugin is enabled. This is always true when the os-sec-admin password was set at least once.
    available boolean
    Whether the security plugin is available. This is always true for recently created services.
    enabled boolean
    Whether the security plugin is enabled. This is always true for recently created services.
    id string
    The provider-assigned unique ID for this managed resource.
    admin_enabled bool
    Whether the os-sec-admin user is enabled. This indicates whether the user management with the security plugin is enabled. This is always true when the os-sec-admin password was set at least once.
    available bool
    Whether the security plugin is available. This is always true for recently created services.
    enabled bool
    Whether the security plugin is enabled. This is always true for recently created services.
    id str
    The provider-assigned unique ID for this managed resource.
    adminEnabled Boolean
    Whether the os-sec-admin user is enabled. This indicates whether the user management with the security plugin is enabled. This is always true when the os-sec-admin password was set at least once.
    available Boolean
    Whether the security plugin is available. This is always true for recently created services.
    enabled Boolean
    Whether the security plugin is enabled. This is always true for recently created services.
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing OpensearchSecurityPluginConfig Resource

    Get an existing OpensearchSecurityPluginConfig 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?: OpensearchSecurityPluginConfigState, opts?: CustomResourceOptions): OpensearchSecurityPluginConfig
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            admin_enabled: Optional[bool] = None,
            admin_password: Optional[str] = None,
            available: Optional[bool] = None,
            enabled: Optional[bool] = None,
            project: Optional[str] = None,
            service_name: Optional[str] = None) -> OpensearchSecurityPluginConfig
    func GetOpensearchSecurityPluginConfig(ctx *Context, name string, id IDInput, state *OpensearchSecurityPluginConfigState, opts ...ResourceOption) (*OpensearchSecurityPluginConfig, error)
    public static OpensearchSecurityPluginConfig Get(string name, Input<string> id, OpensearchSecurityPluginConfigState? state, CustomResourceOptions? opts = null)
    public static OpensearchSecurityPluginConfig get(String name, Output<String> id, OpensearchSecurityPluginConfigState state, CustomResourceOptions options)
    Resource lookup is not supported in YAML
    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:
    AdminEnabled bool
    Whether the os-sec-admin user is enabled. This indicates whether the user management with the security plugin is enabled. This is always true when the os-sec-admin password was set at least once.
    AdminPassword string
    The password for the os-sec-admin user.
    Available bool
    Whether the security plugin is available. This is always true for recently created services.
    Enabled bool
    Whether the security plugin is enabled. This is always true for recently created services.
    Project string
    Identifies the project this resource belongs to. To set up proper dependencies please refer to this variable as a reference. Changing this property forces recreation of the resource.
    ServiceName string
    Specifies the name of the service that this resource belongs to. To set up proper dependencies please refer to this variable as a reference. Changing this property forces recreation of the resource.
    AdminEnabled bool
    Whether the os-sec-admin user is enabled. This indicates whether the user management with the security plugin is enabled. This is always true when the os-sec-admin password was set at least once.
    AdminPassword string
    The password for the os-sec-admin user.
    Available bool
    Whether the security plugin is available. This is always true for recently created services.
    Enabled bool
    Whether the security plugin is enabled. This is always true for recently created services.
    Project string
    Identifies the project this resource belongs to. To set up proper dependencies please refer to this variable as a reference. Changing this property forces recreation of the resource.
    ServiceName string
    Specifies the name of the service that this resource belongs to. To set up proper dependencies please refer to this variable as a reference. Changing this property forces recreation of the resource.
    adminEnabled Boolean
    Whether the os-sec-admin user is enabled. This indicates whether the user management with the security plugin is enabled. This is always true when the os-sec-admin password was set at least once.
    adminPassword String
    The password for the os-sec-admin user.
    available Boolean
    Whether the security plugin is available. This is always true for recently created services.
    enabled Boolean
    Whether the security plugin is enabled. This is always true for recently created services.
    project String
    Identifies the project this resource belongs to. To set up proper dependencies please refer to this variable as a reference. Changing this property forces recreation of the resource.
    serviceName String
    Specifies the name of the service that this resource belongs to. To set up proper dependencies please refer to this variable as a reference. Changing this property forces recreation of the resource.
    adminEnabled boolean
    Whether the os-sec-admin user is enabled. This indicates whether the user management with the security plugin is enabled. This is always true when the os-sec-admin password was set at least once.
    adminPassword string
    The password for the os-sec-admin user.
    available boolean
    Whether the security plugin is available. This is always true for recently created services.
    enabled boolean
    Whether the security plugin is enabled. This is always true for recently created services.
    project string
    Identifies the project this resource belongs to. To set up proper dependencies please refer to this variable as a reference. Changing this property forces recreation of the resource.
    serviceName string
    Specifies the name of the service that this resource belongs to. To set up proper dependencies please refer to this variable as a reference. Changing this property forces recreation of the resource.
    admin_enabled bool
    Whether the os-sec-admin user is enabled. This indicates whether the user management with the security plugin is enabled. This is always true when the os-sec-admin password was set at least once.
    admin_password str
    The password for the os-sec-admin user.
    available bool
    Whether the security plugin is available. This is always true for recently created services.
    enabled bool
    Whether the security plugin is enabled. This is always true for recently created services.
    project str
    Identifies the project this resource belongs to. To set up proper dependencies please refer to this variable as a reference. Changing this property forces recreation of the resource.
    service_name str
    Specifies the name of the service that this resource belongs to. To set up proper dependencies please refer to this variable as a reference. Changing this property forces recreation of the resource.
    adminEnabled Boolean
    Whether the os-sec-admin user is enabled. This indicates whether the user management with the security plugin is enabled. This is always true when the os-sec-admin password was set at least once.
    adminPassword String
    The password for the os-sec-admin user.
    available Boolean
    Whether the security plugin is available. This is always true for recently created services.
    enabled Boolean
    Whether the security plugin is enabled. This is always true for recently created services.
    project String
    Identifies the project this resource belongs to. To set up proper dependencies please refer to this variable as a reference. Changing this property forces recreation of the resource.
    serviceName String
    Specifies the name of the service that this resource belongs to. To set up proper dependencies please refer to this variable as a reference. Changing this property forces recreation of the resource.

    Import

    $ pulumi import aiven:index/opensearchSecurityPluginConfig:OpensearchSecurityPluginConfig foo project/service_name
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    Aiven pulumi/pulumi-aiven
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the aiven Terraform Provider.
    aiven logo
    Aiven v6.13.0 published on Monday, Mar 25, 2024 by Pulumi