Aiven

Pulumi Official
Package maintained by Pulumi
v5.2.0 published on Wednesday, Jul 20, 2022 by Pulumi

getClickhouseUser

The Clickhouse User data source provides information about the existing Aiven Clickhouse User.

Example Usage

using Pulumi;
using Aiven = Pulumi.Aiven;

class MyStack : Stack
{
    public MyStack()
    {
        var ch_user = Output.Create(Aiven.GetClickhouseUser.InvokeAsync(new Aiven.GetClickhouseUserArgs
        {
            Project = aiven_project.Myproject.Project,
            ServiceName = aiven_clickhouse.Myservice.Service_name,
            Username = "<USERNAME>",
        }));
    }

}
package main

import (
	"github.com/pulumi/pulumi-aiven/sdk/v5/go/aiven"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := aiven.LookupClickhouseUser(ctx, &GetClickhouseUserArgs{
			Project:     aiven_project.Myproject.Project,
			ServiceName: aiven_clickhouse.Myservice.Service_name,
			Username:    "<USERNAME>",
		}, nil)
		if err != nil {
			return err
		}
		return nil
	})
}
package generated_program;

import java.util.*;
import java.io.*;
import java.nio.*;
import com.pulumi.*;

public class App {
    public static void main(String[] args) {
        Pulumi.run(App::stack);
    }

    public static void stack(Context ctx) {
        final var ch-user = Output.of(AivenFunctions.getClickhouseUser(GetClickhouseUserArgs.builder()
            .project(aiven_project.myproject().project())
            .serviceName(aiven_clickhouse.myservice().service_name())
            .username("<USERNAME>")
            .build()));

    }
}
import pulumi
import pulumi_aiven as aiven

ch_user = aiven.get_clickhouse_user(project=aiven_project["myproject"]["project"],
    service_name=aiven_clickhouse["myservice"]["service_name"],
    username="<USERNAME>")
import * as pulumi from "@pulumi/pulumi";
import * as aiven from "@pulumi/aiven";

const ch-user = aiven.getClickhouseUser({
    project: aiven_project.myproject.project,
    serviceName: aiven_clickhouse.myservice.service_name,
    username: "<USERNAME>",
});
variables:
  ch-user:
    Fn::Invoke:
      Function: aiven:getClickhouseUser
      Arguments:
        project: ${aiven_project.myproject.project}
        serviceName: ${aiven_clickhouse.myservice.service_name}
        username: <USERNAME>

Using getClickhouseUser

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 getClickhouseUser(args: GetClickhouseUserArgs, opts?: InvokeOptions): Promise<GetClickhouseUserResult>
function getClickhouseUserOutput(args: GetClickhouseUserOutputArgs, opts?: InvokeOptions): Output<GetClickhouseUserResult>
def get_clickhouse_user(project: Optional[str] = None,
                        service_name: Optional[str] = None,
                        username: Optional[str] = None,
                        opts: Optional[InvokeOptions] = None) -> GetClickhouseUserResult
def get_clickhouse_user_output(project: Optional[pulumi.Input[str]] = None,
                        service_name: Optional[pulumi.Input[str]] = None,
                        username: Optional[pulumi.Input[str]] = None,
                        opts: Optional[InvokeOptions] = None) -> Output[GetClickhouseUserResult]
func LookupClickhouseUser(ctx *Context, args *LookupClickhouseUserArgs, opts ...InvokeOption) (*LookupClickhouseUserResult, error)
func LookupClickhouseUserOutput(ctx *Context, args *LookupClickhouseUserOutputArgs, opts ...InvokeOption) LookupClickhouseUserResultOutput

> Note: This function is named LookupClickhouseUser in the Go SDK.

public static class GetClickhouseUser 
{
    public static Task<GetClickhouseUserResult> InvokeAsync(GetClickhouseUserArgs args, InvokeOptions? opts = null)
    public static Output<GetClickhouseUserResult> Invoke(GetClickhouseUserInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetClickhouseUserResult> getClickhouseUser(GetClickhouseUserArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
Fn::Invoke:
  Function: aiven:index/getClickhouseUser:getClickhouseUser
  Arguments:
    # Arguments dictionary

The following arguments are supported:

Project string
ServiceName string
Username string
Project string
ServiceName string
Username string
project String
serviceName String
username String
project string
serviceName string
username string
project String
serviceName String
username String

getClickhouseUser Result

The following output properties are available:

Id string

The provider-assigned unique ID for this managed resource.

Password string
Project string
Required bool
ServiceName string
Username string
Uuid string
Id string

The provider-assigned unique ID for this managed resource.

Password string
Project string
Required bool
ServiceName string
Username string
Uuid string
id String

The provider-assigned unique ID for this managed resource.

password String
project String
required Boolean
serviceName String
username String
uuid String
id string

The provider-assigned unique ID for this managed resource.

password string
project string
required boolean
serviceName string
username string
uuid string
id str

The provider-assigned unique ID for this managed resource.

password str
project str
required bool
service_name str
username str
uuid str
id String

The provider-assigned unique ID for this managed resource.

password String
project String
required Boolean
serviceName String
username String
uuid String

Package Details

Repository
https://github.com/pulumi/pulumi-aiven
License
Apache-2.0
Notes

This Pulumi package is based on the aiven Terraform Provider.