Class AclBindingRule
Starting with Consul 1.5.0, the consul..AclBindingRule resource can be used to managed Consul ACL binding rules.
Example Usage
using Pulumi;
using Consul = Pulumi.Consul;
class MyStack : Stack
{
public MyStack()
{
var minikube = new Consul.AclAuthMethod("minikube", new Consul.AclAuthMethodArgs
{
Config =
{
{ "CACert", @"-----BEGIN CERTIFICATE-----
...-----END CERTIFICATE-----
" },
{ "Host", "https://192.0.2.42:8443" },
{ "ServiceAccountJWT", "eyJhbGciOiJSUzI1NiIsImtpZCI6IiJ9..." },
},
Description = "dev minikube cluster",
Type = "kubernetes",
});
var test = new Consul.AclBindingRule("test", new Consul.AclBindingRuleArgs
{
AuthMethod = minikube.Name,
BindName = "minikube",
BindType = "service",
Description = "foobar",
Selector = "serviceaccount.namespace==default",
});
}
}
Inherited Members
Namespace: Pulumi.Consul
Assembly: Pulumi.Consul.dll
Syntax
public class AclBindingRule : CustomResource
Constructors
View SourceAclBindingRule(String, AclBindingRuleArgs, CustomResourceOptions)
Create a AclBindingRule resource with the given unique name, arguments, and options.
Declaration
public AclBindingRule(string name, AclBindingRuleArgs args, CustomResourceOptions options = null)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | name | The unique name of the resource |
| AclBindingRuleArgs | args | The arguments used to populate this resource's properties |
| CustomResourceOptions | options | A bag of options that control this resource's behavior |
Properties
View SourceAuthMethod
The name of the ACL auth method this rule apply.
Declaration
public Output<string> AuthMethod { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
BindName
The name to bind to a token at login-time.
Declaration
public Output<string> BindName { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
BindType
Specifies the way the binding rule affects a token created at login.
Declaration
public Output<string> BindType { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Description
A free form human readable description of the binding rule.
Declaration
public Output<string> Description { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Namespace
The namespace to create the binding rule within.
Declaration
public Output<string> Namespace { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Selector
The expression used to math this rule against valid identities returned from an auth method validation.
Declaration
public Output<string> Selector { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Methods
View SourceGet(String, Input<String>, AclBindingRuleState, CustomResourceOptions)
Get an existing AclBindingRule resource's state with the given name, ID, and optional extra properties used to qualify the lookup.
Declaration
public static AclBindingRule Get(string name, Input<string> id, AclBindingRuleState state = null, CustomResourceOptions options = null)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | name | The unique name of the resulting resource. |
| Input<System.String> | id | The unique provider ID of the resource to lookup. |
| AclBindingRuleState | state | Any extra arguments used during the lookup. |
| CustomResourceOptions | options | A bag of options that control this resource's behavior |
Returns
| Type | Description |
|---|---|
| AclBindingRule |