com.pulumi.alicloud.ros.kotlin.TemplateArgs.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of pulumi-alicloud-kotlin Show documentation
Show all versions of pulumi-alicloud-kotlin Show documentation
Build cloud applications and infrastructure by combining the safety and reliability of infrastructure as code with the power of the Kotlin programming language.
@file:Suppress("NAME_SHADOWING", "DEPRECATION")
package com.pulumi.alicloud.ros.kotlin
import com.pulumi.alicloud.ros.TemplateArgs.builder
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import kotlin.Pair
import kotlin.String
import kotlin.Suppress
import kotlin.collections.Map
import kotlin.jvm.JvmName
/**
* Provides a ROS Template resource.
* For information about ROS Template and how to use it, see [What is Template](https://www.alibabacloud.com/help/en/doc-detail/141851.htm).
* > **NOTE:** Available in v1.108.0+.
* ## Example Usage
* Basic Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as alicloud from "@pulumi/alicloud";
* const example = new alicloud.ros.Template("example", {
* templateName: "example_value",
* templateBody: ` {
* \x09"ROSTemplateFormatVersion": "2015-09-01"
* }
* `,
* });
* ```
* ```python
* import pulumi
* import pulumi_alicloud as alicloud
* example = alicloud.ros.Template("example",
* template_name="example_value",
* template_body=""" {
* \x09"ROSTemplateFormatVersion": "2015-09-01"
* }
* """)
* ```
* ```csharp
* using System.Collections.Generic;
* using System.Linq;
* using Pulumi;
* using AliCloud = Pulumi.AliCloud;
* return await Deployment.RunAsync(() =>
* {
* var example = new AliCloud.Ros.Template("example", new()
* {
* TemplateName = "example_value",
* TemplateBody = @" {
* ""ROSTemplateFormatVersion"": ""2015-09-01""
* }
* ",
* });
* });
* ```
* ```go
* package main
* import (
* "github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/ros"
* "github.com/pulumi/pulumi/sdk/v3/go/pulumi"
* )
* func main() {
* pulumi.Run(func(ctx *pulumi.Context) error {
* _, err := ros.NewTemplate(ctx, "example", &ros.TemplateArgs{
* TemplateName: pulumi.String("example_value"),
* TemplateBody: pulumi.String(" {\n \"ROSTemplateFormatVersion\": \"2015-09-01\"\n }\n"),
* })
* if err != nil {
* return err
* }
* return nil
* })
* }
* ```
* ```java
* package generated_program;
* import com.pulumi.Context;
* import com.pulumi.Pulumi;
* import com.pulumi.core.Output;
* import com.pulumi.alicloud.ros.Template;
* import com.pulumi.alicloud.ros.TemplateArgs;
* 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) {
* var example = new Template("example", TemplateArgs.builder()
* .templateName("example_value")
* .templateBody("""
* {
* "ROSTemplateFormatVersion": "2015-09-01"
* }
* """)
* .build());
* }
* }
* ```
* ```yaml
* resources:
* example:
* type: alicloud:ros:Template
* properties:
* templateName: example_value
* templateBody: |2
* {
* "ROSTemplateFormatVersion": "2015-09-01"
* }
* ```
*
* ## Import
* ROS Template can be imported using the id, e.g.
* ```sh
* $ pulumi import alicloud:ros/template:Template example
* ```
* @property description The description of the template. The description can be up to 256 characters in length.
* @property tags A mapping of tags to assign to the resource.
* @property templateBody The structure that contains the template body. The template body must be 1 to 524,288 bytes in length. If the length of the template body is longer than required, we recommend that you add parameters to the HTTP POST request body to avoid request failures due to excessive length of URLs. You must specify one of the TemplateBody and TemplateURL parameters, but you cannot specify both of them.
* @property templateName The name of the template. The name can be up to 255 characters in length and can contain digits, letters, hyphens (-), and underscores (_). It must start with a digit or letter.
* @property templateUrl The template url.
*/
public data class TemplateArgs(
public val description: Output? = null,
public val tags: Output