HCP

v0.1.11 published on Monday, Jul 25, 2022 by Grapl Security

getConsulAgentHelmConfig

The Consul agent Helm config data source provides Helm values for a Consul agent running in Kubernetes.

Example Usage

using Pulumi;
using Hcp = Pulumi.Hcp;

class MyStack : Stack
{
    public MyStack()
    {
        var example = Output.Create(Hcp.GetConsulAgentHelmConfig.InvokeAsync(new Hcp.GetConsulAgentHelmConfigArgs
        {
            ClusterId = @var.Cluster_id,
            KubernetesEndpoint = @var.Kubernetes_endpoint,
        }));
    }

}
package main

import (
	"github.com/grapl-security/pulumi-hcp/sdk/go/hcp"
	"github.com/pulumi/pulumi-hcp/sdk/go/hcp"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := hcp.GetConsulAgentHelmConfig(ctx, &GetConsulAgentHelmConfigArgs{
			ClusterId:          _var.Cluster_id,
			KubernetesEndpoint: _var.Kubernetes_endpoint,
		}, nil)
		if err != nil {
			return err
		}
		return nil
	})
}
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.hcp.HcpFunctions;
import com.pulumi.hcp.inputs.GetConsulAgentHelmConfigArgs;
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 example = HcpFunctions.getConsulAgentHelmConfig(GetConsulAgentHelmConfigArgs.builder()
            .clusterId(var_.cluster_id())
            .kubernetesEndpoint(var_.kubernetes_endpoint())
            .build());

    }
}
import pulumi
import pulumi_hcp as hcp

example = hcp.get_consul_agent_helm_config(cluster_id=var["cluster_id"],
    kubernetes_endpoint=var["kubernetes_endpoint"])
import * as pulumi from "@pulumi/pulumi";
import * as hcp from "@pulumi/hcp";

const example = hcp.getConsulAgentHelmConfig({
    clusterId: _var.cluster_id,
    kubernetesEndpoint: _var.kubernetes_endpoint,
});
variables:
  example:
    Fn::Invoke:
      Function: hcp:getConsulAgentHelmConfig
      Arguments:
        clusterId: ${var.cluster_id}
        kubernetesEndpoint: ${var.kubernetes_endpoint}

Using getConsulAgentHelmConfig

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 getConsulAgentHelmConfig(args: GetConsulAgentHelmConfigArgs, opts?: InvokeOptions): Promise<GetConsulAgentHelmConfigResult>
function getConsulAgentHelmConfigOutput(args: GetConsulAgentHelmConfigOutputArgs, opts?: InvokeOptions): Output<GetConsulAgentHelmConfigResult>
def get_consul_agent_helm_config(cluster_id: Optional[str] = None,
                                 expose_gossip_ports: Optional[bool] = None,
                                 kubernetes_endpoint: Optional[str] = None,
                                 opts: Optional[InvokeOptions] = None) -> GetConsulAgentHelmConfigResult
def get_consul_agent_helm_config_output(cluster_id: Optional[pulumi.Input[str]] = None,
                                 expose_gossip_ports: Optional[pulumi.Input[bool]] = None,
                                 kubernetes_endpoint: Optional[pulumi.Input[str]] = None,
                                 opts: Optional[InvokeOptions] = None) -> Output[GetConsulAgentHelmConfigResult]
func GetConsulAgentHelmConfig(ctx *Context, args *GetConsulAgentHelmConfigArgs, opts ...InvokeOption) (*GetConsulAgentHelmConfigResult, error)
func GetConsulAgentHelmConfigOutput(ctx *Context, args *GetConsulAgentHelmConfigOutputArgs, opts ...InvokeOption) GetConsulAgentHelmConfigResultOutput

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

public static class GetConsulAgentHelmConfig 
{
    public static Task<GetConsulAgentHelmConfigResult> InvokeAsync(GetConsulAgentHelmConfigArgs args, InvokeOptions? opts = null)
    public static Output<GetConsulAgentHelmConfigResult> Invoke(GetConsulAgentHelmConfigInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetConsulAgentHelmConfigResult> getConsulAgentHelmConfig(GetConsulAgentHelmConfigArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
Fn::Invoke:
  Function: hcp:index/getConsulAgentHelmConfig:getConsulAgentHelmConfig
  Arguments:
    # Arguments dictionary

The following arguments are supported:

getConsulAgentHelmConfig Result

The following output properties are available:

ClusterId string
Config string
Id string

The provider-assigned unique ID for this managed resource.

KubernetesEndpoint string
ExposeGossipPorts bool
ClusterId string
Config string
Id string

The provider-assigned unique ID for this managed resource.

KubernetesEndpoint string
ExposeGossipPorts bool
clusterId String
config String
id String

The provider-assigned unique ID for this managed resource.

kubernetesEndpoint String
exposeGossipPorts Boolean
clusterId string
config string
id string

The provider-assigned unique ID for this managed resource.

kubernetesEndpoint string
exposeGossipPorts boolean
cluster_id str
config str
id str

The provider-assigned unique ID for this managed resource.

kubernetes_endpoint str
expose_gossip_ports bool
clusterId String
config String
id String

The provider-assigned unique ID for this managed resource.

kubernetesEndpoint String
exposeGossipPorts Boolean

Package Details

Repository
https://github.com/grapl-security/pulumi-hcp
License
Apache-2.0
Notes

This Pulumi package is based on the hcp Terraform Provider.