Sitemap
Ted James

Ted James

The world is my office, and every destination is my inspiration

Member-only story

gitlab build job upload artifacts ERROR: No files to upload

2 min readApr 10, 2024

I’m dealing with an issue on gitlab pipeline. My build job seems to went well but i’m unable to upload my artifact .rpm to gitlab even with the good path.

.gitlab-ci.yml

build:
stage: build
image: centos
script:
- set -x
- various steps ...
- cd ~
- tree
artifacts:
paths:
- rpmbuild/RPMS/x86_64/*.rpm

error message .

|-- anaconda-ks.cfg
|-- anaconda-post.log
|-- original-ks.cfg
`-- rpmbuild
|-- BUILD
| `-- *****
|-- BUILDROOT
|-- RPMS
| `-- x86_64
| `-- project-0.1-1.el8.x86_64.rpm
|-- SOURCES
| `-- project-0.1.tar.gz
|-- SPECS
`-- SRPMS
`-- project-0.1-1.el8.src.rpm
17 directories, 37 files
Uploading artifacts for successful job 00:00
Uploading artifacts...
WARNING: rpmbuild/RPMS/x86_64/*.rpm: no matching files. Ensure that the artifact path is relative to the working directory (/builds/firstnameName/project)
ERROR: No files to upload
Cleaning up project directory and file based variables

Any advice would be appreciate

What I tryed :

  • debug in gitlab-ci job build
  • various ways to trigger the .rpm
  • $CI_PROJECT_DIR
  • /project-*.rpm
  • *.rpm

Solution

--

--

Ted James
Ted James

Written by Ted James

The world is my office, and every destination is my inspiration