mirror of
https://github.com/containers/skopeo.git
synced 2025-09-26 20:31:41 +08:00

1. Packit config includes a `get-current-version` action to fetch the version from `version/version.go` and not from the default `git describe`. So, the copr rpm version will always be ahead of what's in the official repos. 2. The absurdly high RPM Epoch is now limited to builds from rhcontainerbot/podman-next copr. So, copr builds on PR jobs will use the default Epoch value. These two changes will make it easier for testers to fetch the scratch copr builds from upstream PRs and it should allow for seamless upgrades. (official rpm -> test copr rpm for bugfix -> upgrade to new official rpm) Signed-off-by: Lokesh Mandvekar <lsm5@redhat.com>
149 lines
4.6 KiB
YAML
149 lines
4.6 KiB
YAML
---
|
|
# See the documentation for more information:
|
|
# https://packit.dev/docs/configuration/
|
|
|
|
# NOTE: The Packit copr_build tasks help to check if every commit builds on
|
|
# supported Fedora and CentOS Stream arches.
|
|
# They do not block the current Cirrus-based workflow.
|
|
|
|
downstream_package_name: skopeo
|
|
upstream_tag_template: v{version}
|
|
|
|
packages:
|
|
skopeo-fedora:
|
|
pkg_tool: fedpkg
|
|
specfile_path: rpm/skopeo.spec
|
|
skopeo-centos:
|
|
pkg_tool: centpkg
|
|
specfile_path: rpm/skopeo.spec
|
|
skopeo-eln:
|
|
specfile_path: rpm/skopeo.spec
|
|
|
|
# https://packit.dev/docs/configuration/actions
|
|
actions:
|
|
get-current-version: bash -c 'grep "^const Version" version/version.go | cut -f2 -d\" | tr \- \~'
|
|
prepare-files: >-
|
|
bash -c "sed -i 's/^\(\s*\)ref: .*/\1ref: \"${PACKIT_PROJECT_TAG}\"/' ${PACKIT_DOWNSTREAM_REPO}/plans/main.fmf"
|
|
|
|
srpm_build_deps:
|
|
- make
|
|
|
|
jobs:
|
|
- job: copr_build
|
|
trigger: pull_request
|
|
packages: [skopeo-fedora]
|
|
notifications: &copr_build_failure_notification
|
|
failure_comment:
|
|
message: "Ephemeral COPR build failed. @containers/packit-build please check."
|
|
targets: &fedora_copr_targets
|
|
- fedora-all-x86_64
|
|
- fedora-all-aarch64
|
|
enable_net: true
|
|
# Re-enable these scans if OpenScanHub starts scanning go packages
|
|
# https://packit.dev/posts/openscanhub-prototype
|
|
osh_diff_scan_after_copr_build: false
|
|
|
|
- job: copr_build
|
|
trigger: pull_request
|
|
packages: [skopeo-eln]
|
|
notifications: *copr_build_failure_notification
|
|
targets: &eln_copr_targets
|
|
fedora-eln-x86_64:
|
|
additional_repos:
|
|
- "https://kojipkgs.fedoraproject.org/repos/eln-build/latest/x86_64/"
|
|
fedora-eln-aarch64:
|
|
additional_repos:
|
|
- "https://kojipkgs.fedoraproject.org/repos/eln-build/latest/aarch64/"
|
|
enable_net: true
|
|
|
|
- job: copr_build
|
|
trigger: pull_request
|
|
packages: [skopeo-centos]
|
|
notifications: *copr_build_failure_notification
|
|
targets: ¢os_copr_targets
|
|
- centos-stream-9-x86_64
|
|
- centos-stream-9-aarch64
|
|
- centos-stream-10-x86_64
|
|
- centos-stream-10-aarch64
|
|
enable_net: true
|
|
|
|
# Run on commit to main branch
|
|
- job: copr_build
|
|
trigger: commit
|
|
packages: [skopeo-fedora]
|
|
notifications:
|
|
failure_comment:
|
|
message: "podman-next COPR build failed. @containers/packit-build please check."
|
|
branch: main
|
|
owner: rhcontainerbot
|
|
project: podman-next
|
|
enable_net: true
|
|
|
|
# Tests on Fedora for main branch
|
|
- job: tests
|
|
trigger: pull_request
|
|
packages: [skopeo-fedora]
|
|
notifications: &test_failure_notification
|
|
failure_comment:
|
|
message: "Tests failed. @containers/packit-build please check."
|
|
targets: *fedora_copr_targets
|
|
tf_extra_params:
|
|
environments:
|
|
- artifacts:
|
|
- type: repository-file
|
|
id: https://copr.fedorainfracloud.org/coprs/rhcontainerbot/podman-next/repo/fedora-$releasever/rhcontainerbot-podman-next-fedora-$releasever.repo
|
|
|
|
# Tests on ELN for main branch
|
|
- job: tests
|
|
trigger: pull_request
|
|
packages: [skopeo-eln]
|
|
notifications: *test_failure_notification
|
|
targets: *eln_copr_targets
|
|
tf_extra_params:
|
|
environments:
|
|
- artifacts:
|
|
- type: repository-file
|
|
id: https://copr.fedorainfracloud.org/coprs/rhcontainerbot/podman-next/repo/fedora-eln/rhcontainerbot-podman-next-fedora-eln.repo
|
|
|
|
# Tests on CentOS Stream for main branch
|
|
- job: tests
|
|
trigger: pull_request
|
|
packages: [skopeo-centos]
|
|
notifications: *test_failure_notification
|
|
targets: *centos_copr_targets
|
|
tf_extra_params:
|
|
environments:
|
|
- artifacts:
|
|
- type: repository-file
|
|
id: https://copr.fedorainfracloud.org/coprs/rhcontainerbot/podman-next/repo/centos-stream-$releasever/rhcontainerbot-podman-next-centos-stream-$releasever.repo
|
|
|
|
# Sync to Fedora
|
|
- job: propose_downstream
|
|
trigger: release
|
|
packages: [skopeo-fedora]
|
|
update_release: false
|
|
dist_git_branches: &fedora_targets
|
|
- fedora-all
|
|
|
|
# Sync to CentOS Stream
|
|
# FIXME: Switch trigger whenever we're ready to update CentOS Stream via
|
|
# Packit
|
|
- job: propose_downstream
|
|
trigger: ignore
|
|
packages: [skopeo-centos]
|
|
update_release: false
|
|
dist_git_branches:
|
|
- c10s
|
|
|
|
# Fedora Koji build
|
|
- job: koji_build
|
|
trigger: commit
|
|
packages: [skopeo-fedora]
|
|
sidetag_group: podman-releases
|
|
# Dependents are not rpm dependencies, but the package whose bodhi update
|
|
# should include this package.
|
|
# Ref: https://packit.dev/docs/fedora-releases-guide/releasing-multiple-packages
|
|
dependents:
|
|
- podman
|
|
dist_git_branches: *fedora_targets
|