com.pulumi.cloudflare.kotlin.CustomSslArgs.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of pulumi-cloudflare-kotlin Show documentation
Show all versions of pulumi-cloudflare-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.
The newest version!
@file:Suppress("NAME_SHADOWING", "DEPRECATION")
package com.pulumi.cloudflare.kotlin
import com.pulumi.cloudflare.CustomSslArgs.builder
import com.pulumi.cloudflare.kotlin.inputs.CustomSslCustomSslOptionsArgs
import com.pulumi.cloudflare.kotlin.inputs.CustomSslCustomSslOptionsArgsBuilder
import com.pulumi.cloudflare.kotlin.inputs.CustomSslCustomSslPriorityArgs
import com.pulumi.cloudflare.kotlin.inputs.CustomSslCustomSslPriorityArgsBuilder
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.jvm.JvmName
/**
* Provides a Cloudflare custom SSL resource.
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as cloudflare from "@pulumi/cloudflare";
* const example = new cloudflare.CustomSsl("example", {
* zoneId: "0da42c8d2132a9ddaf714f9e7c920711",
* customSslOptions: {
* certificate: "-----INSERT CERTIFICATE-----",
* privateKey: "-----INSERT PRIVATE KEY-----",
* bundleMethod: "ubiquitous",
* geoRestrictions: "us",
* type: "legacy_custom",
* },
* });
* ```
* ```python
* import pulumi
* import pulumi_cloudflare as cloudflare
* example = cloudflare.CustomSsl("example",
* zone_id="0da42c8d2132a9ddaf714f9e7c920711",
* custom_ssl_options={
* "certificate": "-----INSERT CERTIFICATE-----",
* "private_key": "-----INSERT PRIVATE KEY-----",
* "bundle_method": "ubiquitous",
* "geo_restrictions": "us",
* "type": "legacy_custom",
* })
* ```
* ```csharp
* using System.Collections.Generic;
* using System.Linq;
* using Pulumi;
* using Cloudflare = Pulumi.Cloudflare;
* return await Deployment.RunAsync(() =>
* {
* var example = new Cloudflare.CustomSsl("example", new()
* {
* ZoneId = "0da42c8d2132a9ddaf714f9e7c920711",
* CustomSslOptions = new Cloudflare.Inputs.CustomSslCustomSslOptionsArgs
* {
* Certificate = "-----INSERT CERTIFICATE-----",
* PrivateKey = "-----INSERT PRIVATE KEY-----",
* BundleMethod = "ubiquitous",
* GeoRestrictions = "us",
* Type = "legacy_custom",
* },
* });
* });
* ```
* ```go
* package main
* import (
* "github.com/pulumi/pulumi-cloudflare/sdk/v5/go/cloudflare"
* "github.com/pulumi/pulumi/sdk/v3/go/pulumi"
* )
* func main() {
* pulumi.Run(func(ctx *pulumi.Context) error {
* _, err := cloudflare.NewCustomSsl(ctx, "example", &cloudflare.CustomSslArgs{
* ZoneId: pulumi.String("0da42c8d2132a9ddaf714f9e7c920711"),
* CustomSslOptions: &cloudflare.CustomSslCustomSslOptionsArgs{
* Certificate: pulumi.String("-----INSERT CERTIFICATE-----"),
* PrivateKey: pulumi.String("-----INSERT PRIVATE KEY-----"),
* BundleMethod: pulumi.String("ubiquitous"),
* GeoRestrictions: pulumi.String("us"),
* Type: pulumi.String("legacy_custom"),
* },
* })
* 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.cloudflare.CustomSsl;
* import com.pulumi.cloudflare.CustomSslArgs;
* import com.pulumi.cloudflare.inputs.CustomSslCustomSslOptionsArgs;
* 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 CustomSsl("example", CustomSslArgs.builder()
* .zoneId("0da42c8d2132a9ddaf714f9e7c920711")
* .customSslOptions(CustomSslCustomSslOptionsArgs.builder()
* .certificate("-----INSERT CERTIFICATE-----")
* .privateKey("-----INSERT PRIVATE KEY-----")
* .bundleMethod("ubiquitous")
* .geoRestrictions("us")
* .type("legacy_custom")
* .build())
* .build());
* }
* }
* ```
* ```yaml
* resources:
* example:
* type: cloudflare:CustomSsl
* properties:
* zoneId: 0da42c8d2132a9ddaf714f9e7c920711
* customSslOptions:
* certificate: '-----INSERT CERTIFICATE-----'
* privateKey: '-----INSERT PRIVATE KEY-----'
* bundleMethod: ubiquitous
* geoRestrictions: us
* type: legacy_custom
* ```
*
* ## Import
* ```sh
* $ pulumi import cloudflare:index/customSsl:CustomSsl example /
* ```
* @property customSslOptions The certificate associated parameters. **Modifying this attribute will force creation of a new resource.**
* @property customSslPriorities
* @property zoneId The zone identifier to target for the resource.
*/
public data class CustomSslArgs(
public val customSslOptions: Output? = null,
public val customSslPriorities: Output>? = null,
public val zoneId: Output? = null,
) : ConvertibleToJava {
override fun toJava(): com.pulumi.cloudflare.CustomSslArgs =
com.pulumi.cloudflare.CustomSslArgs.builder()
.customSslOptions(customSslOptions?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
.customSslPriorities(
customSslPriorities?.applyValue({ args0 ->
args0.map({ args0 ->
args0.let({ args0 -> args0.toJava() })
})
}),
)
.zoneId(zoneId?.applyValue({ args0 -> args0 })).build()
}
/**
* Builder for [CustomSslArgs].
*/
@PulumiTagMarker
public class CustomSslArgsBuilder internal constructor() {
private var customSslOptions: Output? = null
private var customSslPriorities: Output>? = null
private var zoneId: Output? = null
/**
* @param value The certificate associated parameters. **Modifying this attribute will force creation of a new resource.**
*/
@JvmName("xrbxoxmswxjctuah")
public suspend fun customSslOptions(`value`: Output) {
this.customSslOptions = value
}
/**
* @param value
*/
@JvmName("ojtunocudqtjfmrq")
public suspend fun customSslPriorities(`value`: Output>) {
this.customSslPriorities = value
}
@JvmName("qsdlikdpespyonei")
public suspend fun customSslPriorities(vararg values: Output) {
this.customSslPriorities = Output.all(values.asList())
}
/**
* @param values
*/
@JvmName("blwwhseetqdeuclr")
public suspend fun customSslPriorities(values: List