Skip to content

Conversation

@QuanMPhm
Copy link
Contributor

Closes CCI-MOC/ops-issues#1615 (comment)

To use this feature, first create a Coldfront allocation with the appropriate OpenShift resource. Before approving it, use the admin dashboard to add the attributes Allocated Project ID and Allocated Project Name to the allocation, both assigned to the name of the pre-existing project. Afterwards, approve the allocation, then run validate_allocations to populate the quota fields (as well as create various other OpenShift objects) on the allocation and the OpenShift project

Do note, because of how validation is handled for quotas [1], if the pre-existing project already defined its quotas, Coldfront won't overwrite them with the default quotas.

[1]

# We just checked the case where the quota value is set in the cluster
# but not in coldfront. This is the only case the cluster value is the
# "source of truth" for the quota value
# If the coldfront value is set, it is always the source of truth.
# But first, we need to check if the quota value is set anywhere at all.
# TODO (Quan): Refactor these if statements so that we can remove this comment block

…cations

To use this feature, first create a Coldfront allocation with the
appropriate OpenShift resource. Before approving it, use the admin
dashboard to add the attributes `Allocated Project ID` and `Allocated Project Name`
to the allocation, both assigned to the name of the pre-existing project.
Afterwards, approve the allocation, then run `validate_allocations` to
populate the quota fields (as well as create various other OpenShift objects)
on the allocation and the OpenShift project

Do note, because of how validation is handled for quotas [1], if the
pre-existing project already defined its quotas, Coldfront won't
overwrite them with the default quotas.

[1] https://github.com/nerc-project/coldfront-plugin-cloud/blob/1b2338d309c7db1c5a418d25fc40169b7edae055/src/coldfront_plugin_cloud/management/commands/validate_allocations.py#L311-L316
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Create a Coldfront allocation to track a pre-existing Openshift project

2 participants