Please wait. This can take some minutes ...
Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance.
Project price only 1 $
You can buy this project and download/modify it how often you want.
com.pulumi.aws.sagemaker.kotlin.AppArgs.kt Maven / Gradle / Ivy
@file:Suppress("NAME_SHADOWING", "DEPRECATION")
package com.pulumi.aws.sagemaker.kotlin
import com.pulumi.aws.sagemaker.AppArgs.builder
import com.pulumi.aws.sagemaker.kotlin.inputs.AppResourceSpecArgs
import com.pulumi.aws.sagemaker.kotlin.inputs.AppResourceSpecArgsBuilder
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.Pair
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.Map
import kotlin.jvm.JvmName
/**
* Provides a SageMaker App resource.
* ## Example Usage
* ### Basic usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as aws from "@pulumi/aws";
* const example = new aws.sagemaker.App("example", {
* domainId: exampleAwsSagemakerDomain.id,
* userProfileName: exampleAwsSagemakerUserProfile.userProfileName,
* appName: "example",
* appType: "JupyterServer",
* });
* ```
* ```python
* import pulumi
* import pulumi_aws as aws
* example = aws.sagemaker.App("example",
* domain_id=example_aws_sagemaker_domain["id"],
* user_profile_name=example_aws_sagemaker_user_profile["userProfileName"],
* app_name="example",
* app_type="JupyterServer")
* ```
* ```csharp
* using System.Collections.Generic;
* using System.Linq;
* using Pulumi;
* using Aws = Pulumi.Aws;
* return await Deployment.RunAsync(() =>
* {
* var example = new Aws.Sagemaker.App("example", new()
* {
* DomainId = exampleAwsSagemakerDomain.Id,
* UserProfileName = exampleAwsSagemakerUserProfile.UserProfileName,
* AppName = "example",
* AppType = "JupyterServer",
* });
* });
* ```
* ```go
* package main
* import (
* "github.com/pulumi/pulumi-aws/sdk/v6/go/aws/sagemaker"
* "github.com/pulumi/pulumi/sdk/v3/go/pulumi"
* )
* func main() {
* pulumi.Run(func(ctx *pulumi.Context) error {
* _, err := sagemaker.NewApp(ctx, "example", &sagemaker.AppArgs{
* DomainId: pulumi.Any(exampleAwsSagemakerDomain.Id),
* UserProfileName: pulumi.Any(exampleAwsSagemakerUserProfile.UserProfileName),
* AppName: pulumi.String("example"),
* AppType: pulumi.String("JupyterServer"),
* })
* 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.aws.sagemaker.App;
* import com.pulumi.aws.sagemaker.AppArgs;
* 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 App("example", AppArgs.builder()
* .domainId(exampleAwsSagemakerDomain.id())
* .userProfileName(exampleAwsSagemakerUserProfile.userProfileName())
* .appName("example")
* .appType("JupyterServer")
* .build());
* }
* }
* ```
* ```yaml
* resources:
* example:
* type: aws:sagemaker:App
* properties:
* domainId: ${exampleAwsSagemakerDomain.id}
* userProfileName: ${exampleAwsSagemakerUserProfile.userProfileName}
* appName: example
* appType: JupyterServer
* ```
*
* ## Import
* Using `pulumi import`, import SageMaker Apps using the `id`. For example:
* ```sh
* $ pulumi import aws:sagemaker/app:App example arn:aws:sagemaker:us-west-2:012345678912:app/domain-id/user-profile-name/app-type/app-name
* ```
* @property appName The name of the app.
* @property appType The type of app. Valid values are `JupyterServer`, `KernelGateway`, `RStudioServerPro`, `RSessionGateway`, `TensorBoard`, `CodeEditor`, `JupyterLab`, `DetailedProfiler`, and `Canvas`.
* @property domainId The domain ID.
* @property resourceSpec The instance type and the Amazon Resource Name (ARN) of the SageMaker image created on the instance.See Resource Spec below.
* @property spaceName The name of the space. At least one of `user_profile_name` or `space_name` required.
* @property tags A map of tags to assign to the resource. .If configured with a provider `default_tags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
* @property userProfileName The user profile name. At least one of `user_profile_name` or `space_name` required.
*/
public data class AppArgs(
public val appName: Output? = null,
public val appType: Output? = null,
public val domainId: Output? = null,
public val resourceSpec: Output? = null,
public val spaceName: Output? = null,
public val tags: Output>? = null,
public val userProfileName: Output? = null,
) : ConvertibleToJava {
override fun toJava(): com.pulumi.aws.sagemaker.AppArgs =
com.pulumi.aws.sagemaker.AppArgs.builder()
.appName(appName?.applyValue({ args0 -> args0 }))
.appType(appType?.applyValue({ args0 -> args0 }))
.domainId(domainId?.applyValue({ args0 -> args0 }))
.resourceSpec(resourceSpec?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
.spaceName(spaceName?.applyValue({ args0 -> args0 }))
.tags(tags?.applyValue({ args0 -> args0.map({ args0 -> args0.key.to(args0.value) }).toMap() }))
.userProfileName(userProfileName?.applyValue({ args0 -> args0 })).build()
}
/**
* Builder for [AppArgs].
*/
@PulumiTagMarker
public class AppArgsBuilder internal constructor() {
private var appName: Output? = null
private var appType: Output? = null
private var domainId: Output? = null
private var resourceSpec: Output? = null
private var spaceName: Output? = null
private var tags: Output>? = null
private var userProfileName: Output? = null
/**
* @param value The name of the app.
*/
@JvmName("dicknvdkyixhcbes")
public suspend fun appName(`value`: Output) {
this.appName = value
}
/**
* @param value The type of app. Valid values are `JupyterServer`, `KernelGateway`, `RStudioServerPro`, `RSessionGateway`, `TensorBoard`, `CodeEditor`, `JupyterLab`, `DetailedProfiler`, and `Canvas`.
*/
@JvmName("ncseindqupfvcbml")
public suspend fun appType(`value`: Output) {
this.appType = value
}
/**
* @param value The domain ID.
*/
@JvmName("kyubfyjvjdcpimpj")
public suspend fun domainId(`value`: Output) {
this.domainId = value
}
/**
* @param value The instance type and the Amazon Resource Name (ARN) of the SageMaker image created on the instance.See Resource Spec below.
*/
@JvmName("nexltdjylxueavwh")
public suspend fun resourceSpec(`value`: Output) {
this.resourceSpec = value
}
/**
* @param value The name of the space. At least one of `user_profile_name` or `space_name` required.
*/
@JvmName("yikaabiwrbcigpgw")
public suspend fun spaceName(`value`: Output) {
this.spaceName = value
}
/**
* @param value A map of tags to assign to the resource. .If configured with a provider `default_tags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
*/
@JvmName("ypljjidsxofdngsk")
public suspend fun tags(`value`: Output>) {
this.tags = value
}
/**
* @param value The user profile name. At least one of `user_profile_name` or `space_name` required.
*/
@JvmName("xxqdmtkmiqhfgrdn")
public suspend fun userProfileName(`value`: Output) {
this.userProfileName = value
}
/**
* @param value The name of the app.
*/
@JvmName("cjxgafugtbhvlntx")
public suspend fun appName(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.appName = mapped
}
/**
* @param value The type of app. Valid values are `JupyterServer`, `KernelGateway`, `RStudioServerPro`, `RSessionGateway`, `TensorBoard`, `CodeEditor`, `JupyterLab`, `DetailedProfiler`, and `Canvas`.
*/
@JvmName("jarubehhrwmdkbxk")
public suspend fun appType(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.appType = mapped
}
/**
* @param value The domain ID.
*/
@JvmName("ddmfheriehwdyxjd")
public suspend fun domainId(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.domainId = mapped
}
/**
* @param value The instance type and the Amazon Resource Name (ARN) of the SageMaker image created on the instance.See Resource Spec below.
*/
@JvmName("fexjsobupiqclpvr")
public suspend fun resourceSpec(`value`: AppResourceSpecArgs?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.resourceSpec = mapped
}
/**
* @param argument The instance type and the Amazon Resource Name (ARN) of the SageMaker image created on the instance.See Resource Spec below.
*/
@JvmName("dhvswfvnwqlfsgua")
public suspend fun resourceSpec(argument: suspend AppResourceSpecArgsBuilder.() -> Unit) {
val toBeMapped = AppResourceSpecArgsBuilder().applySuspend { argument() }.build()
val mapped = of(toBeMapped)
this.resourceSpec = mapped
}
/**
* @param value The name of the space. At least one of `user_profile_name` or `space_name` required.
*/
@JvmName("yluiefvqxldrwegm")
public suspend fun spaceName(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.spaceName = mapped
}
/**
* @param value A map of tags to assign to the resource. .If configured with a provider `default_tags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
*/
@JvmName("euwicxdrchkkhmck")
public suspend fun tags(`value`: Map?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.tags = mapped
}
/**
* @param values A map of tags to assign to the resource. .If configured with a provider `default_tags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
*/
@JvmName("brwaftrhwpdgiait")
public fun tags(vararg values: Pair) {
val toBeMapped = values.toMap()
val mapped = toBeMapped.let({ args0 -> of(args0) })
this.tags = mapped
}
/**
* @param value The user profile name. At least one of `user_profile_name` or `space_name` required.
*/
@JvmName("mbohmbefpkdtsafb")
public suspend fun userProfileName(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.userProfileName = mapped
}
internal fun build(): AppArgs = AppArgs(
appName = appName,
appType = appType,
domainId = domainId,
resourceSpec = resourceSpec,
spaceName = spaceName,
tags = tags,
userProfileName = userProfileName,
)
}