Yandex Cloud
Search
Contact UsTry it for free
  • Customer Stories
  • Documentation
  • Blog
  • All Services
  • System Status
  • Marketplace
    • Featured
    • Infrastructure & Network
    • Data Platform
    • AI for business
    • Security
    • DevOps tools
    • Serverless
    • Monitoring & Resources
  • All Solutions
    • By industry
    • By use case
    • Economics and Pricing
    • Security
    • Technical Support
    • Start testing with double trial credits
    • Cloud credits to scale your IT product
    • Gateway to Russia
    • Cloud for Startups
    • Center for Technologies and Society
    • Yandex Cloud Partner program
    • Price calculator
    • Pricing plans
  • Customer Stories
  • Documentation
  • Blog
© 2026 Direct Cursus Technology L.L.C.
Terraform in Yandex Cloud
  • Getting started
  • Solution library
    • Overview
    • Release notes
          • cdn_origin_group
          • cdn_resource

In this article:

  • Example usage
  • Arguments & Attributes Reference
  • Import
  1. Terraform reference
  2. Resources
  3. Cloud CDN
  4. Resources
  5. cdn_origin_group

yandex_cdn_origin_group (Resource)

Written by
Yandex Cloud
Updated at April 9, 2026
  • Example usage
  • Arguments & Attributes Reference
  • Import

Allows management of Yandex Cloud CDN Origin Groups.

Example usageExample usage

//
// Create a new CDN Origin Group
//
resource "yandex_cdn_origin_group" "my_group" {
  name     = "My Origin group"
  use_next = true

  origin {
    source = "ya.ru"
  }

  origin {
    source = "yandex.ru"
  }

  origin {
    source = "goo.gl"
  }

  origin {
    source = "amazon.com"
    backup = false
  }
}

Arguments & Attributes ReferenceArguments & Attributes Reference

  • folder_id (String). The folder identifier that resource belongs to. If it is not provided, the default provider folder-id is used.
  • id (String).
  • name (Required)(String). The resource name.
  • provider_type (String). CDN provider is a content delivery service provider. Possible values: "ourcdn" (default) or "gcore"
  • use_next (Bool). If the option is active (has true value), in case the origin responds with 4XX or 5XX codes, use the next origin from the list.
  • origin [Block]. A set of available origins, an origins group must contain at least one enabled origin with fields below.
    • backup (Bool). Specifies whether the origin is used in its origin group as backup. A backup origin is used when one of active origins becomes unavailable.
    • enabled (Bool). The origin is enabled and used as a source for the CDN. Default enabled.
    • origin_group_id (Read-Only) (String). The ID of a specific origin group.
    • source (Required)(String). IP address or Domain name of your origin and the port.
  • timeouts [Block].
    • create (String).
    • delete (String).
    • update (String).

ImportImport

The resource can be imported by using their resource ID. For getting it you can use Yandex Cloud Web Console or Yandex Cloud CLI.

# terraform import yandex_cdn_origin_group.<resource Name> <resource Id>
terraform import yandex_cdn_origin_group.my_cdn_group ...

Was the article helpful?

Previous
cdn_resource
Next
cdn_resource
© 2026 Direct Cursus Technology L.L.C.