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

10209 Commits

Author SHA1 Message Date
Joseph Schorr
d59cdafdde Stop relying on GitHub's admin permissions for a repository (#285)
It appears GitHub has narrowed the permissions returned, so while we
might still have the ability to admin the *repo*, the permissions
list is returning `false`, so we disallow people to create triggers,
which is wrong.

Fixes https://issues.redhat.com/browse/PROJQUAY-523
2020-03-26 14:08:10 -04:00
Joseph Schorr
258a7dc199 Make sure we don't send zero value metrics to Prometheus in verbs (#284)
The `inc` function rejects these with an exception

Fixes https://issues.redhat.com/browse/PROJQUAY-456
2020-03-26 11:44:20 -04:00
Joseph Schorr
f245d21637 Remove the old registry test suite (#282) 2020-03-25 16:01:02 -04:00
Joseph Schorr
59bc23313c Add additional detection for transitive deletes and fix those found (#281)
We were not testing for transitive deletes when performing *User*
deletion, which led us to have a few
2020-03-25 15:58:12 -04:00
Joseph Schorr
3d2aadf91c Update the manifest builder for V1 API to not construct Image rows (#280)
Instead, we now simply save all the Image information into the
in-memory session and then construct the manifest directly at the end.

Fixes https://issues.redhat.com/browse/PROJQUAY-513
2020-03-25 15:05:17 -04:00
Joseph Schorr
ac16395dfb Fix status response codes to conform to the OCI spec (#277)
Fixes https://issues.redhat.com/browse/PROJQUAY-509
2020-03-24 12:57:03 -04:00
Joseph Schorr
dce80ab26d Fix support for empty manifests in V2_2 (#278)
Fixes https://issues.redhat.com/browse/PROJQUAY-510
2020-03-24 11:26:08 -04:00
Joseph Schorr
49862a9eda Move shared image modules into a shared package in prep for adding OCI (#271) 2020-03-20 12:33:43 -04:00
Kurtis Mullins
35bc75d704 [PROJQUAY-461] Install uploaded certs in config-app for TLS validation. (#276) 2020-03-20 12:19:59 -04:00
Joseph Schorr
79ca6f28cf Remove the shared registry model impl now that we have a single (#275)
registry model
2020-03-19 16:57:43 -04:00
Joseph Schorr
8701577cff Have the RepositoryActionCount worker cleanup old rows in RAC (#274)
We don't make use of any action counts older than a year, so this
change will have the worker remove old rows, one month (roughly) at
a time
2020-03-18 17:00:14 -04:00
Alec Merdler
7b827d953c add new 'ManifestSecurityStatus' database model for Clair v4 (#216) 2020-03-17 15:31:15 -07:00
Joseph Schorr
a32a1d58d9 Small changes missing from the previous cleanup PR (#270) 2020-03-17 16:40:57 -04:00
Joseph Schorr
f2c561fab2 Add additional details to the NameInvalid error raised on mismatches (#269)
in V2_1 schema manifests
2020-03-17 13:52:12 -04:00
Joseph Schorr
0844256a71 Major post-OCI cleanup (#225)
* Remove V3_UPGRADE_MODE

* Remove tag backfill worker and all callers to tag backfill and upgrades

* Change initdb to create all test data via the manifest builder, rather than manually via legacy images

* Convert various code paths to use the registry_model where we previously did not do so

* Convert the GC test suite to build via the manifest builder

* Delete an old, unused tool

* Delete the Pre OCI registry model

* Add additional error handling to the manifest creation code path

* Add additional error handling to the OCI tag creation code path

* Change how we respond to invalid manifest content types to better handle unknowns

* Change legacy secscan test suite to use the registry model

* Change the repo build badge to use the registry model (also fixes a bug)

* Delete now-unused data model code

* Remove old model adjustment code from OCI model

* Mark older data models as deprecated which will prevent new rows from being inserted

* Remove references to old registry test suite from various testing files

* Remove tag backfill worker (again; got re-added during rebase)

* Move all deprecated model checks into a central function

* Make data_migration more Pythonic

* Small requested fixes to Tag module styling

* Have tag backfill worker fail to migrate if there are TagManifest's

Since this backfill should only be called in future releases for empty models, this should catch someone attempting to upgrade from a too-old version

* Remove labelbackfillworker as it is no longer needed

* Remove unused invalid import

* Reimplement the tag test for the remaining method used
2020-03-17 13:27:29 -04:00
Bill Dettelback
f9b5ae871c initial version (#265) 2020-03-17 11:45:18 -04:00
Joseph Schorr
5619452776 Add ability to filter user lookups in LDAP user system (#252)
This allows customers to specify additional restrictions on the users
that are allowed to be used

Fixes https://issues.redhat.com/browse/PROJQUAY-226
2020-03-16 11:38:14 -04:00
Joseph Schorr
00a01bb4a6 Don't raise an exception when mirroring username/password cannot be (#253)
decrypted

From the UI perspective, we simply replace the username with text
indicating it is invalid.

For the worker, we already raise an exception and mark the mirroring
as invalid, so add a `logger.exception` so we have additional debug
information.

Fixes https://issues.redhat.com/browse/PROJQUAY-238
2020-03-16 11:37:51 -04:00
dependabot[bot]
bc124f8532 Bump psutil from 5.6.3 to 5.6.6 (#266)
Bumps [psutil](https://github.com/giampaolo/psutil) from 5.6.3 to 5.6.6.
- [Release notes](https://github.com/giampaolo/psutil/releases)
- [Changelog](https://github.com/giampaolo/psutil/blob/master/HISTORY.rst)
- [Commits](https://github.com/giampaolo/psutil/compare/release-5.6.3...release-5.6.6)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-03-13 14:15:23 -04:00
Joseph Schorr
7b8d96a250 Ensure that temporary tags cannot be written for repositories marked (#258)
for deletion

The purge code assumes that once it has deleted tags, no new ones will
be added, so we need to enforce that state
2020-03-12 15:41:54 -04:00
Joseph Schorr
08f97dc162 Mark any server hostnames with quay.io as reserved (#263)
Usage of `quay.io` in a server hostname breaks the superuser API
(on purpose) to ensure that API is never available in production.

This change ensures this is messaged properly.

Fixes https://issues.redhat.com/browse/PROJQUAY-80
2020-03-12 12:48:56 -04:00
Henry Donnay
2735d348ac quay-entrypoint.sh: fix openssl commandline (#264)
Turns out `--` isn't in the openssl in rhel7.

This is my bad to begin with, as this argument terminator isn't
documented even on versions where it works.

Signed-off-by: Hank Donnay <hdonnay@redhat.com>
2020-03-12 12:18:26 -04:00
Jake Moshenko
7f56b221e8 Gen migrations (#240)
* Move truthy_bool to a neutral location.

* Add dba operator migration version generation code.
Change existing migrations to use an injected and wrapped op.

* Generate databasemigration hints files for all existing migrations.

* Reformat with black.
2020-03-11 13:54:08 -04:00
Kurtis Mullins
5fd7ebbc97 [PROJQUAY-160] Remove TOS and Privacy pages (#262) 2020-03-11 13:23:44 -04:00
Joseph Schorr
04cf7cc2c3 Catch infinite loops in GC purge code and raise an exception instead (#257)
If we have a bug that causes the GC's assumptions to be wrong (such
as an Image added after a purge began), then the purge loop can enter a
state where it will never halt. This change detects that condition and
raises an exception so we can properly investigate the bug.

Fixes https://issues.redhat.com/browse/PROJQUAY-452
2020-03-10 17:30:12 -04:00
Joseph Schorr
44b4063ec9 Small fixes for external login buttons (#260)
1) Display up to three per row, rather than two
2) Fix the display of external images to allow for local references
2020-03-10 16:19:57 -04:00
Alec Merdler
0879c81e95 correct baselines for Red Hat Quay.io logo (#256) 2020-03-10 11:34:06 -04:00
thomasmckay
2ad6ddbf33 PROJQUAY-222 - mirror trim tag whitespace (#250) mustafar 2020-03-09 11:43:09 -04:00
Joseph Schorr
5b50258897 Change the lookup of active orgs to skip the unnecessary heavy filter (#249) 2020-03-04 16:50:17 -05:00
Joseph Schorr
45e6573401 Small worker fixes (#248)
* Fix a copy-paste error within the global prom stats worker

Also adds a test

* Fix queueitem deletion metric reporting
2020-03-04 16:28:10 -05:00
Henry Donnay
f89b946cea quay-entypoint.sh: fix config argument handling (#231)
This commit properly makes the `openssl` invocation correct for passwords starting with `-`and simplifies the code.
2020-03-04 15:49:29 -05:00
Henry Donnay
091bbe3e89 quay-entrypoint.sh: don't use scl shells (#233)
This commit makes the entrypoint absorb the scl env so that `exec` does
what's expected and signals are propagated properly.
2020-03-03 12:47:10 -05:00
Alec Merdler
1349a4ccfc Revert "Update Frontend Dependencies (#237)" (#244)
This reverts commit 1c6edb4b10.
2020-03-02 14:39:00 -08:00
Kurtis Mullins
dadc0df793 Use Redhat Terms & Privacy links in Footer (#242) 2020-03-02 14:48:45 -05:00
Alec Merdler
1c6edb4b10 Update Frontend Dependencies (#237)
* update AngularJS to 1.7.9

* update jQuery to 1.12.4

* update Bootstrap to 4.4.1
2020-02-28 11:05:01 -08:00
Kurtis Mullins
82d1a0d160 [PROJQUAY-329] Only allow lowercase characters in repository names. (#235) 2020-02-28 10:02:52 -05:00
Joseph Schorr
424c1a19d7 Have the BlobUpload cleanup worker run on a single instance only (#239)
Instead of running simultaneously across multiple nodes, we change the
worker to run only from a single instance. This is better for the DB and
the previous behavior was not necessary given the size of the BlobUpload
table.

Fixes https://issues.redhat.com/browse/PROJQUAY-365
2020-02-27 13:16:40 -05:00
Joseph Schorr
1b023b8c2f Fix performance of the global prom stats worker queries (#238)
- Change the counts to use the MySQL information schema for estimates
- Change the lookup of active users to skip the unnecessary heavy filter
2020-02-27 13:16:35 -05:00
Ivan Bazulic
c4786cb10a Updated NodeJS version from 8 to 12 in Dockerfile.rhel7 (#234) 2020-02-26 10:05:56 -05:00
Alec Merdler
d4e5dd8854 Merge pull request #236 from alecmerdler/fix-local-config-app
Fix Local Config App Script
2020-02-24 10:48:07 -08:00
alecmerdler
0821f2f70e fix local-config-app.sh script 2020-02-21 16:50:55 -08:00
Joseph Schorr
5281111147 Merge pull request #232 from josephschorr/joseph.schorr/PROJQUAY-268/github-params
Change GitHub calls to pass client_id and secret in the Auth header
2020-02-20 15:04:50 -05:00
Joseph Schorr
d0f2deb6db Merge pull request #227 from josephschorr/joseph.schorr/PROJQUAY-220/tag-history-future
Hide all future tag expirations in the timeline, by default
2020-02-19 14:49:43 -05:00
Joseph Schorr
4a6cacb06d Change GitHub calls to pass client_id and secret in the Auth header
This is a required change, as GitHub is deprecating the query parameters in a few months. See https://developer.github.com/changes/2020-02-10-deprecating-auth-through-query-param/ for details.

Fixes https://issues.redhat.com/browse/PROJQUAY-268
2020-02-19 13:21:39 -05:00
Joseph Schorr
5be95a9b7d Merge pull request #230 from josephschorr/joseph.schorr/PROJQUAY-268/upgrade-github-lib
Upgrade the version of the GitHub library we use in prep for change how we Auth to github
2020-02-19 13:10:09 -05:00
thomasmckay
37f42d1e4b Merge pull request #28 from sghosh151/master
PROJQUAY-17 - Update build.sh to support buildah or podman
2020-02-19 06:58:23 -05:00
Jimmy Zelinskie
3b98f939b8 Merge pull request #224 from jzelinskie/route-buckets
prometheus: default histogram buckets
2020-02-18 11:32:05 -05:00
Jimmy Zelinskie
323eeb7f73 Merge pull request #229 from jzelinskie/verb-blueprint-metrics
verbs: time blueprint
2020-02-18 11:31:25 -05:00
Joseph Schorr
4c74f8f974 Upgrade the version of the GitHub library we use in prep for change how we Auth to github 2020-02-17 15:54:29 -05:00
Joseph Schorr
7f2cf26ee0 Merge pull request #221 from josephschorr/fix-v2-labels
The incremented counters are for v2 as a whole
2020-02-17 15:22:59 -05:00