1
0
mirror of https://github.com/quay/quay.git synced 2026-01-27 18:42:52 +03:00
Files
quay/features/__init__.pyi
kwestpharedhat 15fa20a115 QuotaManagement: Reporting (PROJQUAY-2936) (#1048)
* initial commit

* fixing some bugs

* create quota management

Fix json request json type

Creation of quota is working

All quota crud operations

crud for quota limits

repository size reporting

adding registry model

error levels

namespacequota

remove holdover from user file

finalizing refactor to namespace over organization

finalization of functionality

fixing formatting to match with black style

missed some files in formatting

fixing access to attribute

add single test to verify its working

fix some bugs and add defensive catching

bug fixes and code resiliency

Bug fixes and making quota limits detect properly where necessary

remove transitive delete and other bug fixes

fix formatting and trasnitive deletion issues

fix repositorysize does not exist error

fix not nul constraint and add security tests

fix security tests and bug

more security test fixes

reorder security tests

put docker file back and adjust security testing

security tests reduced

Missed changes for status 200

missed additional 201 responses getting 200

security bypass for now

Another tweak to security testing

forgot 1 endpoint

bug fix for parsing dictionary

remove unnecessary check at blob head

add initdb for quota

Incorrect syntax repair

mysql only supports decimal

adding quota specific notifications

optimization

add permission checks

adjust security and add configuration parameter

fix security test for new security levels

Fix logic errors and improve caching

fix logic issue and error reporting

adjust things according to PR comments

fix refactor left overs

miscapitilazation

missed refactor location

refactor code to remove quota limit groupings

fix refactor errors

remove transitive deletion

fix transitive deletes

Transitive deletion work

Transitive deletion work

refactor registry model and remove it

place api behind feature flag

patch feature enabledment for tests

patch feature enabledment for tests

testing to see if the config is the problem

remove patch

fix new org bug

fixing notifications

mismatched parameters

fix org not exists

fixed paramter mismatch

fix nonetype access

fix nonetype access

new tables created user deletion issues

new tables created user deletion issues

parameter mismatch

fix transitive delete

fix model access error

record does not exist missing catch

fix quota deletion to always delete limits

quotalimits deletion on quota deletion

mistake

fix quota limits deletion

patch tests and disable feature

typo

switch to toggle feature

add feature patch to top of file

change testconfigpy

* change permissions

* adjust permissions

* change config access

* fix formatting

* gether feature information differently

* duplicate function name

* fix config name

* type conversion

* config adjustments

* incorrect keyword

* Update security api tests

* duplicate naming

* fix config schema

* revert files and fix error

* QuotaManagement: UI (PROJQUAY-2936) (#1)

* [WIP]: Quota Reporting on Quay UI

* Integrating quota reporting UI with backend

* Humanizing bytes on UI

* Quota Reporting UI on repo table view

* Taking pull and updating code

* Adding quota management view

* Added support for CRUD operations for org quota

* create quota management

Fix json request json type

Creation of quota is working

All quota crud operations

crud for quota limits

repository size reporting

adding registry model

error levels

namespacequota

remove holdover from user file

finalizing refactor to namespace over organization

finalization of functionality

fixing formatting to match with black style

missed some files in formatting

fixing access to attribute

add single test to verify its working

fix some bugs and add defensive catching

bug fixes and code resiliency

Bug fixes and making quota limits detect properly where necessary

remove transitive delete and other bug fixes

fix formatting and trasnitive deletion issues

fix repositorysize does not exist error

fix not nul constraint and add security tests

fix security tests and bug

more security test fixes

reorder security tests

put docker file back and adjust security testing

security tests reduced

Missed changes for status 200

missed additional 201 responses getting 200

security bypass for now

Another tweak to security testing

forgot 1 endpoint

bug fix for parsing dictionary

remove unnecessary check at blob head

add initdb for quota

Incorrect syntax repair

mysql only supports decimal

adding quota specific notifications

optimization

add permission checks

adjust security and add configuration parameter

fix security test for new security levels

Fix logic errors and improve caching

fix logic issue and error reporting

adjust things according to PR comments

fix refactor left overs

miscapitilazation

missed refactor location

refactor code to remove quota limit groupings

fix refactor errors

remove transitive deletion

fix transitive deletes

Transitive deletion work

Transitive deletion work

refactor registry model and remove it

place api behind feature flag

patch feature enabledment for tests

patch feature enabledment for tests

testing to see if the config is the problem

remove patch

fix new org bug

fixing notifications

mismatched parameters

fix org not exists

fixed paramter mismatch

fix nonetype access

fix nonetype access

new tables created user deletion issues

new tables created user deletion issues

parameter mismatch

fix transitive delete

fix model access error

record does not exist missing catch

fix quota deletion to always delete limits

quotalimits deletion on quota deletion

mistake

fix quota limits deletion

patch tests and disable feature

typo

switch to toggle feature

add feature patch to top of file

change testconfigpy

* Removing quota and state conf from repo-list and user-view

* Removing quota and state conf form app list page

* Removing quota conf from repo-list.html

* minor fixes

* Added Quota Repoting and configuring quota from UI

* Making quota configuration component reusable + added support to read bytes via KB, MB, etc + Added reporting for total org consumption + Added org consumption for super user panel + Added quota configurable support on super user panel

* Adding older quota management component

* Removing not reusable quota management component

* Adding % consumption for repo quotas

* Adding % consumption for organization level quota

* Adding check to verify request.args

* Removing todo

* Adding default 0 to quota

* Formatting with black

* Fixing params for tests

* Formatting test file

Co-authored-by: Keith Westphal <kwestpha@redhat.com>

* remove migration

* add migration back

* repair formatting

* QuotaManagement: Moving the logic for bytes conversion to human friendly units to the frontend  (PROJQUAY-2936) (#3)

* Moving the logic for bytes conversion to human friendly units to the frontend

* Reading updates from quota_limit_id

* Formatting using black

* remote unused function

* Adding quota configuring on super user panel (#4)

* Converting quota bytes to human friendly format (#5)

* PR refactors

* invalid reference

* bad return value

* fix bad reference

* bad reference

* fix tests

* Quota Config: UI improvements (#6)

* Quota UI Improvements

* Rendering table for quota limit config

* Removing proxy cache files

* Disabling quota config for org view

* Removing redundant get

* Fixing PR requests

* repair formatting

Co-authored-by: Sunandadadi <Sunandadadi@users.noreply.github.com>
2022-03-08 12:02:03 -06:00

187 lines
6.2 KiB
Python

class FeatureNameValue(object):
def __init__(self, name: str, value: bool): ...
def __str__(self) -> str: ...
def __repr__(self) -> str: ...
def __cmp__(self, other): ...
def __bool__(self) -> bool: ...
def import_features(config_dict): ...
def get_features() -> Dict[str, FeatureNameValue]: ...
# Feature Flag: Whether sessions are permanent.
PERMANENT_SESSIONS: FeatureNameValue
# Feature Flag: Whether super users are supported.
SUPER_USERS: FeatureNameValue
# Feature Flag: Whether to allow anonymous users to browse and pull public repositories.
ANONYMOUS_ACCESS: FeatureNameValue
# Feature Flag: Whether billing is required.
BILLING: FeatureNameValue
# Feature Flag: Whether user accounts automatically have usage log access.
USER_LOG_ACCESS: FeatureNameValue
# Feature Flag: Whether GitHub login is supported.
GITHUB_LOGIN: FeatureNameValue
# Feature Flag: Whether Google login is supported.
GOOGLE_LOGIN: FeatureNameValue
# Feature Flag: Whether to support GitHub build triggers.
GITHUB_BUILD: FeatureNameValue
# Feature Flag: Whether to support Bitbucket build triggers.
BITBUCKET_BUILD: FeatureNameValue
# Feature Flag: Whether to support GitLab build triggers.
GITLAB_BUILD: FeatureNameValue
# Feature Flag: Dockerfile build support.
BUILD_SUPPORT: FeatureNameValue
# Feature Flag: Whether emails are enabled.
MAILING: FeatureNameValue
# Feature Flag: Whether users can be created (by non-super users).
USER_CREATION: FeatureNameValue
# Feature Flag: Whether users being created must be invited by another user.
# If USER_CREATION is off, this flag has no effect.
INVITE_ONLY_USER_CREATION: FeatureNameValue
# Feature Flag: Whether users can be renamed
USER_RENAME: FeatureNameValue
# Feature Flag: Whether non-encrypted passwords (as opposed to encrypted tokens) can be used for
# basic auth.
REQUIRE_ENCRYPTED_BASIC_AUTH: FeatureNameValue
# Feature Flag: Whether to automatically replicate between storage engines.
STORAGE_REPLICATION: FeatureNameValue
# Feature Flag: Whether users can directly login to the UI.
DIRECT_LOGIN: FeatureNameValue
# Feature Flag: Whether the v2/ endpoint is visible
ADVERTISE_V2: FeatureNameValue
# Feature Flag: Whether to restrict V1 pushes to the whitelist.
RESTRICTED_V1_PUSH: FeatureNameValue
# Feature Flag: Whether or not to rotate old action logs to storage.
ACTION_LOG_ROTATION: FeatureNameValue
# Feature Flag: Whether to enable conversion to ACIs.
ACI_CONVERSION: FeatureNameValue
# Feature Flag: Whether to allow for "namespace-less" repositories when pulling and pushing from
# Docker.
LIBRARY_SUPPORT: FeatureNameValue
# Feature Flag: Whether to require invitations when adding a user to a team.
REQUIRE_TEAM_INVITE: FeatureNameValue
# Feature Flag: Whether to proxy all direct download URLs in storage via the registry's nginx.
PROXY_STORAGE: FeatureNameValue
# Feature Flag: Whether to collect and support user metadata.
USER_METADATA: FeatureNameValue
# Feature Flag: Whether to support signing
SIGNING: FeatureNameValue
# Feature Flag: Whether to enable support for App repositories.
APP_REGISTRY: FeatureNameValue
# Feature Flag: Whether app registry is in a read-only mode.
READONLY_APP_REGISTRY: FeatureNameValue
# Feature Flag: If set to true, the _catalog endpoint returns public repositories. Otherwise,
# only private repositories can be returned.
PUBLIC_CATALOG: FeatureNameValue
# Feature Flag: If set to true, build logs may be read by those with read access to the repo,
# rather than only write access or admin access.
READER_BUILD_LOGS: FeatureNameValue
# Feature Flag: If set to true, autocompletion will apply to partial usernames.
PARTIAL_USER_AUTOCOMPLETE: FeatureNameValue
# Feature Flag: If set to true, users can confirm (and modify) their initial usernames when
# logging in via OIDC or a non-database internal auth provider.
USERNAME_CONFIRMATION: FeatureNameValue
# Feature Flag: If set to true, Quay will run using FIPS compliant hash functions.
FIPS: FeatureNameValue
# Security scanner
SECURITY_SCANNER: FeatureNameValue
SECURITY_NOTIFICATIONS: FeatureNameValue
# Repository mirror
REPO_MIRROR: FeatureNameValue
# Site key and secret key for using recaptcha.
RECAPTCHA: FeatureNameValue
# Feature Flag: Whether team syncing from the backing auth is enabled.
TEAM_SYNCING: FeatureNameValue
# Feature Flag: If enabled, non-superusers can setup team syncing.
NONSUPERUSER_TEAM_SYNCING_SETUP: FeatureNameValue
# Feature Flag: Whether users can view and change their tag expiration.
CHANGE_TAG_EXPIRATION: FeatureNameValue
# Feature Flag: If enabled, users can create and use app specific tokens to login via the CLI.
APP_SPECIFIC_TOKENS: FeatureNameValue
# Feature Flag: Whether to record when users were last accessed.
USER_LAST_ACCESSED: FeatureNameValue
# Feature Flag: Whether to allow users to retrieve aggregated log counts.
AGGREGATED_LOG_COUNT_RETRIEVAL: FeatureNameValue
# Feature Flag: Whether rate limiting is enabled.
RATE_LIMITS: FeatureNameValue
# Feature Flag: Whether to support log exporting.
LOG_EXPORT: FeatureNameValue
# Feature Flag: Whether pull logs are disabled for free namespace.
DISABLE_PULL_LOGS_FOR_FREE_NAMESPACES: FeatureNameValue
# Feature Flag: If set to true, no account using blacklisted email addresses will be allowed
# to be created.
BLACKLISTED_EMAILS: FeatureNameValue
# Feature Flag: Whether garbage collection is enabled.
GARBAGE_COLLECTION: FeatureNameValue
# Feature Flags: Whether the workers for GCing deleted namespaces and repositories
# are enabled.
NAMESPACE_GARBAGE_COLLECTION: FeatureNameValue
REPOSITORY_GARBAGE_COLLECTION: FeatureNameValue
# Feature Flag: Whether to clear expired RepositoryActionCount entries.
CLEAR_EXPIRED_RAC_ENTRIES: FeatureNameValue
# Feature Flag: Whether OCI manifest support should be enabled generally.
GENERAL_OCI_SUPPORT: FeatureNameValue
# Feature Flag: Whether the repository action count worker is enabled.
REPOSITORY_ACTION_COUNTER: FeatureNameValue
# TEMP FEATURE: Backfill the sizes of manifests.
MANIFEST_SIZE_BACKFILL: FeatureNameValue
# Feature Flag: If set to true, the first User account may be created via API /api/v1/user/initialize
USER_INITIALIZE: FeatureNameValue
# Allows "/" in repository names
EXTENDED_REPOSITORY_NAMES: FeatureNameValue
QUOTA_MANAGEMENT: FeatureNameValue