---
title: "selectel_vpc_project_v2 resource"
sidebar_label: "selectel_vpc_project_v2"
description: "Creates and manages a Selectel Cloud Platform project using public API v2"
sidebar_position: 35
---

# selectel\_vpc\_project\_v2 resource

:::info

This instruction is a copy of the Selectel Terraform provider documentation in the [Terraform Registry](https://registry.terraform.io/providers/selectel/selectel/latest/docs).

:::

Creates and manages a project using public API v2. For more information about projects, see the [official Selectel documentation](/access-control/projects/about-projects/).

## Example usage \{#example-usage}

### Project with quotas \{#project-with-quotas}

```hcl
resource "selectel_vpc_project_v2" "project_1" {
  name = "project1"
  quotas {
    resource_name = "compute_cores"
    resource_quotas {
      region = "ru-3"
      zone   = "ru-3a"
      value  = 12
    }
  }
  quotas {
    resource_name = "compute_ram"
    resource_quotas {
      region = "ru-3"
      zone   = "ru-3a"
      value  = 20480
    }
  }
  quotas {
    resource_name = "volume_gigabytes_fast"
    resource_quotas {
      region = "ru-3"
      zone   = "ru-3a"
      value  = 100
    }
  }
}
```

### Project with external panel \{#project-with-external-panel}

```hcl
resource "selectel_vpc_project_v2" "project_1" {
  name       = "project_1"
  custom_url = "project-123.selvpc.ru"
  theme = {
    color = "2753E9"
  }
}
```

## Argument reference \{#argument-reference}

* `name` - (Required) Project name.
* `quotas` - (Optional) Array of project quotas. Learn more from [Project limits and quotas](/access-control/projects/quotas/).

  * `resource_name` - (Required) Resource name. To get the name of the resource, use [Selectel Cloud Quota Management API](https://developers.selectel.ru/docs/selectel-cloud-platform/main-services/cloud-quota-management/).

  * `resource_quotas` - (Required) Array of quotas for the resource.

    * `region` - (Optional) Pool where the resource is located, for example, `ru-3`. Learn more about available pools in [Product availability by location](/infrastructure/product-availability-by-location/).

    * `zone` - (Optional) Pool segment where the resource is located, for example, `ru-3a`. Learn more about available pool segments in [Product availability by location](/infrastructure/product-availability-by-location/).

    * `value` - (Required) Quota value. The value cannot exceed the project limit. To get the project limit, in the [Control panel](https://my.selectel.ru/vpc/default/quotas/), go to **Cloud Platform** ⟶ **Quotas**. The project limit for the resource is in the **Quota** column. Learn more about [Project limits and quotas](/access-control/projects/quotas/).
* `custom_url` — (Optional) URL of the project in the external panel. The available value is the third-level domain, for example, `123456.selvpc.ru` or `project.example.com`.
* `theme` — (Optional) Additional theme settings for the external panel.

  * `color` — (Optional) Fill color of the toolbar in hex format.

  * `logo` — (Optional) URL of the logo on the toolbar.

## Attributes reference \{#attributes-reference}

* `url` — Project URL. Created automatically and you cannot change it.

* `enabled` — Project status. Possible values are `active` and `disabled`.

* `all_quotas` — List of quotas. Can differ from the values that are set in the `quotas` block, if all available quotas for the project are automatically applied.

## Import \{#import}

You can import a project:

```shell
export OS_DOMAIN_NAME=<account_id>
export OS_USERNAME=<username>
export OS_PASSWORD=<password>
terraform import selectel_vpc_project_v2.project_1 <project_id>
```

where:

* `<account_id>` — ID аккаунта Selectel. ID аккаунта находится in правом верхнем углу [панели управления](https://my.selectel.ru/). Подробнее о [регистрации](/account/registration/).

* `<username>` — имя сервисного пользователя. Чтобы узнать имя, in [панели управления](https://my.selectel.ru/iam/users_management/users?type=service) перейдите in **Identity & Access Management** ⟶ **Управление пользователями** ⟶ вкладка **Сервисные пользователи** ⟶ скопируйте имя нужного пользователя. Подробнее о [сервисных пользователях](/access-control/access-management/).

* `<password>` — пароль сервисного пользователя.

* `<project_id>` — уникальный идентификатор проекта, например, `a07abc12310546f1b9291ab3013a7d75`. Чтобы узнать ID, in [панели управления](https://my.selectel.ru/vpc/) перейдите in **Облачная платформа** ⟶ имя проекта ⟶ скопируйте ID нужного проекта.
