License
NOTE: This feature requires Consul Enterprise.
The consul..License resource provides datacenter-level management of
the Consul Enterprise license. If ACLs are enabled then a token with operator
privileges may be required in order to use this command.
Example Usage
using System.IO;
using Pulumi;
using Consul = Pulumi.Consul;
class MyStack : Stack
{
public MyStack()
{
var license = new Consul.License("license", new Consul.LicenseArgs
{
License = File.ReadAllText("license.hclic"),
});
}
}
Coming soon!
import pulumi
import pulumi_consul as consul
license = consul.License("license", license=(lambda path: open(path).read())("license.hclic"))import * as pulumi from "@pulumi/pulumi";
import * as consul from "@pulumi/consul";
import * from "fs";
const license = new consul.License("license", {license: fs.readFileSync("license.hclic")});Create a License Resource
new License(name: string, args: LicenseArgs, opts?: CustomResourceOptions);def License(resource_name, opts=None, datacenter=None, license=None, __props__=None);func NewLicense(ctx *Context, name string, args LicenseArgs, opts ...ResourceOption) (*License, error)public License(string name, LicenseArgs args, CustomResourceOptions? opts = null)- name string
- The unique name of the resource.
- args LicenseArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- opts ResourceOptions
- A bag of options that control this resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args LicenseArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args LicenseArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
License Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Programming Model docs.
Inputs
The License resource accepts the following input properties:
- Consul
License string The Consul license to use.
- Datacenter string
The datacenter to use. This overrides the agent’s default datacenter and the datacenter in the provider setup.
- License string
The Consul license to use.
- Datacenter string
The datacenter to use. This overrides the agent’s default datacenter and the datacenter in the provider setup.
- license string
The Consul license to use.
- datacenter string
The datacenter to use. This overrides the agent’s default datacenter and the datacenter in the provider setup.
- license str
The Consul license to use.
- datacenter str
The datacenter to use. This overrides the agent’s default datacenter and the datacenter in the provider setup.
Outputs
All input properties are implicitly available as output properties. Additionally, the License resource produces the following output properties:
- Customer
Id string The ID of the customer the license is attached to.
- Expiration
Time string The expiration time of the license.
- Features List<string>
The features for which the license is valid.
- Flags Dictionary<string, string>
The metadata attached to the license.
- Id string
- The provider-assigned unique ID for this managed resource.
- Installation
Id string The ID of the current installation.
- Issue
Time string The date the license was issued.
- License
Id string The ID of the license used.
- Product string
The product for which the license is valid.
- Start
Time string The start time of the license.
- Valid bool
Whether the license is valid.
- Warnings List<string>
A list of warning messages regarding the license validity.
- Customer
Id string The ID of the customer the license is attached to.
- Expiration
Time string The expiration time of the license.
- Features []string
The features for which the license is valid.
- Flags map[string]string
The metadata attached to the license.
- Id string
- The provider-assigned unique ID for this managed resource.
- Installation
Id string The ID of the current installation.
- Issue
Time string The date the license was issued.
- License
Id string The ID of the license used.
- Product string
The product for which the license is valid.
- Start
Time string The start time of the license.
- Valid bool
Whether the license is valid.
- Warnings []string
A list of warning messages regarding the license validity.
- customer
Id string The ID of the customer the license is attached to.
- expiration
Time string The expiration time of the license.
- features string[]
The features for which the license is valid.
- flags {[key: string]: string}
The metadata attached to the license.
- id string
- The provider-assigned unique ID for this managed resource.
- installation
Id string The ID of the current installation.
- issue
Time string The date the license was issued.
- license
Id string The ID of the license used.
- product string
The product for which the license is valid.
- start
Time string The start time of the license.
- valid boolean
Whether the license is valid.
- warnings string[]
A list of warning messages regarding the license validity.
- customer_
id str The ID of the customer the license is attached to.
- expiration_
time str The expiration time of the license.
- features List[str]
The features for which the license is valid.
- flags Dict[str, str]
The metadata attached to the license.
- id str
- The provider-assigned unique ID for this managed resource.
- installation_
id str The ID of the current installation.
- issue_
time str The date the license was issued.
- license_
id str The ID of the license used.
- product str
The product for which the license is valid.
- start_
time str The start time of the license.
- valid bool
Whether the license is valid.
- warnings List[str]
A list of warning messages regarding the license validity.
Look up an Existing License Resource
Get an existing License 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?: LicenseState, opts?: CustomResourceOptions): Licensestatic get(resource_name, id, opts=None, customer_id=None, datacenter=None, expiration_time=None, features=None, flags=None, installation_id=None, issue_time=None, license=None, license_id=None, product=None, start_time=None, valid=None, warnings=None, __props__=None);func GetLicense(ctx *Context, name string, id IDInput, state *LicenseState, opts ...ResourceOption) (*License, error)public static License Get(string name, Input<string> id, LicenseState? state, CustomResourceOptions? opts = null)- 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.
The following state arguments are supported:
- Consul
License string The Consul license to use.
- Customer
Id string The ID of the customer the license is attached to.
- Datacenter string
The datacenter to use. This overrides the agent’s default datacenter and the datacenter in the provider setup.
- Expiration
Time string The expiration time of the license.
- Features List<string>
The features for which the license is valid.
- Flags Dictionary<string, string>
The metadata attached to the license.
- Installation
Id string The ID of the current installation.
- Issue
Time string The date the license was issued.
- License
Id string The ID of the license used.
- Product string
The product for which the license is valid.
- Start
Time string The start time of the license.
- Valid bool
Whether the license is valid.
- Warnings List<string>
A list of warning messages regarding the license validity.
- Customer
Id string The ID of the customer the license is attached to.
- Datacenter string
The datacenter to use. This overrides the agent’s default datacenter and the datacenter in the provider setup.
- Expiration
Time string The expiration time of the license.
- Features []string
The features for which the license is valid.
- Flags map[string]string
The metadata attached to the license.
- Installation
Id string The ID of the current installation.
- Issue
Time string The date the license was issued.
- License string
The Consul license to use.
- License
Id string The ID of the license used.
- Product string
The product for which the license is valid.
- Start
Time string The start time of the license.
- Valid bool
Whether the license is valid.
- Warnings []string
A list of warning messages regarding the license validity.
- customer
Id string The ID of the customer the license is attached to.
- datacenter string
The datacenter to use. This overrides the agent’s default datacenter and the datacenter in the provider setup.
- expiration
Time string The expiration time of the license.
- features string[]
The features for which the license is valid.
- flags {[key: string]: string}
The metadata attached to the license.
- installation
Id string The ID of the current installation.
- issue
Time string The date the license was issued.
- license string
The Consul license to use.
- license
Id string The ID of the license used.
- product string
The product for which the license is valid.
- start
Time string The start time of the license.
- valid boolean
Whether the license is valid.
- warnings string[]
A list of warning messages regarding the license validity.
- customer_
id str The ID of the customer the license is attached to.
- datacenter str
The datacenter to use. This overrides the agent’s default datacenter and the datacenter in the provider setup.
- expiration_
time str The expiration time of the license.
- features List[str]
The features for which the license is valid.
- flags Dict[str, str]
The metadata attached to the license.
- installation_
id str The ID of the current installation.
- issue_
time str The date the license was issued.
- license str
The Consul license to use.
- license_
id str The ID of the license used.
- product str
The product for which the license is valid.
- start_
time str The start time of the license.
- valid bool
Whether the license is valid.
- warnings List[str]
A list of warning messages regarding the license validity.
Package Details
- Repository
- https://github.com/pulumi/pulumi-consul
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
consulTerraform Provider.