All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.pulumi.azure.media.kotlin.StreamingEndpointArgs.kt Maven / Gradle / Ivy

@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.azure.media.kotlin

import com.pulumi.azure.media.StreamingEndpointArgs.builder
import com.pulumi.azure.media.kotlin.inputs.StreamingEndpointAccessControlArgs
import com.pulumi.azure.media.kotlin.inputs.StreamingEndpointAccessControlArgsBuilder
import com.pulumi.azure.media.kotlin.inputs.StreamingEndpointCrossSiteAccessPolicyArgs
import com.pulumi.azure.media.kotlin.inputs.StreamingEndpointCrossSiteAccessPolicyArgsBuilder
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.Boolean
import kotlin.Int
import kotlin.Pair
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.collections.Map
import kotlin.jvm.JvmName

/**
 * Manages a Streaming Endpoint.
 * ## Example Usage
 * 
 * ```typescript
 * import * as pulumi from "@pulumi/pulumi";
 * import * as azure from "@pulumi/azure";
 * const example = new azure.core.ResourceGroup("example", {
 *     name: "media-resources",
 *     location: "West Europe",
 * });
 * const exampleAccount = new azure.storage.Account("example", {
 *     name: "examplestoracc",
 *     resourceGroupName: example.name,
 *     location: example.location,
 *     accountTier: "Standard",
 *     accountReplicationType: "GRS",
 * });
 * const exampleServiceAccount = new azure.media.ServiceAccount("example", {
 *     name: "examplemediaacc",
 *     location: example.location,
 *     resourceGroupName: example.name,
 *     storageAccounts: [{
 *         id: exampleAccount.id,
 *         isPrimary: true,
 *     }],
 * });
 * const exampleStreamingEndpoint = new azure.media.StreamingEndpoint("example", {
 *     name: "endpoint1",
 *     resourceGroupName: example.name,
 *     location: example.location,
 *     mediaServicesAccountName: exampleServiceAccount.name,
 *     scaleUnits: 2,
 * });
 * ```
 * ```python
 * import pulumi
 * import pulumi_azure as azure
 * example = azure.core.ResourceGroup("example",
 *     name="media-resources",
 *     location="West Europe")
 * example_account = azure.storage.Account("example",
 *     name="examplestoracc",
 *     resource_group_name=example.name,
 *     location=example.location,
 *     account_tier="Standard",
 *     account_replication_type="GRS")
 * example_service_account = azure.media.ServiceAccount("example",
 *     name="examplemediaacc",
 *     location=example.location,
 *     resource_group_name=example.name,
 *     storage_accounts=[{
 *         "id": example_account.id,
 *         "is_primary": True,
 *     }])
 * example_streaming_endpoint = azure.media.StreamingEndpoint("example",
 *     name="endpoint1",
 *     resource_group_name=example.name,
 *     location=example.location,
 *     media_services_account_name=example_service_account.name,
 *     scale_units=2)
 * ```
 * ```csharp
 * using System.Collections.Generic;
 * using System.Linq;
 * using Pulumi;
 * using Azure = Pulumi.Azure;
 * return await Deployment.RunAsync(() =>
 * {
 *     var example = new Azure.Core.ResourceGroup("example", new()
 *     {
 *         Name = "media-resources",
 *         Location = "West Europe",
 *     });
 *     var exampleAccount = new Azure.Storage.Account("example", new()
 *     {
 *         Name = "examplestoracc",
 *         ResourceGroupName = example.Name,
 *         Location = example.Location,
 *         AccountTier = "Standard",
 *         AccountReplicationType = "GRS",
 *     });
 *     var exampleServiceAccount = new Azure.Media.ServiceAccount("example", new()
 *     {
 *         Name = "examplemediaacc",
 *         Location = example.Location,
 *         ResourceGroupName = example.Name,
 *         StorageAccounts = new[]
 *         {
 *             new Azure.Media.Inputs.ServiceAccountStorageAccountArgs
 *             {
 *                 Id = exampleAccount.Id,
 *                 IsPrimary = true,
 *             },
 *         },
 *     });
 *     var exampleStreamingEndpoint = new Azure.Media.StreamingEndpoint("example", new()
 *     {
 *         Name = "endpoint1",
 *         ResourceGroupName = example.Name,
 *         Location = example.Location,
 *         MediaServicesAccountName = exampleServiceAccount.Name,
 *         ScaleUnits = 2,
 *     });
 * });
 * ```
 * ```go
 * package main
 * import (
 * 	"github.com/pulumi/pulumi-azure/sdk/v5/go/azure/core"
 * 	"github.com/pulumi/pulumi-azure/sdk/v5/go/azure/media"
 * 	"github.com/pulumi/pulumi-azure/sdk/v5/go/azure/storage"
 * 	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
 * )
 * func main() {
 * 	pulumi.Run(func(ctx *pulumi.Context) error {
 * 		example, err := core.NewResourceGroup(ctx, "example", &core.ResourceGroupArgs{
 * 			Name:     pulumi.String("media-resources"),
 * 			Location: pulumi.String("West Europe"),
 * 		})
 * 		if err != nil {
 * 			return err
 * 		}
 * 		exampleAccount, err := storage.NewAccount(ctx, "example", &storage.AccountArgs{
 * 			Name:                   pulumi.String("examplestoracc"),
 * 			ResourceGroupName:      example.Name,
 * 			Location:               example.Location,
 * 			AccountTier:            pulumi.String("Standard"),
 * 			AccountReplicationType: pulumi.String("GRS"),
 * 		})
 * 		if err != nil {
 * 			return err
 * 		}
 * 		exampleServiceAccount, err := media.NewServiceAccount(ctx, "example", &media.ServiceAccountArgs{
 * 			Name:              pulumi.String("examplemediaacc"),
 * 			Location:          example.Location,
 * 			ResourceGroupName: example.Name,
 * 			StorageAccounts: media.ServiceAccountStorageAccountArray{
 * 				&media.ServiceAccountStorageAccountArgs{
 * 					Id:        exampleAccount.ID(),
 * 					IsPrimary: pulumi.Bool(true),
 * 				},
 * 			},
 * 		})
 * 		if err != nil {
 * 			return err
 * 		}
 * 		_, err = media.NewStreamingEndpoint(ctx, "example", &media.StreamingEndpointArgs{
 * 			Name:                     pulumi.String("endpoint1"),
 * 			ResourceGroupName:        example.Name,
 * 			Location:                 example.Location,
 * 			MediaServicesAccountName: exampleServiceAccount.Name,
 * 			ScaleUnits:               pulumi.Int(2),
 * 		})
 * 		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.azure.core.ResourceGroup;
 * import com.pulumi.azure.core.ResourceGroupArgs;
 * import com.pulumi.azure.storage.Account;
 * import com.pulumi.azure.storage.AccountArgs;
 * import com.pulumi.azure.media.ServiceAccount;
 * import com.pulumi.azure.media.ServiceAccountArgs;
 * import com.pulumi.azure.media.inputs.ServiceAccountStorageAccountArgs;
 * import com.pulumi.azure.media.StreamingEndpoint;
 * import com.pulumi.azure.media.StreamingEndpointArgs;
 * 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 ResourceGroup("example", ResourceGroupArgs.builder()
 *             .name("media-resources")
 *             .location("West Europe")
 *             .build());
 *         var exampleAccount = new Account("exampleAccount", AccountArgs.builder()
 *             .name("examplestoracc")
 *             .resourceGroupName(example.name())
 *             .location(example.location())
 *             .accountTier("Standard")
 *             .accountReplicationType("GRS")
 *             .build());
 *         var exampleServiceAccount = new ServiceAccount("exampleServiceAccount", ServiceAccountArgs.builder()
 *             .name("examplemediaacc")
 *             .location(example.location())
 *             .resourceGroupName(example.name())
 *             .storageAccounts(ServiceAccountStorageAccountArgs.builder()
 *                 .id(exampleAccount.id())
 *                 .isPrimary(true)
 *                 .build())
 *             .build());
 *         var exampleStreamingEndpoint = new StreamingEndpoint("exampleStreamingEndpoint", StreamingEndpointArgs.builder()
 *             .name("endpoint1")
 *             .resourceGroupName(example.name())
 *             .location(example.location())
 *             .mediaServicesAccountName(exampleServiceAccount.name())
 *             .scaleUnits(2)
 *             .build());
 *     }
 * }
 * ```
 * ```yaml
 * resources:
 *   example:
 *     type: azure:core:ResourceGroup
 *     properties:
 *       name: media-resources
 *       location: West Europe
 *   exampleAccount:
 *     type: azure:storage:Account
 *     name: example
 *     properties:
 *       name: examplestoracc
 *       resourceGroupName: ${example.name}
 *       location: ${example.location}
 *       accountTier: Standard
 *       accountReplicationType: GRS
 *   exampleServiceAccount:
 *     type: azure:media:ServiceAccount
 *     name: example
 *     properties:
 *       name: examplemediaacc
 *       location: ${example.location}
 *       resourceGroupName: ${example.name}
 *       storageAccounts:
 *         - id: ${exampleAccount.id}
 *           isPrimary: true
 *   exampleStreamingEndpoint:
 *     type: azure:media:StreamingEndpoint
 *     name: example
 *     properties:
 *       name: endpoint1
 *       resourceGroupName: ${example.name}
 *       location: ${example.location}
 *       mediaServicesAccountName: ${exampleServiceAccount.name}
 *       scaleUnits: 2
 * ```
 * 
 * ### With Access Control
 * 
 * ```typescript
 * import * as pulumi from "@pulumi/pulumi";
 * import * as azure from "@pulumi/azure";
 * const example = new azure.core.ResourceGroup("example", {
 *     name: "media-resources",
 *     location: "West Europe",
 * });
 * const exampleAccount = new azure.storage.Account("example", {
 *     name: "examplestoracc",
 *     resourceGroupName: example.name,
 *     location: example.location,
 *     accountTier: "Standard",
 *     accountReplicationType: "GRS",
 * });
 * const exampleServiceAccount = new azure.media.ServiceAccount("example", {
 *     name: "examplemediaacc",
 *     location: example.location,
 *     resourceGroupName: example.name,
 *     storageAccounts: [{
 *         id: exampleAccount.id,
 *         isPrimary: true,
 *     }],
 * });
 * const exampleStreamingEndpoint = new azure.media.StreamingEndpoint("example", {
 *     name: "endpoint1",
 *     resourceGroupName: example.name,
 *     location: example.location,
 *     mediaServicesAccountName: exampleServiceAccount.name,
 *     scaleUnits: 2,
 *     accessControl: {
 *         ipAllows: [
 *             {
 *                 name: "AllowedIP",
 *                 address: "192.168.1.1",
 *             },
 *             {
 *                 name: "AnotherIp",
 *                 address: "192.168.1.2",
 *             },
 *         ],
 *         akamaiSignatureHeaderAuthenticationKeys: [
 *             {
 *                 identifier: "id1",
 *                 expiration: "2030-12-31T16:00:00Z",
 *                 base64Key: "dGVzdGlkMQ==",
 *             },
 *             {
 *                 identifier: "id2",
 *                 expiration: "2032-01-28T16:00:00Z",
 *                 base64Key: "dGVzdGlkMQ==",
 *             },
 *         ],
 *     },
 * });
 * ```
 * ```python
 * import pulumi
 * import pulumi_azure as azure
 * example = azure.core.ResourceGroup("example",
 *     name="media-resources",
 *     location="West Europe")
 * example_account = azure.storage.Account("example",
 *     name="examplestoracc",
 *     resource_group_name=example.name,
 *     location=example.location,
 *     account_tier="Standard",
 *     account_replication_type="GRS")
 * example_service_account = azure.media.ServiceAccount("example",
 *     name="examplemediaacc",
 *     location=example.location,
 *     resource_group_name=example.name,
 *     storage_accounts=[{
 *         "id": example_account.id,
 *         "is_primary": True,
 *     }])
 * example_streaming_endpoint = azure.media.StreamingEndpoint("example",
 *     name="endpoint1",
 *     resource_group_name=example.name,
 *     location=example.location,
 *     media_services_account_name=example_service_account.name,
 *     scale_units=2,
 *     access_control={
 *         "ip_allows": [
 *             {
 *                 "name": "AllowedIP",
 *                 "address": "192.168.1.1",
 *             },
 *             {
 *                 "name": "AnotherIp",
 *                 "address": "192.168.1.2",
 *             },
 *         ],
 *         "akamai_signature_header_authentication_keys": [
 *             {
 *                 "identifier": "id1",
 *                 "expiration": "2030-12-31T16:00:00Z",
 *                 "base64_key": "dGVzdGlkMQ==",
 *             },
 *             {
 *                 "identifier": "id2",
 *                 "expiration": "2032-01-28T16:00:00Z",
 *                 "base64_key": "dGVzdGlkMQ==",
 *             },
 *         ],
 *     })
 * ```
 * ```csharp
 * using System.Collections.Generic;
 * using System.Linq;
 * using Pulumi;
 * using Azure = Pulumi.Azure;
 * return await Deployment.RunAsync(() =>
 * {
 *     var example = new Azure.Core.ResourceGroup("example", new()
 *     {
 *         Name = "media-resources",
 *         Location = "West Europe",
 *     });
 *     var exampleAccount = new Azure.Storage.Account("example", new()
 *     {
 *         Name = "examplestoracc",
 *         ResourceGroupName = example.Name,
 *         Location = example.Location,
 *         AccountTier = "Standard",
 *         AccountReplicationType = "GRS",
 *     });
 *     var exampleServiceAccount = new Azure.Media.ServiceAccount("example", new()
 *     {
 *         Name = "examplemediaacc",
 *         Location = example.Location,
 *         ResourceGroupName = example.Name,
 *         StorageAccounts = new[]
 *         {
 *             new Azure.Media.Inputs.ServiceAccountStorageAccountArgs
 *             {
 *                 Id = exampleAccount.Id,
 *                 IsPrimary = true,
 *             },
 *         },
 *     });
 *     var exampleStreamingEndpoint = new Azure.Media.StreamingEndpoint("example", new()
 *     {
 *         Name = "endpoint1",
 *         ResourceGroupName = example.Name,
 *         Location = example.Location,
 *         MediaServicesAccountName = exampleServiceAccount.Name,
 *         ScaleUnits = 2,
 *         AccessControl = new Azure.Media.Inputs.StreamingEndpointAccessControlArgs
 *         {
 *             IpAllows = new[]
 *             {
 *                 new Azure.Media.Inputs.StreamingEndpointAccessControlIpAllowArgs
 *                 {
 *                     Name = "AllowedIP",
 *                     Address = "192.168.1.1",
 *                 },
 *                 new Azure.Media.Inputs.StreamingEndpointAccessControlIpAllowArgs
 *                 {
 *                     Name = "AnotherIp",
 *                     Address = "192.168.1.2",
 *                 },
 *             },
 *             AkamaiSignatureHeaderAuthenticationKeys = new[]
 *             {
 *                 new Azure.Media.Inputs.StreamingEndpointAccessControlAkamaiSignatureHeaderAuthenticationKeyArgs
 *                 {
 *                     Identifier = "id1",
 *                     Expiration = "2030-12-31T16:00:00Z",
 *                     Base64Key = "dGVzdGlkMQ==",
 *                 },
 *                 new Azure.Media.Inputs.StreamingEndpointAccessControlAkamaiSignatureHeaderAuthenticationKeyArgs
 *                 {
 *                     Identifier = "id2",
 *                     Expiration = "2032-01-28T16:00:00Z",
 *                     Base64Key = "dGVzdGlkMQ==",
 *                 },
 *             },
 *         },
 *     });
 * });
 * ```
 * ```go
 * package main
 * import (
 * 	"github.com/pulumi/pulumi-azure/sdk/v5/go/azure/core"
 * 	"github.com/pulumi/pulumi-azure/sdk/v5/go/azure/media"
 * 	"github.com/pulumi/pulumi-azure/sdk/v5/go/azure/storage"
 * 	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
 * )
 * func main() {
 * 	pulumi.Run(func(ctx *pulumi.Context) error {
 * 		example, err := core.NewResourceGroup(ctx, "example", &core.ResourceGroupArgs{
 * 			Name:     pulumi.String("media-resources"),
 * 			Location: pulumi.String("West Europe"),
 * 		})
 * 		if err != nil {
 * 			return err
 * 		}
 * 		exampleAccount, err := storage.NewAccount(ctx, "example", &storage.AccountArgs{
 * 			Name:                   pulumi.String("examplestoracc"),
 * 			ResourceGroupName:      example.Name,
 * 			Location:               example.Location,
 * 			AccountTier:            pulumi.String("Standard"),
 * 			AccountReplicationType: pulumi.String("GRS"),
 * 		})
 * 		if err != nil {
 * 			return err
 * 		}
 * 		exampleServiceAccount, err := media.NewServiceAccount(ctx, "example", &media.ServiceAccountArgs{
 * 			Name:              pulumi.String("examplemediaacc"),
 * 			Location:          example.Location,
 * 			ResourceGroupName: example.Name,
 * 			StorageAccounts: media.ServiceAccountStorageAccountArray{
 * 				&media.ServiceAccountStorageAccountArgs{
 * 					Id:        exampleAccount.ID(),
 * 					IsPrimary: pulumi.Bool(true),
 * 				},
 * 			},
 * 		})
 * 		if err != nil {
 * 			return err
 * 		}
 * 		_, err = media.NewStreamingEndpoint(ctx, "example", &media.StreamingEndpointArgs{
 * 			Name:                     pulumi.String("endpoint1"),
 * 			ResourceGroupName:        example.Name,
 * 			Location:                 example.Location,
 * 			MediaServicesAccountName: exampleServiceAccount.Name,
 * 			ScaleUnits:               pulumi.Int(2),
 * 			AccessControl: &media.StreamingEndpointAccessControlArgs{
 * 				IpAllows: media.StreamingEndpointAccessControlIpAllowArray{
 * 					&media.StreamingEndpointAccessControlIpAllowArgs{
 * 						Name:    pulumi.String("AllowedIP"),
 * 						Address: pulumi.String("192.168.1.1"),
 * 					},
 * 					&media.StreamingEndpointAccessControlIpAllowArgs{
 * 						Name:    pulumi.String("AnotherIp"),
 * 						Address: pulumi.String("192.168.1.2"),
 * 					},
 * 				},
 * 				AkamaiSignatureHeaderAuthenticationKeys: media.StreamingEndpointAccessControlAkamaiSignatureHeaderAuthenticationKeyArray{
 * 					&media.StreamingEndpointAccessControlAkamaiSignatureHeaderAuthenticationKeyArgs{
 * 						Identifier: pulumi.String("id1"),
 * 						Expiration: pulumi.String("2030-12-31T16:00:00Z"),
 * 						Base64Key:  pulumi.String("dGVzdGlkMQ=="),
 * 					},
 * 					&media.StreamingEndpointAccessControlAkamaiSignatureHeaderAuthenticationKeyArgs{
 * 						Identifier: pulumi.String("id2"),
 * 						Expiration: pulumi.String("2032-01-28T16:00:00Z"),
 * 						Base64Key:  pulumi.String("dGVzdGlkMQ=="),
 * 					},
 * 				},
 * 			},
 * 		})
 * 		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.azure.core.ResourceGroup;
 * import com.pulumi.azure.core.ResourceGroupArgs;
 * import com.pulumi.azure.storage.Account;
 * import com.pulumi.azure.storage.AccountArgs;
 * import com.pulumi.azure.media.ServiceAccount;
 * import com.pulumi.azure.media.ServiceAccountArgs;
 * import com.pulumi.azure.media.inputs.ServiceAccountStorageAccountArgs;
 * import com.pulumi.azure.media.StreamingEndpoint;
 * import com.pulumi.azure.media.StreamingEndpointArgs;
 * import com.pulumi.azure.media.inputs.StreamingEndpointAccessControlArgs;
 * 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 ResourceGroup("example", ResourceGroupArgs.builder()
 *             .name("media-resources")
 *             .location("West Europe")
 *             .build());
 *         var exampleAccount = new Account("exampleAccount", AccountArgs.builder()
 *             .name("examplestoracc")
 *             .resourceGroupName(example.name())
 *             .location(example.location())
 *             .accountTier("Standard")
 *             .accountReplicationType("GRS")
 *             .build());
 *         var exampleServiceAccount = new ServiceAccount("exampleServiceAccount", ServiceAccountArgs.builder()
 *             .name("examplemediaacc")
 *             .location(example.location())
 *             .resourceGroupName(example.name())
 *             .storageAccounts(ServiceAccountStorageAccountArgs.builder()
 *                 .id(exampleAccount.id())
 *                 .isPrimary(true)
 *                 .build())
 *             .build());
 *         var exampleStreamingEndpoint = new StreamingEndpoint("exampleStreamingEndpoint", StreamingEndpointArgs.builder()
 *             .name("endpoint1")
 *             .resourceGroupName(example.name())
 *             .location(example.location())
 *             .mediaServicesAccountName(exampleServiceAccount.name())
 *             .scaleUnits(2)
 *             .accessControl(StreamingEndpointAccessControlArgs.builder()
 *                 .ipAllows(
 *                     StreamingEndpointAccessControlIpAllowArgs.builder()
 *                         .name("AllowedIP")
 *                         .address("192.168.1.1")
 *                         .build(),
 *                     StreamingEndpointAccessControlIpAllowArgs.builder()
 *                         .name("AnotherIp")
 *                         .address("192.168.1.2")
 *                         .build())
 *                 .akamaiSignatureHeaderAuthenticationKeys(
 *                     StreamingEndpointAccessControlAkamaiSignatureHeaderAuthenticationKeyArgs.builder()
 *                         .identifier("id1")
 *                         .expiration("2030-12-31T16:00:00Z")
 *                         .base64Key("dGVzdGlkMQ==")
 *                         .build(),
 *                     StreamingEndpointAccessControlAkamaiSignatureHeaderAuthenticationKeyArgs.builder()
 *                         .identifier("id2")
 *                         .expiration("2032-01-28T16:00:00Z")
 *                         .base64Key("dGVzdGlkMQ==")
 *                         .build())
 *                 .build())
 *             .build());
 *     }
 * }
 * ```
 * ```yaml
 * resources:
 *   example:
 *     type: azure:core:ResourceGroup
 *     properties:
 *       name: media-resources
 *       location: West Europe
 *   exampleAccount:
 *     type: azure:storage:Account
 *     name: example
 *     properties:
 *       name: examplestoracc
 *       resourceGroupName: ${example.name}
 *       location: ${example.location}
 *       accountTier: Standard
 *       accountReplicationType: GRS
 *   exampleServiceAccount:
 *     type: azure:media:ServiceAccount
 *     name: example
 *     properties:
 *       name: examplemediaacc
 *       location: ${example.location}
 *       resourceGroupName: ${example.name}
 *       storageAccounts:
 *         - id: ${exampleAccount.id}
 *           isPrimary: true
 *   exampleStreamingEndpoint:
 *     type: azure:media:StreamingEndpoint
 *     name: example
 *     properties:
 *       name: endpoint1
 *       resourceGroupName: ${example.name}
 *       location: ${example.location}
 *       mediaServicesAccountName: ${exampleServiceAccount.name}
 *       scaleUnits: 2
 *       accessControl:
 *         ipAllows:
 *           - name: AllowedIP
 *             address: 192.168.1.1
 *           - name: AnotherIp
 *             address: 192.168.1.2
 *         akamaiSignatureHeaderAuthenticationKeys:
 *           - identifier: id1
 *             expiration: 2030-12-31T16:00:00Z
 *             base64Key: dGVzdGlkMQ==
 *           - identifier: id2
 *             expiration: 2032-01-28T16:00:00Z
 *             base64Key: dGVzdGlkMQ==
 * ```
 * 
 * ## Import
 * Streaming Endpoints can be imported using the `resource id`, e.g.
 * ```sh
 * $ pulumi import azure:media/streamingEndpoint:StreamingEndpoint example /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/group1/providers/Microsoft.Media/mediaServices/service1/streamingEndpoints/endpoint1
 * ```
 * @property accessControl A `access_control` block as defined below.
 * @property autoStartEnabled The flag indicates if the resource should be automatically started on creation.
 * @property cdnEnabled The CDN enabled flag.
 * @property cdnProfile The CDN profile name.
 * @property cdnProvider The CDN provider name. Supported value are `StandardVerizon`,`PremiumVerizon` and `StandardAkamai`
 * @property crossSiteAccessPolicy A `cross_site_access_policy` block as defined below.
 * @property customHostNames The custom host names of the streaming endpoint.
 * @property description The streaming endpoint description.
 * @property location The Azure Region where the Streaming Endpoint should exist. Changing this forces a new Streaming Endpoint to be created.
 * @property maxCacheAgeSeconds Max cache age in seconds.
 * @property mediaServicesAccountName The Media Services account name. Changing this forces a new Streaming Endpoint to be created.
 * @property name The name which should be used for this Streaming Endpoint maximum length is `24`. Changing this forces a new Streaming Endpoint to be created.
 * @property resourceGroupName The name of the Resource Group where the Streaming Endpoint should exist. Changing this forces a new Streaming Endpoint to be created.
 * @property scaleUnits The number of scale units. To create a Standard Streaming Endpoint set `0`. For Premium Streaming Endpoint valid values are between `1` and `10`.
 * @property tags A mapping of tags which should be assigned to the Streaming Endpoint.
 */
public data class StreamingEndpointArgs(
    public val accessControl: Output? = null,
    public val autoStartEnabled: Output? = null,
    public val cdnEnabled: Output? = null,
    public val cdnProfile: Output? = null,
    public val cdnProvider: Output? = null,
    public val crossSiteAccessPolicy: Output? = null,
    public val customHostNames: Output>? = null,
    public val description: Output? = null,
    public val location: Output? = null,
    public val maxCacheAgeSeconds: Output? = null,
    public val mediaServicesAccountName: Output? = null,
    public val name: Output? = null,
    public val resourceGroupName: Output? = null,
    public val scaleUnits: Output? = null,
    public val tags: Output>? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.azure.media.StreamingEndpointArgs =
        com.pulumi.azure.media.StreamingEndpointArgs.builder()
            .accessControl(accessControl?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
            .autoStartEnabled(autoStartEnabled?.applyValue({ args0 -> args0 }))
            .cdnEnabled(cdnEnabled?.applyValue({ args0 -> args0 }))
            .cdnProfile(cdnProfile?.applyValue({ args0 -> args0 }))
            .cdnProvider(cdnProvider?.applyValue({ args0 -> args0 }))
            .crossSiteAccessPolicy(
                crossSiteAccessPolicy?.applyValue({ args0 ->
                    args0.let({ args0 ->
                        args0.toJava()
                    })
                }),
            )
            .customHostNames(customHostNames?.applyValue({ args0 -> args0.map({ args0 -> args0 }) }))
            .description(description?.applyValue({ args0 -> args0 }))
            .location(location?.applyValue({ args0 -> args0 }))
            .maxCacheAgeSeconds(maxCacheAgeSeconds?.applyValue({ args0 -> args0 }))
            .mediaServicesAccountName(mediaServicesAccountName?.applyValue({ args0 -> args0 }))
            .name(name?.applyValue({ args0 -> args0 }))
            .resourceGroupName(resourceGroupName?.applyValue({ args0 -> args0 }))
            .scaleUnits(scaleUnits?.applyValue({ args0 -> args0 }))
            .tags(
                tags?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.key.to(args0.value)
                    }).toMap()
                }),
            ).build()
}

/**
 * Builder for [StreamingEndpointArgs].
 */
@PulumiTagMarker
public class StreamingEndpointArgsBuilder internal constructor() {
    private var accessControl: Output? = null

    private var autoStartEnabled: Output? = null

    private var cdnEnabled: Output? = null

    private var cdnProfile: Output? = null

    private var cdnProvider: Output? = null

    private var crossSiteAccessPolicy: Output? = null

    private var customHostNames: Output>? = null

    private var description: Output? = null

    private var location: Output? = null

    private var maxCacheAgeSeconds: Output? = null

    private var mediaServicesAccountName: Output? = null

    private var name: Output? = null

    private var resourceGroupName: Output? = null

    private var scaleUnits: Output? = null

    private var tags: Output>? = null

    /**
     * @param value A `access_control` block as defined below.
     */
    @JvmName("qtevjlmpywvfysts")
    public suspend fun accessControl(`value`: Output) {
        this.accessControl = value
    }

    /**
     * @param value The flag indicates if the resource should be automatically started on creation.
     */
    @JvmName("tviubkldejrtceey")
    public suspend fun autoStartEnabled(`value`: Output) {
        this.autoStartEnabled = value
    }

    /**
     * @param value The CDN enabled flag.
     */
    @JvmName("opjpgpgpafavduou")
    public suspend fun cdnEnabled(`value`: Output) {
        this.cdnEnabled = value
    }

    /**
     * @param value The CDN profile name.
     */
    @JvmName("tmnvtxukvytgowhv")
    public suspend fun cdnProfile(`value`: Output) {
        this.cdnProfile = value
    }

    /**
     * @param value The CDN provider name. Supported value are `StandardVerizon`,`PremiumVerizon` and `StandardAkamai`
     */
    @JvmName("begxsycvpigmqcok")
    public suspend fun cdnProvider(`value`: Output) {
        this.cdnProvider = value
    }

    /**
     * @param value A `cross_site_access_policy` block as defined below.
     */
    @JvmName("yktlsedjiqutqdgp")
    public suspend fun crossSiteAccessPolicy(`value`: Output) {
        this.crossSiteAccessPolicy = value
    }

    /**
     * @param value The custom host names of the streaming endpoint.
     */
    @JvmName("hkmvbcvmlcqbteca")
    public suspend fun customHostNames(`value`: Output>) {
        this.customHostNames = value
    }

    @JvmName("gvgkfqajqbslqxew")
    public suspend fun customHostNames(vararg values: Output) {
        this.customHostNames = Output.all(values.asList())
    }

    /**
     * @param values The custom host names of the streaming endpoint.
     */
    @JvmName("pmdtblilswddobcp")
    public suspend fun customHostNames(values: List>) {
        this.customHostNames = Output.all(values)
    }

    /**
     * @param value The streaming endpoint description.
     */
    @JvmName("dxcdvtpgvqmoivlt")
    public suspend fun description(`value`: Output) {
        this.description = value
    }

    /**
     * @param value The Azure Region where the Streaming Endpoint should exist. Changing this forces a new Streaming Endpoint to be created.
     */
    @JvmName("vdgnrnhlkjvlymoj")
    public suspend fun location(`value`: Output) {
        this.location = value
    }

    /**
     * @param value Max cache age in seconds.
     */
    @JvmName("uiqfmedmcpehxisv")
    public suspend fun maxCacheAgeSeconds(`value`: Output) {
        this.maxCacheAgeSeconds = value
    }

    /**
     * @param value The Media Services account name. Changing this forces a new Streaming Endpoint to be created.
     */
    @JvmName("xjevnxaadkkeunin")
    public suspend fun mediaServicesAccountName(`value`: Output) {
        this.mediaServicesAccountName = value
    }

    /**
     * @param value The name which should be used for this Streaming Endpoint maximum length is `24`. Changing this forces a new Streaming Endpoint to be created.
     */
    @JvmName("ssiypimsdgvgvcht")
    public suspend fun name(`value`: Output) {
        this.name = value
    }

    /**
     * @param value The name of the Resource Group where the Streaming Endpoint should exist. Changing this forces a new Streaming Endpoint to be created.
     */
    @JvmName("rjsysfakvatouhol")
    public suspend fun resourceGroupName(`value`: Output) {
        this.resourceGroupName = value
    }

    /**
     * @param value The number of scale units. To create a Standard Streaming Endpoint set `0`. For Premium Streaming Endpoint valid values are between `1` and `10`.
     */
    @JvmName("qkojptoadeeigggh")
    public suspend fun scaleUnits(`value`: Output) {
        this.scaleUnits = value
    }

    /**
     * @param value A mapping of tags which should be assigned to the Streaming Endpoint.
     */
    @JvmName("nbbpkltcaclxsdds")
    public suspend fun tags(`value`: Output>) {
        this.tags = value
    }

    /**
     * @param value A `access_control` block as defined below.
     */
    @JvmName("uywtmnvfbfegxoui")
    public suspend fun accessControl(`value`: StreamingEndpointAccessControlArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.accessControl = mapped
    }

    /**
     * @param argument A `access_control` block as defined below.
     */
    @JvmName("hfkjrlrywpsccxlq")
    public suspend fun accessControl(argument: suspend StreamingEndpointAccessControlArgsBuilder.() -> Unit) {
        val toBeMapped = StreamingEndpointAccessControlArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.accessControl = mapped
    }

    /**
     * @param value The flag indicates if the resource should be automatically started on creation.
     */
    @JvmName("qhjgmrgjhvqdacey")
    public suspend fun autoStartEnabled(`value`: Boolean?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.autoStartEnabled = mapped
    }

    /**
     * @param value The CDN enabled flag.
     */
    @JvmName("tdldpulgkvuxadyx")
    public suspend fun cdnEnabled(`value`: Boolean?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.cdnEnabled = mapped
    }

    /**
     * @param value The CDN profile name.
     */
    @JvmName("xoaheflphtktdvsp")
    public suspend fun cdnProfile(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.cdnProfile = mapped
    }

    /**
     * @param value The CDN provider name. Supported value are `StandardVerizon`,`PremiumVerizon` and `StandardAkamai`
     */
    @JvmName("ljgwgwpywsyfccdw")
    public suspend fun cdnProvider(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.cdnProvider = mapped
    }

    /**
     * @param value A `cross_site_access_policy` block as defined below.
     */
    @JvmName("pjlsjfpucphcpkvs")
    public suspend fun crossSiteAccessPolicy(`value`: StreamingEndpointCrossSiteAccessPolicyArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.crossSiteAccessPolicy = mapped
    }

    /**
     * @param argument A `cross_site_access_policy` block as defined below.
     */
    @JvmName("fcpxmuvjuneekbvo")
    public suspend fun crossSiteAccessPolicy(argument: suspend StreamingEndpointCrossSiteAccessPolicyArgsBuilder.() -> Unit) {
        val toBeMapped = StreamingEndpointCrossSiteAccessPolicyArgsBuilder().applySuspend {
            argument()
        }.build()
        val mapped = of(toBeMapped)
        this.crossSiteAccessPolicy = mapped
    }

    /**
     * @param value The custom host names of the streaming endpoint.
     */
    @JvmName("yjnwaqsoiwakjlfq")
    public suspend fun customHostNames(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.customHostNames = mapped
    }

    /**
     * @param values The custom host names of the streaming endpoint.
     */
    @JvmName("mmuagyqvbbmfdktd")
    public suspend fun customHostNames(vararg values: String) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.customHostNames = mapped
    }

    /**
     * @param value The streaming endpoint description.
     */
    @JvmName("ewvpgaqgumqdwyfb")
    public suspend fun description(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.description = mapped
    }

    /**
     * @param value The Azure Region where the Streaming Endpoint should exist. Changing this forces a new Streaming Endpoint to be created.
     */
    @JvmName("grqalhdrpxgimecb")
    public suspend fun location(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.location = mapped
    }

    /**
     * @param value Max cache age in seconds.
     */
    @JvmName("nowyghmnqbayrkei")
    public suspend fun maxCacheAgeSeconds(`value`: Int?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.maxCacheAgeSeconds = mapped
    }

    /**
     * @param value The Media Services account name. Changing this forces a new Streaming Endpoint to be created.
     */
    @JvmName("iwapvxkfkyfhkhox")
    public suspend fun mediaServicesAccountName(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.mediaServicesAccountName = mapped
    }

    /**
     * @param value The name which should be used for this Streaming Endpoint maximum length is `24`. Changing this forces a new Streaming Endpoint to be created.
     */
    @JvmName("nkioqrmptcwxuuak")
    public suspend fun name(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.name = mapped
    }

    /**
     * @param value The name of the Resource Group where the Streaming Endpoint should exist. Changing this forces a new Streaming Endpoint to be created.
     */
    @JvmName("udatcwchrbdyycnd")
    public suspend fun resourceGroupName(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.resourceGroupName = mapped
    }

    /**
     * @param value The number of scale units. To create a Standard Streaming Endpoint set `0`. For Premium Streaming Endpoint valid values are between `1` and `10`.
     */
    @JvmName("ayxsuishsypfuaya")
    public suspend fun scaleUnits(`value`: Int?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.scaleUnits = mapped
    }

    /**
     * @param value A mapping of tags which should be assigned to the Streaming Endpoint.
     */
    @JvmName("awatqsbvbsudafya")
    public suspend fun tags(`value`: Map?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.tags = mapped
    }

    /**
     * @param values A mapping of tags which should be assigned to the Streaming Endpoint.
     */
    @JvmName("nicdjckadljtwbtr")
    public fun tags(vararg values: Pair) {
        val toBeMapped = values.toMap()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.tags = mapped
    }

    internal fun build(): StreamingEndpointArgs = StreamingEndpointArgs(
        accessControl = accessControl,
        autoStartEnabled = autoStartEnabled,
        cdnEnabled = cdnEnabled,
        cdnProfile = cdnProfile,
        cdnProvider = cdnProvider,
        crossSiteAccessPolicy = crossSiteAccessPolicy,
        customHostNames = customHostNames,
        description = description,
        location = location,
        maxCacheAgeSeconds = maxCacheAgeSeconds,
        mediaServicesAccountName = mediaServicesAccountName,
        name = name,
        resourceGroupName = resourceGroupName,
        scaleUnits = scaleUnits,
        tags = tags,
    )
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy