curl -X GET \ "https://copr.fedorainfracloud.org/api_3/mock-chroots/list"
Get list of all currently active mock chroots with additional comments.This endpoint returns available build targets (chroots) that can be used when creating or configuring Copr projects.
import requestsresponse = requests.get('https://copr.fedorainfracloud.org/api_3/mock-chroots/list')chroots = response.json()# Filter for Fedora 40 chrootsfedora_40 = {k: v for k, v in chroots.items() if k.startswith('fedora-40-')}print(fedora_40)# {'fedora-40-x86_64': '', 'fedora-40-aarch64': ''}
The list of available chroots changes over time as new distributions are released and old ones reach end-of-life. Always fetch the current list rather than hardcoding chroot names.