Allow skipping the redundant Pulp CLI publish after RPM uploads
What does this MR do?
Allow uploading RPM packages to Pulp with pulp rpm content upload --no-publish, when the CI/CD variable PULP_CLI_PUBLISH is false.
The Pulp RPM repositories have autopublish enabled: create_rpm_repo in pulp-resources-automation creates every RPM repository with autopublish: true and sets it back if it changes. So Pulp already publishes the repository inside the upload task. The pulp CLI then started a second, redundant publish of the full repository. During the 18.11.13 and 19.0.10 releases, 27 of the 32 publishes on gitlab-pre-release-el-8-x86_64 came from the CLI (207 of 246 worker minutes). They caused most of the repository lock contention that made the staging upload jobs time out.
- By default (
PULP_CLI_PUBLISHunset ortrue), the CLI publishes after each upload as before. SetPULP_CLI_PUBLISH=falseon dev.gitlab.org to turn on--no-publish. - Deb uploads do not change.
pulp deb content uploadhas no publish option. - The behavior was tested on the Pulp pre environment: with
autopublish: true, a--no-publishupload is still published, and no separate publish task runs. Withautopublish: false, the package is not published. Test and results: gitlab-com/gl-infra/delivery#22494 (comment 4058773453)
Related issues
Related to gitlab-com/gl-infra/delivery#22495 (closed)
Checklist
See Definition of done.
For anything in this list which will not be completed, please provide a reason in the MR discussion.
Required
- MR title and description are up to date, accurate, and descriptive.
- MR targeting the appropriate branch.
- Latest Merge Result pipeline is green.
- When ready for review, MR is marked as ready (not a draft) and a reviewer is requested. Pick the reviewer suggested by the reviewer roulette, or one of the project maintainers.
- The UBT version and corresponding checksum hash have been updated and referenced in the merge request if applicable.
- UBT EE pipeline (
Trigger:ee-package-ubt) is green
- UBT EE pipeline (
For GitLab team members
If you don't have access to this, the reviewer should trigger these jobs for you during the review process.
- The manual
Trigger:ee-packagejobs have a green pipeline running against latest commit.- To debug QA failures, refer to the Investigate QA failures section.
- If
config/softwareorconfig/patchesdirectories are changed, make sure thebuild-package-on-all-osjob within theTrigger:ee-packagedownstream pipeline succeeded. - If you are changing anything SSL related, then the
Trigger:package:fipsmanual job within theTrigger:ee-packagedownstream pipeline must succeed. - If CI configuration is changed, the branch must be pushed to
dev.gitlab.orgto confirm regular branch builds aren't broken.
Expected (please provide an explanation if not completing)
- Test plan indicating conditions for success has been posted and passes. Tested on the Pulp pre environment: gitlab-com/gl-infra/delivery#22494 (comment 4058773453)
- Documentation created/updated. Added the
PULP_*variables todoc/development/ci-variables.md. - Tests added.
- Integration tests added to GitLab QA.
- Equivalent MR/issue for the GitLab Chart opened.
- Validate potential values for new configuration settings. Formats such as integer
10, duration10s, URIscheme://user:passwd@host:portmay require quotation or other special handling when rendered in a template and written to a configuration file.
Reviewer checklist
- As soon as you begin reviewing, select Start a review on your first comment so the MR shows Reviewer started review.