Skip to content

Commit

Permalink
Generate libsonnet source from libgenerator PR tf-libsonnet/libgenera…
Browse files Browse the repository at this point in the history
…tor#251

Signed-off-by: tflibsonnet-ci <[email protected]>
  • Loading branch information
renovate[bot] authored and tflibsonnet-ci committed Jan 31, 2024
1 parent df9ca07 commit ac3d957
Show file tree
Hide file tree
Showing 8 changed files with 525 additions and 8 deletions.
2 changes: 2 additions & 0 deletions 1.x/_gen/main.libsonnet
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,14 @@ local d = (import 'github.com/jsonnet-libs/docsonnet/doc-util/main.libsonnet');
group: (import 'resources/group.libsonnet'),
integration_aws_parameter_store: (import 'resources/integration_aws_parameter_store.libsonnet'),
integration_aws_secrets_manager: (import 'resources/integration_aws_secrets_manager.libsonnet'),
integration_terraform_cloud: (import 'resources/integration_terraform_cloud.libsonnet'),
project: (import 'resources/project.libsonnet'),
project_member_group: (import 'resources/project_member_group.libsonnet'),
project_member_service_account: (import 'resources/project_member_service_account.libsonnet'),
secret: (import 'resources/secret.libsonnet'),
secrets_sync_aws_parameter_store: (import 'resources/secrets_sync_aws_parameter_store.libsonnet'),
secrets_sync_aws_secrets_manager: (import 'resources/secrets_sync_aws_secrets_manager.libsonnet'),
secrets_sync_terraform_cloud: (import 'resources/secrets_sync_terraform_cloud.libsonnet'),
service_account: (import 'resources/service_account.libsonnet'),
service_token: (import 'resources/service_token.libsonnet'),
data: (import 'data/main.libsonnet'),
Expand Down
4 changes: 2 additions & 2 deletions 1.x/_gen/provider_doppler.libsonnet
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ local tf = (import 'github.com/tf-libsonnet/core/main.libsonnet');
local d = (import 'github.com/jsonnet-libs/docsonnet/doc-util/main.libsonnet');
{
'#':: d.pkg(name='provider', url='', help='`provider` represents the `doppler` Terraform provider config.\n\n\n\nThis package contains functions and utilities for setting up the provider using Jsonnet code.\n'),
'#new':: d.fn(help='\n`doppler.provider.new` injects a new `doppler` Terraform `provider`\nblock into the root module document.\n\nOptionally, this inserts the provider into the\n[required_providers](https://developer.hashicorp.com/terraform/language/providers/requirements) `terraform` sub block if\nthe `src` and/or `version` parameters are set.\n\n**Args**:\n - `doppler_token` (`string`): A Doppler token, either a personal or service token\n - `host` (`string`): The Doppler API host (i.e. https://api.doppler.com) When `null`, the `host` field will be omitted from the resulting object.\n - `verify_tls` (`bool`): Whether or not to verify TLS When `null`, the `verify_tls` field will be omitted from the resulting object.\n - `alias` (`string`): The provider `alias` to set for this instance of the provider block. When `null`, the `alias`\n field will be omitted from the resulting provider block.\n - `src` (`string`): The provider `source` to set on the resulting `required_providers` block. If `src` or `version` is\n set and is not `null`, a `required_providers` block and entry for the provider will be injected into the document.\n - `version` (`string`): The provider `version` to set on the resulting `required_providers` block. If `src` or\n `version` is set and is not `null`, a `required_providers` block and entry for the provider will be injected into the\n document.\n\n\n**Returns**:\n- A mixin object that injects the new provider (and optionally, `required_providers` block) into the root Terraform configuration.\n', args=[]),
'#new':: d.fn(help='\n`doppler.provider.new` injects a new `doppler` Terraform `provider`\nblock into the root module document.\n\nOptionally, this inserts the provider into the\n[required_providers](https://developer.hashicorp.com/terraform/language/providers/requirements) `terraform` sub block if\nthe `src` and/or `version` parameters are set.\n\n**Args**:\n - `doppler_token` (`string`): A Doppler token, either a personal or service token. This can also be set via the DOPPLER_TOKEN environment variable.\n - `host` (`string`): The Doppler API host (i.e. https://api.doppler.com). This can also be set via the DOPPLER_API_HOST environment variable. When `null`, the `host` field will be omitted from the resulting object.\n - `verify_tls` (`bool`): Whether or not to verify TLS. This can also be set via the DOPPLER_VERIFY_TLS environment variable. When `null`, the `verify_tls` field will be omitted from the resulting object.\n - `alias` (`string`): The provider `alias` to set for this instance of the provider block. When `null`, the `alias`\n field will be omitted from the resulting provider block.\n - `src` (`string`): The provider `source` to set on the resulting `required_providers` block. If `src` or `version` is\n set and is not `null`, a `required_providers` block and entry for the provider will be injected into the document.\n - `version` (`string`): The provider `version` to set on the resulting `required_providers` block. If `src` or\n `version` is set and is not `null`, a `required_providers` block and entry for the provider will be injected into the\n document.\n\n\n**Returns**:\n- A mixin object that injects the new provider (and optionally, `required_providers` block) into the root Terraform configuration.\n', args=[]),
new(
doppler_token,
host=null,
Expand All @@ -17,7 +17,7 @@ local d = (import 'github.com/jsonnet-libs/docsonnet/doc-util/main.libsonnet');
version=version,
attrs=self.newAttrs(doppler_token=doppler_token, host=host, verify_tls=verify_tls)
),
'#newAttrs':: d.fn(help='\n`doppler.provider.` constructs a new object with attributes and blocks configured for the `doppler`\nTerraform `provider`.\n\nUnlike [doppler.provider.new](#fn-dopplernew), this function will not inject the `provider`\nblock into the root Terraform document. Instead, this must be passed in as the `attrs` argument for the\n[tf.withProvider](https://github.com/tf-libsonnet/core/tree/main/docs#fn-withprovider) function to build a complete block.\n\nThis is most useful when you need to preprocess the attributes with functions, conditional, or looping logic prior to\ninjecting into a complete block.\n\n**Args**:\n - `doppler_token` (`string`): A Doppler token, either a personal or service token\n - `host` (`string`): The Doppler API host (i.e. https://api.doppler.com) When `null`, the `host` field will be omitted from the resulting object.\n - `verify_tls` (`bool`): Whether or not to verify TLS When `null`, the `verify_tls` field will be omitted from the resulting object.\n\n**Returns**:\n - An attribute object that can be used with [tf.withProvider](https://github.com/tf-libsonnet/core/tree/main/docs#fn-withprovider) to construct a new `doppler` provider\n configuration into the root Terraform configuration.\n', args=[]),
'#newAttrs':: d.fn(help='\n`doppler.provider.` constructs a new object with attributes and blocks configured for the `doppler`\nTerraform `provider`.\n\nUnlike [doppler.provider.new](#fn-dopplernew), this function will not inject the `provider`\nblock into the root Terraform document. Instead, this must be passed in as the `attrs` argument for the\n[tf.withProvider](https://github.com/tf-libsonnet/core/tree/main/docs#fn-withprovider) function to build a complete block.\n\nThis is most useful when you need to preprocess the attributes with functions, conditional, or looping logic prior to\ninjecting into a complete block.\n\n**Args**:\n - `doppler_token` (`string`): A Doppler token, either a personal or service token. This can also be set via the DOPPLER_TOKEN environment variable.\n - `host` (`string`): The Doppler API host (i.e. https://api.doppler.com). This can also be set via the DOPPLER_API_HOST environment variable. When `null`, the `host` field will be omitted from the resulting object.\n - `verify_tls` (`bool`): Whether or not to verify TLS. This can also be set via the DOPPLER_VERIFY_TLS environment variable. When `null`, the `verify_tls` field will be omitted from the resulting object.\n\n**Returns**:\n - An attribute object that can be used with [tf.withProvider](https://github.com/tf-libsonnet/core/tree/main/docs#fn-withprovider) to construct a new `doppler` provider\n configuration into the root Terraform configuration.\n', args=[]),
newAttrs(
doppler_token,
host=null,
Expand Down
45 changes: 45 additions & 0 deletions 1.x/_gen/resources/integration_terraform_cloud.libsonnet
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
local tf = (import 'github.com/tf-libsonnet/core/main.libsonnet');
local d = (import 'github.com/jsonnet-libs/docsonnet/doc-util/main.libsonnet');
{
'#':: d.pkg(name='integration_terraform_cloud', url='', help='`integration_terraform_cloud` represents the `doppler_integration_terraform_cloud` Terraform resource.\n\n\n\nThis package contains functions and utilities for setting up the resource using Jsonnet code.\n'),
'#new':: d.fn(help="\n`doppler.integration_terraform_cloud.new` injects a new `doppler_integration_terraform_cloud` Terraform `resource`\nblock into the root module document.\n\nAdditionally, this inserts a private function into the `_ref` attribute that generates references to attributes of the\nresource. For example, if you added a new instance to the root using:\n\n # arguments omitted for brevity\n doppler.integration_terraform_cloud.new('some_id')\n\nYou can get the reference to the `id` field of the created `doppler.integration_terraform_cloud` using the reference:\n\n $._ref.doppler_integration_terraform_cloud.some_id.get('id')\n\nThis is the same as directly entering `\"${ doppler_integration_terraform_cloud.some_id.id }\"` as the value.\n\nNOTE: if you are chaining multiple resources together in a merge operation, you may not be able to use `super`, `self`,\nor `$` to refer to the root object. Instead, make an explicit outer object using `local`.\n\n**Args**:\n - `resourceLabel` (`string`): The name label of the block.\n - `api_key` (`string`): A Terraform Cloud API key.\n - `name` (`string`): The name of the integration\n\n**Returns**:\n- A mixin object that injects the new resource into the root Terraform configuration.\n", args=[]),
new(
resourceLabel,
api_key,
name,
_meta={}
):: tf.withResource(
type='doppler_integration_terraform_cloud',
label=resourceLabel,
attrs=self.newAttrs(api_key=api_key, name=name),
_meta=_meta
),
'#newAttrs':: d.fn(help='\n`doppler.integration_terraform_cloud.newAttrs` constructs a new object with attributes and blocks configured for the `integration_terraform_cloud`\nTerraform resource.\n\nUnlike [doppler.integration_terraform_cloud.new](#fn-new), this function will not inject the `resource`\nblock into the root Terraform document. Instead, this must be passed in as the `attrs` argument for the\n[tf.withResource](https://github.com/tf-libsonnet/core/tree/main/docs#fn-withresource) function to build a complete block.\n\nThis is most useful when you need to preprocess the attributes with functions, conditional, or looping logic prior to\ninjecting into a complete block.\n\n**Args**:\n - `api_key` (`string`): A Terraform Cloud API key.\n - `name` (`string`): The name of the integration\n\n**Returns**:\n - An attribute object that can be used with [tf.withResource](https://github.com/tf-libsonnet/core/tree/main/docs#fn-withresource) to construct a new `integration_terraform_cloud` resource into the root Terraform configuration.\n', args=[]),
newAttrs(
api_key,
name
):: std.prune(a={
api_key: api_key,
name: name,
}),
'#withApiKey':: d.fn(help='`doppler.string.withApiKey` constructs a mixin object that can be merged into the `string`\nTerraform resource block to set or update the api_key field.\n\n\n\n**Args**:\n - `resourceLabel` (`string`): The name label of the block to update.\n - `value` (`string`): The value to set for the `api_key` field.\n', args=[]),
withApiKey(resourceLabel, value): {
resource+: {
doppler_integration_terraform_cloud+: {
[resourceLabel]+: {
api_key: value,
},
},
},
},
'#withName':: d.fn(help='`doppler.string.withName` constructs a mixin object that can be merged into the `string`\nTerraform resource block to set or update the name field.\n\n\n\n**Args**:\n - `resourceLabel` (`string`): The name label of the block to update.\n - `value` (`string`): The value to set for the `name` field.\n', args=[]),
withName(resourceLabel, value): {
resource+: {
doppler_integration_terraform_cloud+: {
[resourceLabel]+: {
name: value,
},
},
},
},
}
Loading

0 comments on commit ac3d957

Please sign in to comment.