1
0
mirror of https://github.com/quay/quay.git synced 2026-01-26 06:21:37 +03:00
Commit Graph

47 Commits

Author SHA1 Message Date
jbpratt
57a5e3368f feat(ui): add repository activity heatmap (PROJQUAY-9353) (#4398)
* feat(ui): add repository activity heatmap (PROJQUAY-9353)

Implements an activity heatmap showing last 90 days of repository
pull/push activity to match feature available in Angular UI.

Features:
- Continuous week-by-week calendar grid layout
- Smart month labels (Aug, Sep, Oct) with spacing optimization
- Day labels (Mon, Wed, Fri) positioned clearly
- 5-level color scaling from gray (no activity) to dark blue (high activity)
- Interactive tooltips with date and action counts
- Full-width responsive design
- PatternFly design system integration
- ARIA labels for accessibility

Technical implementation:
- Custom React component using SVG rendering
- API integration with includeStats=true endpoint
- Color-coded cells based on activity intensity
- Tooltip with high contrast for dark/light mode support

Co-authored-by: Claude <noreply@anthropic.com>
Signed-off-by: Brady Pratt <bpratt@redhat.com>

* fix(test): resolve builds.cy.ts failures from includeStats param change (PROJQUAY-9353)

Fixed 21 failing Cypress tests in builds.cy.ts caused by two issues:

1. Updated all repository detail API intercepts to use includeStats=true
   instead of includeStats=false to match the actual API call changed
   in the heatmap feature implementation

2. Added optional chaining to error.response?.status in ErrorHandling.ts
   to prevent null reference errors when error.response is undefined

All 27 tests now pass (previously 6 passing, 21 failing).

Co-authored-by: Claude <noreply@anthropic.com>
Signed-off-by: Brady Pratt <bpratt@redhat.com>

---------

Signed-off-by: Brady Pratt <bpratt@redhat.com>
Co-authored-by: Claude <noreply@anthropic.com>
2025-10-30 10:27:47 -05:00
jbpratt
bf24701ef3 feat(ui): add Information tab as default for repository view (PROJQUAY-9556) (#4386)
* feat(ui): add Information tab as default for repository view (PROJQUAY-9556)

Adds a new Information tab to the repository details page that displays:
- Repository description (editable for users with write permissions)
- Pull commands (podman and docker)
- Repository activity placeholder (to be implemented later)

The Information tab now appears first and is the default tab when viewing
a repository, replacing Tags as the default. This matches the behavior of
the old Angular UI and provides users with essential repository information
upfront.

Updated existing Cypress tests to navigate to the Tags tab explicitly where
needed, and added new tests to verify the Information tab is the default.

Co-authored-by: Claude <noreply@anthropic.com>
Signed-off-by: Brady Pratt <bpratt@redhat.com>

* feat(ui): add markdown rendering for repository descriptions (PROJQUAY-9556)

Repository descriptions now support markdown formatting including:
- GitHub Flavored Markdown (headings, lists, links, etc.)
- Code blocks with syntax highlighting and copy-to-clipboard functionality
- Tables styled with PatternFly components
- Inline code formatting

This restores markdown capability that existed in the legacy UI and uses
the same react-markdown implementation pattern as ModelCard. The edit
mode now indicates markdown support to guide users.

Co-authored-by: Claude <noreply@anthropic.com>

* refactor(ui): use PatternFly design tokens for markdown styling (PROJQUAY-9556)

Replaces hardcoded inline styles with CSS classes using PatternFly design
tokens for better consistency with the design system:

- Inline code: Uses global BackgroundColor, spacer, BorderRadius, and
  FontFamily tokens
- Table cells: Uses global BorderColor and spacer tokens

This improves theme consistency and makes the styling more maintainable
by leveraging the PatternFly design system instead of magic values.

Also adds TypeScript types to MarkdownCodeBlock event handlers for better
type safety.

Co-authored-by: Claude <noreply@anthropic.com>

* clean up additional tests

Signed-off-by: Brady Pratt <bpratt@redhat.com>

---------

Signed-off-by: Brady Pratt <bpratt@redhat.com>
Co-authored-by: Claude <noreply@anthropic.com>
2025-10-21 14:07:36 -04:00
Shubhra Deshpande
49ff0da0c2 feat: Added Redis database and Redis flush worker (PROJQUAY-7176) (#4321)
* Added redis database and redis flush worker

* updated digest validation

* adding test coverage for scan_keys function

* adding test coverage

* added tests for scan function

* added coverage for flush to database function

* added coverage for gnuicorn worker initialization

* Replaced mock methods in the test with actual function calls

---------

Co-authored-by: shudeshp <shudeshp@redhat.com>
2025-10-17 09:27:11 -04:00
Harish Govindarajulu
f63d25bdd3 nginx: Add nginx routing logic to default to react UI for downstream (PROJQUAY-9207) (#4252)
* Add ngnix routing logic to default to react UI for downstream

* Remove defaulting from env, update Makefile to build react by default for local

* Add cypress test for signin and create account workflow

* Add missing routes + fallback to backend server

* Hide UI toggle when defaulting to new UI

* Adds forgot password + recovery email, recaptcha, missing login checks

* Add external login screen + support for other login types for new UI

* Add new screen for update user after external login

* Add authorized apps section under external logins tab

* Implement updateuser react component + fix cypress test

* Fix external login OAuth flow for react

* switch logic to default to new ui

* Add DEFAULT_UI: angular to config for cypress CI

* Fix cypress tests for oauth-callback

* Rebase and fix merge conflicts

---------

Signed-off-by: harishsurf <hgovinda@redhat.com>
2025-10-14 15:10:39 -04:00
jbpratt
427107dd47 ui: add show/hide signatures toggle for tags view (PROJQUAY-7019) (#4334)
this adds functionality to filter out cosign signature tags (.sig),
SBOM tags (.sbom), and attestation tags (.att) from the tags list.
users can toggle visibility with a button in the toolbar, matching
the behavior from the angular UI. when repositories contain many tags
with signatures (1K+), this prevents UI cluttering by hiding signature
artifacts by default.

implementation:
- added showSignaturesState recoil atom to track toggle state
- added isCosignSignatureTag() utility to detect signature patterns
- added "Show/Hide Signatures" button to tags toolbar
- signature tags are hidden by default (showSignatures: false)
- filter applied before pagination and sorting

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Signed-off-by: Brady Pratt <bpratt@redhat.com>
Co-authored-by: Claude <noreply@anthropic.com>
2025-10-14 11:02:04 -05:00
Shubhra Deshpande
ba57ee67e6 db: Added TagPullStatistics and ManifestPullStatistics tables with migrations (PROJQUAY-8414) (#4318)
Added TagPullStatistics and ManifestPullStatistics tables with migrations



---------

Co-authored-by: shudeshp <shudeshp@redhat.com>
2025-10-07 10:59:37 -04:00
Brandon Caton
09ba46e025 ui: fixing flake by updating start date (#4188)
* ui: fixing flake by updating start date

* updating tag creation for other tests
2025-08-14 16:06:21 -04:00
Ivan Bazulic
9be679eb58 mirror: Add job timeout to mirror configurations (PROJQUAY-7249) (#3723)
* mirror: Add job timeout to mirror configurations (PROJQUAY-7249)
Previous global job timeout of 5 minutes was inadequate for big images. The timeout should now be configurable in much the same way as sync is. Minimum job length is 300 seconds/5 minutes.

The PR is still work in progress.

* Fix init db, remove reference to user data in logs

* Fix tests, change repo mirror configuration

* Fix tests, make mirroring cancellable through UI

* Add cancel mirror test, change HTML document to reflect mirror timeout

* Flake8 doesn't like when '==' is used with 'None'

* Fix mirror registry tests

* Add new cypress data to fix cypress tests

* Added ability to define upload chunk size to RADOS driver, small changes to repo mirror HTML page

* Fix database migration to follow HEAD

* Upload new database data for Cypress tests

* Make skopeo_timeout_interval mandatory on API calls

---------

Co-authored-by: Ivan Bazulic <ibazulic@redhat.com>
2025-06-12 19:09:51 +02:00
Harish Govindarajulu
813be12ea7 ui: Add proxy cache config UI to org settings (PROJQUAY-7697) (#3388)
* ui: Add proxy cache config UI to org settings (PROJQUAY-7697)

* Fix alerts + reset input fields on user action

* Add cypress test for proxy cache config

* enable proxy cache for cypress test

* Propagate backend api error to UI

* Add additional cypress test coverage

* Fix eslint error

---------

Signed-off-by: harishsurf <hgovinda@redhat.com>
2024-11-27 07:56:20 +05:30
Ivan Bazulic
77bc70a637 logs: Audit export logs requests (PROJQUAY-7679) (#3146)
* logs: Audit export logs requests (PROJQUAY-7679))
We add the ability to audit export logs requests that were previously not tracked.

* Add UI elements to properly render new audit log

* Truncate date/time column on exterme zooms

* Add initdb.py entries

* Fix migration and add test db data

* Add test database and fix migration paths

* Changed logging mechanism to grab raised exceptions

* Fix improper import

* Add date/time timestamp to saved metadata

* Change message on export logs screen in UI

* Changed message in old UI as well

* Change log description in new UI too

* Simplify call logic and add additonal information to logged errors
2024-10-03 13:07:22 -04:00
Sunandadadi
f327551ccc autoprune: support multiple organization and repository policies (PROJQUAY-7695) (#3209)
* autoprune: support multiple organization policies (PROJQUAY-7695)

* ui to support multiple org policies

* backend to support multiple repository autoprune policies

* ui: multiple repository policies

* fixing tests

* adding tests
2024-09-20 09:18:09 -04:00
Brandon Caton
27d7c149b9 db: adding immutable column to tag table (PROJQUAY-7777) (#3195)
Adding immutable column to tag table
2024-09-19 10:02:20 -04:00
Brandon Caton
4c15712a82 db: fixing alembic migration (PROJQUAY-7493) (#3044)
fixing alembic migration
2024-07-17 15:02:53 -04:00
Kenny Lee Sin Cheong
32890207da registry: index manifest artifact type for filtering (PROJQUAY-7471) (#3035)
Previous assumption made use of the config media type only, which is not the case
if a manifest's artifact type is explicitly set. i.e the config's media type and
artifact type are different, and the artifact type take precedence for filtering.
2024-07-16 22:33:38 +00:00
Brandon Caton
916aff690c oauth: logging assign oauth action to audit logs (PROJQUAY-7431) (#3033)
logging assign oauth action to audit logs
2024-07-16 14:24:17 -04:00
Sunandadadi
6c371c5406 db: updates for image expiry notification (PROJQUAY-7075) (#2894)
* resolving conflicts

* database: adding subject_backfilled index to manifest table (PROJQUAY-7360) (#2963)

adding subject_backfilled index to manifest table

* adding index to last_ran_ms and updating alembic head

* minor fixes

* updating cypress data

---------

Co-authored-by: Brandon Caton <bcaton@redhat.com>
2024-06-25 15:59:40 -04:00
Brandon Caton
e4f05583c1 oauth: allowing to assign token to user (PROJQUAY-7074) (#2869)
Allow organization administrators to assign Oauth token to another user.
2024-06-25 09:23:51 -04:00
Brandon Caton
bc06a3ef36 database: adding subject_backfilled index to manifest table (PROJQUAY-7360) (#2963)
adding subject_backfilled index to manifest table
2024-06-24 14:04:27 -04:00
Kenny Lee Sin Cheong
4546163e83 registry: implements the OCI 1.1 referrers API (PROJQUAY-7280) (#2597)
* registry: implements the OCI 1.1 referrers API

Migrations:
- Adds a subject column for lookup
- Adds a subject_backfilled column to track status of the backfilling
of existing manifests
- Adds a manifest_json column making use of postgres' JSONB support,
for future use.

Manifestsubjectbackfillworker: Indexes existing manifests for possible
existing subject field.

* Deprecate IGNORE_UNKNOWN_MEDIATYPES

* Cleanup
2024-06-07 13:28:13 -04:00
Harish Govindarajulu
3e55c5940b autoprune: add alembic script to remove unique constraint on index (PROJQUAY-6782) (#2725)
Make "repositoryautoprunepolicy_namespace_id" index not unique to avoid
duplicate key violation error

Signed-off-by: harishsurf <hgovinda@redhat.com>
2024-03-07 23:53:57 +05:30
Harish Govindarajulu
98811f5397 feat: Add auto-prune policy at repository level (PROJQUAY-6354) (#2691)
* feat: Add support for auto pruning at repository level (PROJQUAY-6354)

* Add repositoryautoprunepolicy table to alembic migration script

* Add repository auto-prune policy endpoints

* Add UI for repository auto-pruning policies

* case: apply repo auto-prune policy when no namespace policy given

* case: both namespace and repo pruning policy are given

* Add tests for repository autoprune endpoint

* Add cypress test for repository auto-prune

* Add repo auto-prune policy clean-up for repository deletion

* Add repository auto pruning tables to quay db snapshot for cypress tests

* Address review comments

* Add more tests + fix CI + reformat files

* Address review comments #2

---------

Signed-off-by: harishsurf <hgovinda@redhat.com>
2024-02-27 15:02:57 +05:30
Brandon Caton
b641538bad ui: removing repo settings and build UI feature flags (PROJQUAY-6617) (#2680)
Removing repo settings and build UI feature flags since they should be enabled by default.
2024-02-19 09:19:10 -05:00
Marcus Kok
5c44cc483f ui: add section for RH subscriptions under billing settings (PROJQUAY-5363) (#2656)
* Add marketplace ui to patternfly
* Fix bug where unlimited private repo sku
showed extremely large number in ui
2024-02-08 14:03:59 -05:00
Marcus Kok
2ab7dc29f4 marketplace: add support for quantity from subscriptions api (PROJQUAY-6551) (#2633)
* Adds handling for when a subscription returned from the subscription watch api has a quantity greater than 1. Number of private repos should be correctly calculated using the quantity.

* Updates ui so that subscriptions can only be added to an org as a group, i.e. a subscription with quantity = 2 cannot be split across organizations.
2024-01-29 15:21:30 -05:00
Brandon Caton
7cec2f6697 ui: implementing creation of custom git trigger (PROJQUAY-6299) (#2599)
Implements the build trigger creation wizard.
2024-01-17 10:04:44 -05:00
Daniel Messer
e8ff33e728 logs: add failure logging for login, push, pull and delete events (PROJQUAY-5411) (#1903)
* add login failure logging

Signed-off-by: dmesser <dmesser@redhat.com>

* move failure logging into credential validation

Signed-off-by: dmesser <dmesser@redhat.com>

* more precise tracking of affected users

Signed-off-by: dmesser <dmesser@redhat.com>

* fix indent

Signed-off-by: dmesser <dmesser@redhat.com>

* differentiate robots with wrong credentials

Signed-off-by: dmesser <dmesser@redhat.com>

* don't audit failures by default

Signed-off-by: dmesser <dmesser@redhat.com>

* discrete failure tracking for logins, push, pulls and deletes

Signed-off-by: dmesser <dmesser@redhat.com>

* refine log metadata

Signed-off-by: dmesser <dmesser@redhat.com>

* login failure log visualization

Signed-off-by: dmesser <dmesser@redhat.com>

* properly use data model

Signed-off-by: dmesser <dmesser@redhat.com>

* fix unit test bug

Signed-off-by: dmesser <dmesser@redhat.com>

* track non-existing repos differently

Signed-off-by: dmesser <dmesser@redhat.com>

* log view visualization of failed pushes and pulls

Signed-off-by: dmesser <dmesser@redhat.com>

* ensure all tests are conducted with failure logging

Signed-off-by: dmesser <dmesser@redhat.com>

* additional unicode protection

Signed-off-by: dmesser <dmesser@redhat.com>

* python black formatting

Signed-off-by: dmesser <dmesser@redhat.com>

* add cypress test data

Signed-off-by: dmesser <dmesser@redhat.com>

* add safety checks for ascii conversion attempts

Signed-off-by: dmesser <dmesser@redhat.com>

* adjusting unit test with correct error message

Signed-off-by: dmesser <dmesser@redhat.com>

* update to alembic head

Signed-off-by: dmesser <dmesser@redhat.com>

* add standard oauth token metadata in audit

Signed-off-by: dmesser <dmesser@redhat.com>

* update alembic head

Signed-off-by: dmesser <dmesser@redhat.com>

* correct field name

Signed-off-by: dmesser <dmesser@redhat.com>

* formatting

Signed-off-by: dmesser <dmesser@redhat.com>

* bump alembic head

Signed-off-by: dmesser <dmesser@redhat.com>

* refactor auth logging imports

Signed-off-by: dmesser <dmesser@redhat.com>

* bump alembic head

Signed-off-by: dmesser <dmesser@redhat.com>

* formatting

Signed-off-by: dmesser <dmesser@redhat.com>

* restore module

Signed-off-by: dmesser <dmesser@redhat.com>

* pre-commit fixes

Signed-off-by: dmesser <dmesser@redhat.com>

* adding missing default

Signed-off-by: dmesser <dmesser@redhat.com>

* bump alembic head

Signed-off-by: dmesser <dmesser@redhat.com>

* update test data

Signed-off-by: dmesser <dmesser@redhat.com>

* refactoring to save db calls

Signed-off-by: dmesser <dmesser@redhat.com>

* fix unit tests

Signed-off-by: dmesser <dmesser@redhat.com>

* handle unicode conversion errors on email look up

Signed-off-by: dmesser <dmesser@redhat.com>

* bump alembic head

Signed-off-by: dmesser <dmesser@redhat.com>

* proper debug logging and conditional db calls

Signed-off-by: dmesser <dmesser@redhat.com>

* omit wildcard import

Signed-off-by: dmesser <dmesser@redhat.com>

* re-add import

Signed-off-by: dmesser <dmesser@redhat.com>

---------

Signed-off-by: dmesser <dmesser@redhat.com>
2024-01-16 16:46:20 +01:00
Brandon Caton
27cceb1bb4 ui: adding build trigger table (PROJQUAY-6295) (#2570)
Adds the table to view configured build triggers for a repository. Includes enabling/disabling, deletion, viewing credentials, and notifying of automatically disabled triggers.
2024-01-11 09:02:24 -05:00
Sunandadadi
77d6ad741b ui: breadcrumbs fix when org and repo names are identical (PROJQUAY-6504) (#2569)
* ui: breadcrumbs fix when org and repo names are identical (PROJQUAY-6504)

* eslint fix

* add tests for team name identical to org and repo name

* format fix

* revert db inserts for queueitem and log table
2023-12-19 16:02:52 -05:00
Brandon Caton
236e2fe4fd autoprune: adding audit logs to namespace autoprune policy API (PROJQUAY-6229) (#2431)
Add's audit logs to the CRUD endpoints for both user and organization namespace auto-prune policies.
2023-12-04 13:51:52 -05:00
Harish Govindarajulu
94ca5b31c6 ui: fix tab visibility for teams and membership (PROJQUAY-6333) (#2451)
* ui: fix tab visibility for teams and membership (PROJQUAY-6333)

* Add readonly checks when user doesn't have sufficient permissions

* Add test for non-admin user of a team

---------

Signed-off-by: harishsurf <hgovinda@redhat.com>
2023-11-13 13:35:32 -05:00
Harish Govindarajulu
81bf634749 ui: Add bulk deletion for default permissions (PROJQUAY-6093) (#2336)
Signed-off-by: harishsurf <hgovinda@redhat.com>
2023-10-18 15:56:35 -04:00
Brandon Caton
fa8aaa328f autoprune: background worker (PROJQUAY-6095) (#2402)
Implementation of the background worker for namespace auto-pruning.

Co-authored-by: Sunanda Dadi <Sunandadadi@users.noreply.github.com>
2023-10-16 16:45:20 -04:00
Brandon Caton
1676cc04e5 autoprune: UI settings (PROJQUAY-6097) (#2399)
Adds auto-prune configuration to user and organization settings.
2023-10-11 13:48:55 -04:00
Brandon Caton
0e496b46a5 autoprune: add initial setup for the autoprune feature (PROJQUAY-6094) (#2277)
Adds the auto-prune worker, database models, and feature flag.
2023-10-05 13:37:36 -04:00
Brandon Caton
9a9355e5f2 quota: adding indexes to the quota size tables (PROJQUAY-6048) (#2268)
Adding indexes to the quotanamespacesize and quotarepositorysize tables.
2023-10-02 09:09:35 -04:00
Harish Govindarajulu
b76fa5bc9f ui: Default Permissions tab (PROJQUAY-4570) (#1856)
Signed-off-by: harishsurf <hgovinda@redhat.com>
2023-09-27 12:40:09 -04:00
Harish Govindarajulu
226684dfc7 ui: Teams and members (PROJQUAY-4569) (#2007)
Add team and membership tab for organization (PROJQUAY-4569)

Signed-off-by: harishsurf <hgovinda@redhat.com>
2023-08-29 15:03:56 -04:00
Brandon Caton
3ad9460846 ui: adding tag history panel (PROJQUAY-5720) (#2115)
Implements the tag history view.
2023-08-28 12:13:50 -04:00
Marcus Kok
e44783fe19 billing: Assign SKU to org (PROJQUAY-5363) (#1989)
* add migration for orgrhskus table

* add endpoints for managing and listing skus bound to an org

* create checks in billing flow to look for org-bound skus

* refactor RH marketplace api objects to be more usable in tests

* update cypress test db data and exclude it from pre-commit hook formatting
2023-08-25 14:52:54 -04:00
Brandon Caton
c8bc48e326 ui: adding create tag option and generic alerts (PROJQUAY-5290) (#1996)
Adds tag options dropdown and the create tag option. Also adds generic alerts through the useAlerts hook.
2023-07-20 15:04:07 -04:00
Daniel Messer
fbc4d7800d change removed_tag_expiration_s to bigint (#1929)
Signed-off-by: dmesser <dmesser@redhat.com>
2023-06-05 11:03:17 +02:00
Brandon Caton
6cf0a3531b quota: calculating registry size (PROJQUAY-5476) (#1879)
Allows superusers to trigger a calculation of the deduplicated registry size. A superuser can go to the organization panel of the superuser page and select Calculate to queue a calculation of the registry total. The total will only be calculated when requested. Includes warning to user of increase of database load when running calculation.
2023-05-24 17:10:40 -04:00
Daniel Messer
41cd8330d0 logs: add audit log events for login/logout to Quay (PROJQUAY-2344) (#1866)
* add auditing of login and logout events

Signed-off-by: dmesser <dmesser@redhat.com>

* python black formatting

Signed-off-by: dmesser <dmesser@redhat.com>

* correctly identify username during

Signed-off-by: dmesser <dmesser@redhat.com>

* revert change to existing code

Signed-off-by: dmesser <dmesser@redhat.com>

* remove superfluous ip tracking

Signed-off-by: dmesser <dmesser@redhat.com>

* beautify login messages

Signed-off-by: dmesser <dmesser@redhat.com>

* remove unused import

Signed-off-by: dmesser <dmesser@redhat.com>

* move alembic patch to head

Signed-off-by: dmesser <dmesser@redhat.com>

* correctly log target namespace for robots

Signed-off-by: dmesser <dmesser@redhat.com>

* python black formatting

Signed-off-by: dmesser <dmesser@redhat.com>

* login event detection refinement

Signed-off-by: dmesser <dmesser@redhat.com>

* add missing visualization

Signed-off-by: dmesser <dmesser@redhat.com>

* enrich login event data

Signed-off-by: dmesser <dmesser@redhat.com>

* make login auditing configurable

Signed-off-by: dmesser <dmesser@redhat.com>

* make update-testdata

Signed-off-by: dmesser <dmesser@redhat.com>

---------

Signed-off-by: dmesser <dmesser@redhat.com>
2023-05-17 11:22:35 +02:00
Oleg Bulatov
d49dbd1515 chore: Update db data for UI tests (#1874) 2023-05-10 21:48:28 +02:00
Oleg Bulatov
80602e0421 chore: Fix UI tests (PROJQUAY-5424) (#1858) 2023-05-05 17:52:27 +02:00
Syed Ahmed
0e3221e4f3 ui: Merge quay-ui into quay (PROJQUAY-5315) (#1827)
* ui: Merge quay-ui into quay (PROJQUAY-5315)

Merging the new patternfly UI into the monorepo quay.
Any future changes will need to be opened on the quay repo
2023-04-18 10:00:10 -04:00
Dave O'Connor
f1d8558815 Add quay-ui (#1683)
Signed-off-by: Dave O'Connor <1656866+HammerMeetNail@users.noreply.github.com>
2022-12-20 08:38:16 -05:00