azurerm_media_live_event_output

Manages a Azure Media Live Event Output.

Example Usage

resource "azurerm_resource_group" "example" {
  name     = "media-resources"
  location = "West Europe"
}

resource "azurerm_storage_account" "example" {
  name                     = "examplestoracc"
  resource_group_name      = azurerm_resource_group.example.name
  location                 = azurerm_resource_group.example.location
  account_tier             = "Standard"
  account_replication_type = "GRS"
}

resource "azurerm_media_services_account" "example" {
  name                = "examplemediaacc"
  location            = azurerm_resource_group.example.location
  resource_group_name = azurerm_resource_group.example.name

  storage_account {
    id         = azurerm_storage_account.example.id
    is_primary = true
  }
}

resource "azurerm_media_asset" "example" {
  name                        = "inputAsset"
  resource_group_name         = azurerm_resource_group.example.name
  media_services_account_name = azurerm_media_services_account.example.name
}

resource "azurerm_media_live_event" "example" {
  name                        = "exampleevent"
  resource_group_name         = azurerm_resource_group.example.name
  location                    = azurerm_resource_group.example.location
  media_services_account_name = azurerm_media_services_account.example.name
  description                 = "My Event Description"

  input {
    streaming_protocol          = "RTMP"
    key_frame_interval_duration = "PT6S"
    ip_access_control_allow {
      name                 = "AllowAll"
      address              = "0.0.0.0"
      subnet_prefix_length = 0
    }
  }
}

resource "azurerm_media_live_event_output" "example" {
  name                         = "exampleoutput"
  live_event_id                = azurerm_media_live_event.example.id
  archive_window_duration      = "PT5M"
  asset_name                   = azurerm_media_asset.example.name
  description                  = "Test live output 1"
  manifest_name                = "testmanifest"
  output_snap_time_in_seconds  = 0
  hls_fragments_per_ts_segment = 5
  rewind_window_duration       = "PT5M"
}

Arguments Reference

The following arguments are supported:


Attributes Reference

In addition to the Arguments listed above - the following Attributes are exported:

Timeouts

The timeouts block allows you to specify timeouts for certain actions:

Import

Live Outputs can be imported using the resource id, e.g.

terraform import azurerm_media_live_event_output.example /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/group1/providers/Microsoft.Media/mediaServices/account1/liveEvents/event1/liveOutputs/output1