Include referrers data for container repository tags query
What does this MR do and why?
On the Project
-> Settings
-> Deploy
-> Container Registry
page, we show a list of Docker container tags:
![]() |
Each tag can be signed with a signature. We recently added the ability to fetch signatures in the GraphQL query. This MR actually does the fetching by sending a referrers: true
variable to the GraphQL query. Note that this MR only fetches the signatures but doesn't use it; a follow-up MR will show them in the UI.
How to set up and validate locally
It's extremely involved to set up a local environment that can create the signatures and return it in the GraphQL data. You can see what the production data looks like by running this query (source project):
GraphQL query
query {
containerRepository(id:"gid://gitlab/ContainerRepository/6340028") {
manifest(reference: "sha256:ce9645c76a4695781d93febc2c259fe70b29c7d3bc9ad3750337e783ba1029da")
tags(first: 100, referrers: true) {
nodes {
digest
name
referrers {
artifactType
digest
}
}
}
}
}
But locally, we will just verify that the GraphQL query is sending the referrers
variable for the query rather than checking the response.
- On your local machine, you must set up Docker and a local GitLab runner using the docker executor.
- Stop your local GDK.
- Edit your
config/gitlab.yml
file. Find the top-levelregistry:
key and changeenabled: false
toenabled: true
:
registry:
enabled: true
- Start your local GDK. Verify that the last line of output says
A container registry is available at 127.0.0.1:5000.
- Clone this project locally: https://gitlab.com/bwill/container-signing/
- Check if the
Settings
->Deploy
->Container Registry
nav item is shown. If not, try restarting your GDK. This happens because the image is still starting up and is not ready by the time GDK has started. The registry stays running between GDK restarts. - Run a pipeline against the master branch.
- Go to
Settings
->Deploy
->Container Registry
. There should be one registry shown. Click on it. - A list of tags should be shown. Open
DevTools
and on the Network tab, verify that thegetContainerRepositoryTags
request is sendingreferrers: false
:
![]() |
- Enable the
:show_container_registry_tag_signatures
feature flag. - Refresh the tags list page. Verify that the
getContainerRepositoryTags
request is sendingreferrers: true
this time.
Related to #442848
Merge request reports
Activity
changed milestone to %17.0
assigned to @dftian
added 1 commit
- 7740d6b8 - Include referrers data for container repository tags query
- A deleted user
added backend feature flag labels
2 Warnings d7c49377: Commits that change 30 or more lines across at least 3 files should describe these changes in the commit body. For more information, take a look at our Commit message guidelines. The master pipeline status page reported failures in If these jobs fail in your merge request with the same errors, then they are not caused by your changes.
Please check for any on-going incidents in the incident issue tracker or in the#master-broken
Slack channel.1 Message CHANGELOG missing: If this merge request needs a changelog entry, add the
Changelog
trailer to the commit message you want to add to the changelog.If this merge request doesn't need a CHANGELOG entry, feel free to ignore this message.
Multiversion compatibility
This merge request updates GraphQL backend and frontend code.
To prevent an incident, ensure the updated frontend code is backwards compatible.
For more information, see the multiversion compatibility documentation.
Reviewer roulette
Category Reviewer Maintainer backend @syarynovskyi
(UTC+3, 13 hours ahead of author)
@mcelicalderonG
(UTC-5, 5 hours ahead of author)
frontend @syarynovskyi
(UTC+3, 13 hours ahead of author)
@justin_ho
(UTC+7, 17 hours ahead of author)
Please check reviewer's status!
Please refer to documentation page for guidance on how you can benefit from the Reviewer Roulette, or use the GitLab Review Workload Dashboard to find other available reviewers.
If needed, you can retry the
danger-review
job that generated this comment.Generated by
DangerBundle size analysis [beta]
This compares changes in bundle size for entry points between the commits 586e8ef4 and 76f15ec7
Special assetsEntrypoint / Name Size before Size after Diff Diff in percent average 4.3 MB 4.3 MB - 0.0 % mainChunk 3.3 MB 3.3 MB - 0.0 %
Note: We do not have exact data for 586e8ef4. So we have used data from: 8e7466ca.
The intended commit has no webpack pipeline, so we chose the last commit with one before it.Please look at the full report for more details
Read more about how this report works.
Generated by
Danger- Resolved by Mario Celi
- Resolved by Dzmitry (Dima) Meshcharakou
- Resolved by Mario Celi
- Resolved by Mario Celi
- Resolved by Mario Celi
- Resolved by Mario Celi
- Resolved by Mario Celi
@ahuntsman Would you be able to do the initial backend review for this one?
In particular, I'm concerned about this discrepancy between what production returns and what the test returns for manifest data. Since you're likely the only person who has the signature-aware container registry working locally, I was wondering if you could check to see what data is returned locally (JSON or serialized Ruby object?).
- Resolved by Mario Celi
@lorenzvanherwaarden Would you be able to do the initial frontend review for this one?
I pikachu choosed you because I know your environment's already set up with a GitLab runner with a Docker executor, which is needed for the local repro steps .Edited by Daniel Tian
requested review from @ahuntsman and @lorenzvanherwaarden
- Resolved by Mario Celi
- Resolved by Mario Celi
added pipeline:mr-approved label
- Resolved by Mario Celi
@lorenzvanherwaarden
, thanks for approving this merge request.This is the first time the merge request has been approved. To ensure we don't only run predictive pipelines, and we don't break
master
, a new pipeline will be started shortly.Please wait for the pipeline to start before resolving this discussion and set auto-merge for the new pipeline. See merging a merge request for more details.
E2E Test Result Summary
allure-report-publisher
generated test report!e2e-test-on-gdk:
test report for 76f15ec7expand test summary
+------------------------------------------------------------------+ | suites summary | +-------------+--------+--------+---------+-------+-------+--------+ | | passed | failed | skipped | flaky | total | result | +-------------+--------+--------+---------+-------+-------+--------+ | Package | 19 | 0 | 12 | 19 | 31 | ✅ | | Create | 101 | 0 | 9 | 94 | 110 | ✅ | | Plan | 51 | 0 | 2 | 47 | 53 | ✅ | | Monitor | 7 | 0 | 0 | 7 | 7 | ✅ | | Verify | 31 | 0 | 1 | 30 | 32 | ✅ | | Govern | 66 | 0 | 0 | 43 | 66 | ✅ | | Data Stores | 31 | 0 | 0 | 22 | 31 | ✅ | | Analytics | 2 | 0 | 0 | 1 | 2 | ✅ | | Release | 5 | 0 | 0 | 5 | 5 | ✅ | | Manage | 0 | 0 | 1 | 0 | 1 | ➖ | +-------------+--------+--------+---------+-------+-------+--------+ | Total | 313 | 0 | 25 | 268 | 338 | ✅ | +-------------+--------+--------+---------+-------+-------+--------+
e2e-package-and-test:
test report for 76f15ec7expand test summary
+------------------------------------------------------------------+ | suites summary | +-------------+--------+--------+---------+-------+-------+--------+ | | passed | failed | skipped | flaky | total | result | +-------------+--------+--------+---------+-------+-------+--------+ | Package | 176 | 0 | 80 | 1 | 256 | ✅ | | Create | 183 | 0 | 20 | 0 | 203 | ✅ | | Plan | 44 | 0 | 4 | 0 | 48 | ✅ | | Verify | 10 | 0 | 0 | 0 | 10 | ✅ | | Data Stores | 22 | 0 | 0 | 0 | 22 | ✅ | | Govern | 28 | 0 | 0 | 0 | 28 | ✅ | | Monitor | 8 | 0 | 0 | 0 | 8 | ✅ | | Release | 2 | 0 | 0 | 0 | 2 | ✅ | +-------------+--------+--------+---------+-------+-------+--------+ | Total | 473 | 0 | 104 | 1 | 577 | ✅ | +-------------+--------+--------+---------+-------+-------+--------+
requested review from @xanf
requested review from @mcelicalderonG
removed review request for @xanf
- Resolved by Mario Celi
added pipeline:skip-undercoverage label
removed pipeline:skip-undercoverage label
added 927 commits
-
37609c97...848e437e - 924 commits from branch
master
- d7c49377 - Include referrers data for container repository tags query
- 65c39ba4 - Fix JSON serialization
- 76f15ec7 - Add rollout issue
Toggle commit list-
37609c97...848e437e - 924 commits from branch
reset approvals from @xanf, @ahuntsman, and @lorenzvanherwaarden by pushing to the branch
added pipeline:skip-undercoverage label
removed pipeline:mr-approved label
added pipeline:mr-approved label
enabled an automatic merge when all merge checks for 76f15ec7 pass
mentioned in commit 619b74ce
added workflowstaging-canary label
added workflowcanary label and removed workflowstaging-canary label
added workflowstaging label and removed workflowcanary label
added workflowproduction label and removed workflowstaging label
added workflowpost-deploy-db-production label and removed workflowproduction label
added releasedcandidate label
mentioned in issue #460226 (closed)
mentioned in issue #461391
mentioned in issue #423814 (closed)
added releasedpublished label and removed releasedcandidate label
added pipelinetier-3 label
mentioned in issue gitlab-org/quality/triage-reports#20598 (closed)
mentioned in issue gitlab-org/quality/triage-reports#20975 (closed)
mentioned in issue gitlab-org/quality/triage-reports#21563 (closed)
mentioned in issue gitlab-org/quality/triage-reports#22055