Nicer PDC status.

This commit is contained in:
Adam Saleh 2021-05-05 10:58:47 +02:00
parent f03df1e5f6
commit 9f2ae7d7ac
3 changed files with 270 additions and 12 deletions

219
docs/pdc/endpoints.rst Normal file
View file

@ -0,0 +1,219 @@
Endpoints
=========
Based on the users we identified, we have identified the endpoints our scripts and services are actually using.
/rest_api/v1/global-components/?name={{name}}
-----------------------
::
{
"dist_git_path": null, # dont use these
"dist_git_web_url": "https://src.fedoraproject.org/cgit/rpms/gnupg2.git", # generated from name
"id": 20,
"labels": [], # we don't use these
"name": "gnupg2",
"upstream": null # we don't use this
}
/rest_api/v1/component-branches/
--------------------
::
{
"active": true, # I don't know where do we store this?
"critical_path": false,
"global_component": "0ad",
"id": 501964,
"name": "f34",
"slas": [
{
"eol": "2022-03-08",
"id": 1003101,
"sla": "security_fixes"
},
{
"eol": "2022-03-08",
"id": 1003102,
"sla": "bug_fixes"
}
],
"type": "rpm" # | rpm | container | zip | iso | composite | module | flatpak
}
rest_api/v1/component-branch-slas/
----------------------
Couldn't find the shape without authenticating
rest_api/v1/compose-images/
---------------
stores `composeinfo.json` and `image-manifest.json`
gives ability to retrieve list of images in specified compose
::
{
"header": {
"type": "productmd.images",
"version": "1.2"
},
"payload": {
"compose": {
"date": "20160416",
"id": "Fedora-Rawhide-20160416.n.0",
"respin": 0,
"type": "nightly"
},
"images": {
"Workstation": {
"x86_64": [
{
"arch": "x86_64",
"bootable": true,
"checksums": {
"sha256": "a7cbd69cc5c96dbf0e0f39d29b09c27844af677a602f512672527a5f7a91000c"
},
"disc_count": 1,
"disc_number": 1,
"format": "iso",
"implant_md5": "ea67ef79f3374d91735008148de4146e",
"mtime": 1460789082,
"path": "Workstation/x86_64/iso/Fedora-Workstation-netinst-x86_64-Rawhide-20160416.n.0.iso",
"size": 426770432,
"subvariant": "Workstation",
"type": "boot",
"volume_id": "Fedora-WS-dvd-x86_64-rawh"
}
]
}
}
}
}
rest_api/v1/compose-images/
-----------------------
::
{
"active": false,
"allow_buildroot_push": false,
"allowed_debuginfo_services": [],
"allowed_push_targets": [],
"base_product": null,
"bugzilla": null,
"compose_set": [],
"dist_git": {
"branch": "f25"
},
"integrated_with": null,
"name": "Fedora Updates",
"product_version": "fedora-25",
"release_id": "fedora-25-updates",
"release_type": "updates",
"short": "fedora",
"sigkey": null,
"version": "25"
},
rest_api/v1/rpms
---------------
::
{
"count": 12473109,
"next": "https://pdc.fedoraproject.org/rest_api/v1/rpms/?page=2",
"previous": null,
"results": [
{
"arch": "x86_64",
"built_for_release": null,
"dependencies": {
"conflicts": [],
"obsoletes": [],
"provides": [],
"recommends": [],
"requires": [],
"suggests": []
},
"epoch": 0,
"filename": "readline-6.3-7.fc24.x86_64.rpm",
"id": 20,
"linked_composes": [
"Fedora-24-20160202.n.0",
"Fedora-24-20160203.n.0",
"Fedora-24-20160203.n.1",
"Fedora-24-20160204.n.0"
],
"linked_releases": [],
"name": "readline",
"release": "7.fc24",
"srpm_commit_branch": null,
"srpm_commit_hash": null,
"srpm_name": "readline",
"srpm_nevra": "readline-0:6.3-7.fc24.src",
"version": "6.3"
} ] }
rest_api/v1/releases
--------------------
::
{
"active": false,
"allow_buildroot_push": false,
"allowed_debuginfo_services": [],
"allowed_push_targets": [],
"base_product": null,
"bugzilla": null,
"compose_set": [],
"dist_git": null,
"integrated_with": null,
"name": "Fedora Updates",
"product_version": "fedora-26",
"release_id": "fedora-26-updates",
"release_type": "updates",
"short": "fedora",
"sigkey": null,
"version": "26"
}
product-versions
----------------
::
{
"active": true,
"allowed_push_targets": [],
"name": "fedora 34",
"product": "fedora",
"product_version_id": "fedora-34",
"releases": [
"fedora-34"
],
"short": "fedora",
"version": "34"
},
{
"active": true,
"allowed_push_targets": [],
"name": "fedora rawhide",
"product": "fedora",
"product_version_id": "fedora-rawhide",
"releases": [
"fedora-Rawhide",
"fedora-modular-Rawhide"
],
"short": "fedora",
"version": "rawhide"
}

View file

@ -11,6 +11,15 @@ It uses https://github.com/product-definition-center/product-definition-center/t
The software is orphaned by it's original maintainers with version requiring EOL version of python and EOL version of Django Framework,
this means we need to upgrade it or replace it.
Abstract take-away
------------------
Current approach we agree on:
- there is no silver bullet, it will require development effort
- responsibility for retirement and sla's of packages could be moved to pagure-dist_git
- responsibility for critical-path and releases can be moved to Bodhi
- nightly compose metadata requires new application, that would be much simpler than current PDC
Previous work
-------------
@ -92,4 +101,11 @@ it turned out we would need to maintain a separate service that would serve as a
- https://postgrest.org/en/stable/auth.html
- https://samkhawase.com/blog/postgrest/postgrest_auth0_service/
This speaks against using Postgrest.
This speaks against using Postgrest.
.. toctree::
:maxdepth: 1
users
endpoints

View file

@ -101,19 +101,42 @@ fedscm_admin/pdc.py
- new_branch
- get_sla
- new_sla_to_branch
- component_type_to_singular
To verify
---------
pagure
------
- /rest_api/v1/component-branches/
- to get retired packages
- pagure
- modulebuildservice ?
- based on ansible roles/mbs/common/files/fedora.json.production
- mirrormanager scripts
modulebuildservice
------------------
- /rest_api/v1/component-branches/
- to get end-of-life packages
- based on ansible roles/mbs/common/files/fedora.json.productbion
mirrormanager scripts
---------------------
- /rest_api/v1/releases/
- checks for currently active releases
- roles/mirrormanager/backend/templates/handle_propagation.sh
- roles/mirrormanager/crawler/files/check_propagation.sh
- ODCS has related stuff
* new hotness has related stuff
* fedora messaging has pdc-related configuration
* osbs client has configuration
ODCS
----
no longer uses pdc
new hotness
-----------
- /rest_api/v1/component-branches/
- to get retired packages
fedora messaging
----------------
- no integrations found
osbs client
-----------
- no integrations found