Summary
The prepare: artifact plugin aggregates artifacts into a single shared repository whose name is currently hardcoded. There is no way for a user to override it. This should be configurable so integrators can pick a name that fits their environment.
Current behavior
The shared aggregation repository name is fixed to tmt-artifact-shared:
- Defined in
tmt/steps/prepare/artifact/providers/__init__.py:31 (SHARED_REPO_NAME)
- Passed to
create_repository() in tmt/steps/prepare/artifact/__init__.py:235
The plugin schema (tmt/schemas/prepare/artifact.yaml) exposes only how, provide, default-repository-priority and verify — no option for the repository name.
The underlying create_repository() helper already accepts a repo_name argument (tmt/steps/prepare/artifact/providers/repository.py:114), so the plumbing exists; it is just not surfaced as a user-facing option.
Motivation
Downstream users rely on a stable, known repository name. For example, Testing Farm needs to keep the test-artifacts repository name to avoid breaking existing users who reference it. With the name hardcoded to tmt-artifact-shared, those workflows cannot migrate to the artifact plugin without breaking.
Proposed change
Add an option to the prepare: artifact plugin to set the shared aggregation repository name, for example:
prepare:
how: artifact
provide:
- koji:<build-id>
repository-name: test-artifacts
When unset, the current default (tmt-artifact-shared) is kept for backward compatibility.
Implementation would involve:
- Adding the option to
tmt/schemas/prepare/artifact.yaml
- Adding the corresponding field to the plugin data class
- Threading the value into the
create_repository(..., repo_name=...) call in place of the hardcoded SHARED_REPO_NAME
Summary
The
prepare: artifactplugin aggregates artifacts into a single shared repository whose name is currently hardcoded. There is no way for a user to override it. This should be configurable so integrators can pick a name that fits their environment.Current behavior
The shared aggregation repository name is fixed to
tmt-artifact-shared:tmt/steps/prepare/artifact/providers/__init__.py:31(SHARED_REPO_NAME)create_repository()intmt/steps/prepare/artifact/__init__.py:235The plugin schema (
tmt/schemas/prepare/artifact.yaml) exposes onlyhow,provide,default-repository-priorityandverify— no option for the repository name.The underlying
create_repository()helper already accepts arepo_nameargument (tmt/steps/prepare/artifact/providers/repository.py:114), so the plumbing exists; it is just not surfaced as a user-facing option.Motivation
Downstream users rely on a stable, known repository name. For example, Testing Farm needs to keep the
test-artifactsrepository name to avoid breaking existing users who reference it. With the name hardcoded totmt-artifact-shared, those workflows cannot migrate to theartifactplugin without breaking.Proposed change
Add an option to the
prepare: artifactplugin to set the shared aggregation repository name, for example:When unset, the current default (
tmt-artifact-shared) is kept for backward compatibility.Implementation would involve:
tmt/schemas/prepare/artifact.yamlcreate_repository(..., repo_name=...)call in place of the hardcodedSHARED_REPO_NAME