Managing projects
You can add more projects, as described in Configuring multitenancy. Also, you can edit project details and quotas, manage user assignment, as well as enable/disable and delete the existing projects. Enabling and disabling projects allows or prohibits access to projects in the self-service panel.
Limitations
- A project cannot be deleted if it has virtual objects.
- You can set project quotas only after deploying the compute cluster.
- You cannot configure domain quotas for floating IP addresses, VPN connections, load balancers, Kubernetes clusters, and placements.
Prerequisites
- As quotas can exceed the existing virtual resources and virtual resources are not reserved for each project, the compute cluster must have enough virtual resources for all projects in all domains.
To edit a project name or description
Admin panel
- On the Settings > Projects and users screen, click the domain, within which you want to manage projects.
- Go to the Projects tab, click the ellipsis icon next to the project, and then click Edit.
-
Make the required changes, and then click Save.
A description should not contain any personally identifiable information or sensitive business data.
Command-line interface
Use the following command:
vinfra domain project set [--description <description>] [--name <name>] --domain <domain> <project>
--description <description>
-
Project description
A description should not contain any personally identifiable information or sensitive business data.
--name <name>
- Project name
--domain <domain>
- Domain name or ID
<project>
- Project ID or name
For example, to change the name of the project myproject
within the domain mydomain
to newproject
, run:
# vinfra domain project set myproject --domain mydomain --name newproject
To assign users to a project
Admin panel
- On the Settings > Projects and users screen, click the domain, within which you want to manage projects.
- Go to the Projects tab, click the ellipsis icon next to the project, and then click Manage users.
- In the Manage users window, select only those users that you want to assign to the project, and then click Save.
Command-line interface
Use the following command:
vinfra domain user set --assign <project> <role> --domain <domain> <user>
--assign <project> <role>
-
Assign a user to a project with one or more permission sets. Specify this option multiple times to assign the user to multiple projects.
<project>
: project ID or name<role>
: user role in the project (project_admin
)
--domain <domain>
- Domain name or ID
<user>
- User ID or name
For example, to assign the user myuser
from the domain mydomain
to the project myproject
as a project administrator, run:
# vinfra domain user set myuser --domain mydomain --assign myproject project_admin
To unassign users from a project
Admin panel
- On the Settings > Projects and users screen, click the domain, within which you want to manage projects.
- Go to the Projects tab and click the required project.
- On the Users tab, click the bin icon next to a user that you want to unassign from the project.
Command-line interface
Use the following command:
vinfra domain project user remove --user <user> --domain <domain> <project>
--user <user>
- User name or ID
--domain <domain>
- Domain name or ID
<project>
- Project ID or name
For example, to remove the user myuser
from the project myproject
within the domain mydomain
, run:
# vinfra domain project user remove myproject --domain mydomain --user myuser
To edit project quotas
Admin panel
- On the Settings > Projects and users screen, click the domain, within which you want to manage projects.
- Go to the Projects tab, click the ellipsis icon next to the project, and then click Edit quotas.
-
Define quotas for virtual resources that will be available inside the project. To specify a certain value for a resource, clear the Unlimited check box next to it first.
The default storage policy must be shared with projects that will use the Kubernetes-as-a-service feature.
- Click Save to apply your changes.
Command-line interface
Use the following command:
vinfra service compute quotas update [--cores <cores>] [--ram-size <ram>] [--floatingip <floating-ip>] [--storage-policy <storage_policy>:<size>] [--k8saas-cluster <cluster>] [--lbaas-loadbalancer <load-balancer>] [--placement <placement>] [--volumes-backups <volumes-backups-size>] <project-id>
--cores <cores>
- Number of cores
--ram-size <ram>
- Number of RAM. Use the following units:
M
orMiB
for mebibytes,G
orGiB
for gibibytes,T
orTiB
for tebibytes,P
orPiB
for pebibytes, andE
orEiB
for exbibytes. --floatingip <floating-ip>
- Number of floating IP addresses
--storage-policy <storage_policy>:<size>
- Comma-separated list of
<storage_policy>:<size>
. To specify the size, use the following units:M
orMiB
for mebibytes,G
orGiB
for gibibytes,T
orTiB
for tebibytes,P
orPiB
for pebibytes, andE
orEiB
for exbibytes. --k8saas-cluster <cluster>
- Number of Kubernetes clusters
--lbaas-loadbalancer <load-balancer>
- The new value for the load balancer quota limit. The value
-1
means unlimited. --placement <placement>
- Comma-separated list of
<placement-id>:<size>
--volumes-backups <volumes-backups-size>
- The new value for the volumes backups size quota limit
<project-id>
- Project ID
For example, to update quotas for the project with the ID 6ef6f48f01b640ccb8ff53117b830fa3
to 10 vCPUs, 20 GiB of RAM, and 512 GiB of disk space for the default
storage policy, run:
# vinfra service compute quotas update 6ef6f48f01b640ccb8ff53117b830fa3 --cores 10 --ram-size 10G --storage-policy default:512G
You can view the updated quotas in the vinfra service compute quotas show
output:
# vinfra service compute quotas show 79830e3c64c74ded9bac6bffde5d26e4 +----------------------------------------+----------+ | Field | Value | +----------------------------------------+----------+ | compute.cores.limit | 10 | | compute.ram.limit | 10.0GiB | | compute.ram_quota.limit | 10.0GiB | | lbaas.loadbalancer.limit | -1 | | network.floatingip.limit | -1 | | storage.gigabytes.default.limit | 512.0GiB | | storage.storage_policies.default.limit | 512.0GiB | | storage.volumes_backups.limit | -1 | +----------------------------------------+----------+
To enable or disable a project
Admin panel
- On the Settings > Projects and users screen, click the domain, within which you want to manage projects.
- Go to the Projects tab, click the ellipsis icon next to the project, and then click Enable or Disable.
Command-line interface
Use the following command:
vinfra domain project set [--enable | --disable] --domain <domain> <project>
--enable
- Enable project
--disable
- Disable project
--domain <domain>
- Domain name or ID
<project>
- Project ID or name
For example, to disable the project myproject
within the domain mydomain
, run:
# vinfra domain project set myproject --domain mydomain --disable
To delete a project
Admin panel
- On the Settings > Projects and users screen, click the domain, within which you want to manage projects.
- Go to the Projects tab, click the ellipsis icon next to the project, and then click Delete.
- In the confirmation window, click Delete.
Command-line interface
Use the following command:
vinfra domain project delete --domain <domain> <project>
--domain <domain>
- Domain name or ID
<project>
- Project ID or name
For example, to delete the project myproject
from the domain mydomain
, run:
# vinfra domain project delete myproject --domain mydomain