Yandex Cloud
Search
Contact UsTry it for free
  • Customer Stories
  • Documentation
  • Blog
  • All Services
  • System Status
    • Featured
    • Infrastructure & Network
    • Data Platform
    • Containers
    • Developer tools
    • Serverless
    • Security
    • Monitoring & Resources
    • AI for business
    • Business tools
  • 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
© 2025 Direct Cursus Technology L.L.C.
Yandex Cloud CDN
  • Getting started
    • All guides
      • Creating an origin group
      • Updating an origin group
      • Adding an origin group to a resource
      • Getting information about origins
      • Deleting an origin group
  • Access management
  • Pricing policy
  • Terraform reference
  • Monitoring metrics for the EdgeCDN provider
  • Monitoring metrics for the Yandex Cloud CDN provider
  • Request logs
  • Audit Trails events
  • Release notes
  • Troubleshooting

In this article:

  • Editing a group
  • Deleting one origin from a group
  • Deleting multiple origins from a group
  1. Step-by-step guides
  2. Origin groups
  3. Updating an origin group

Updating an origin group

Written by
Yandex Cloud
Updated at December 3, 2025
  • Editing a group
  • Deleting one origin from a group
  • Deleting multiple origins from a group

Editing a groupEditing a group

To update an origin group:

Management console
CLI
Terraform
API
  1. In the management console, select the folder where you want to create a resource group.
  2. Go to Cloud CDN.
  3. In the left-hand panel, select Origin groups.
  4. Select the group to edit.
  5. In the top-right corner, click Edit.
  6. Edit as appropriate.
  7. Click Save.

If you do not have the Yandex Cloud CLI installed yet, install and initialize it.

By default, the CLI uses the folder specified when creating the profile. To change the default folder, use the yc config set folder-id <folder_ID> command. You can also set a different folder for any specific command using the --folder-name or --folder-id parameter.

  1. View the description of the CLI command to edit an origin group:

    yc cdn origin-group update --help
    
  2. Get a list of all origin groups in the default folder:

    yc cdn origin-group list --format yaml
    

    Result:

    - id: "90209"
      folder_id: b1g86q4m5vej********
      name: test-group-1
    ...
        origin_group_id: "90208"
        source: www.a1.com
        enabled: true
    
  3. Edit the settings of the origin group by specifying the group ID:

    yc cdn origin-group update --id <origin_group_ID> \
      --name <new_group_name> \
      --origin source=<new_origin_IP_address_or_domain_name>,enabled=true \
      --origin source=<new_origin_IP_address_or_domain_name>,enabled=true,backup=true
    

    Where --origin is the origin specification:

    • source: New origin's IP address or domain name.
    • enabled: Flag showing whether the origin is enabled.
    • backup: Flag showing whether the origin as a backup one.

    Result:

    id: "90209"
    folder_id: b1g86q4m5vej********
    name: test-group-22
    ...
      origin_group_id: "90209"
      source: www.site1.com
      enabled: true
    

    For more information about the yc cdn origin-group update command, see the CLI reference.

With Terraform, you can quickly create a cloud infrastructure in Yandex Cloud and manage it using configuration files. These files store the infrastructure description written in HashiCorp Configuration Language (HCL). If you change the configuration files, Terraform automatically detects which part of your configuration is already deployed, and what should be added or removed.

Terraform is distributed under the Business Source License. The Yandex Cloud provider for Terraform is distributed under the MPL-2.0 license.

For more information about the provider resources, see the relevant documentation on the Terraform website or its mirror.

If you do not have Terraform yet, install it and configure the Yandex Cloud provider.

  1. Open the Terraform configuration file and edit the yandex_cdn_origin_group description:

    resource "yandex_cdn_origin_group" "my_group" {
      name          = "<origin_group_name>"
      use_next      = true
      provider_type = "<CDN_provider>"
      origin {
      source = "<origin_1_IP_address_or_domain_name>"
      }
      origin {
      source = "<origin_2_IP_address_or_domain_name>"
      }
      origin {
      source = "<origin_3_IP_address_or_domain_name>"
      backup = false
      }
    }
    

    Where:

    • name: Origin group name.

    • use_next: Indicates whether to use the next origin on the list.

    • provider_type: CDN provider, must match the origin group CDN provider. This is an optional setting. The possible values are:

      • ourcdn (default): Yandex Cloud CDN provider.

      • gcore: EdgeCDN provider.

        Warning

        When creating each CDN resource and each origin group, they get assigned a specific provider. You cannot change the assigned provider.

    • origin: Origin specification:

      • source: Origin IP address or domain name.
      • enabled: Flag showing whether the origin is enabled.
      • backup: Flag showing whether the origin as a backup one. For more information about priorities, see Origin groups.

    For more information about the resources you can create with Terraform, see this provider guide.

  2. Apply the changes:

    1. In the terminal, go to the directory where you edited the configuration file.

    2. Make sure the configuration file is correct using this command:

      terraform validate
      

      If the configuration is correct, you will get this message:

      Success! The configuration is valid.
      
    3. Run this command:

      terraform plan
      

      You will see a detailed list of resources. No changes will be made at this step. If the configuration contains any errors, Terraform will show them.

    4. Apply the changes:

      terraform apply
      
    5. Type yes and press Enter to confirm the changes.

    You can check the updates in the management console or using this CLI command:

    yc cdn origin-group get <origin_group_ID>
    

To update an origin group, use the update REST API method for the OriginGroup resource or the OriginGroupService/Update gRPC API call.

Deleting one origin from a groupDeleting one origin from a group

Note

You can only delete backup origins.

To delete an origin from an origin group:

Management console
API
  1. In the management console, select the folder where you want to create a resource group.
  2. Go to Cloud CDN.
  3. In the left-hand panel, select Origin groups and click the name of the group to delete an origin from.
  4. Select the appropriate origin and click Delete in the bottom panel.
  5. In the window that opens, click Delete.

Use the delete REST API method for the Origin resource or the OriginService/Delete gRPC API call.

Deleting multiple origins from a groupDeleting multiple origins from a group

Note

You can only delete backup origins.

To delete multiple origins from a group:

Management console
  1. In the management console, select the folder where you want to create a resource group.
  2. Go to Cloud CDN.
  3. In the left-hand panel, select Origin groups and click the name of the group to delete origins from.
  4. Select the appropriate origins and click Delete in the bottom panel.
  5. In the window that opens, click Delete.

Was the article helpful?

Previous
Creating an origin group
Next
Adding an origin group to a resource
© 2025 Direct Cursus Technology L.L.C.