Apt mirror for gitlab-runner in packages.gitlab.com - Sonatype Nexus Repository - Sonatype Community

Apt mirror for gitlab-runner in packages.gitlab.com

post by rol.N on Jul 7, 2025

Hi,

I want to create an apt proxy for gitlab-runner to be available for our ubuntu hosts.

I have created a repo “apt-proxy-noble-gitlab” connected to packages.gitlab.com for ubuntu noble

`https://packages.gitlab.com/runner/gitlab-runner/ubuntu/\`

and downloaded the gitlab.com gpg key to the test machine to /etc/apt/keyrings/ and set it via signed-by option in the apt sources file I created for the gitlab repo.

`deb [signed-by=/etc/apt/keyrings/gitlab.gpg] https://URL-to-my.repo.url/repository/apt-proxy-noble-gitlab/ubuntu noble main
deb-src [signed-by=/etc/apt/keyrings/gitlab.gpg] https://URL-to-my.repo.url/repository/apt-proxy-noble-gitlab/ubuntu noble main`

When I run “apt update” on my test host all the entries for gitlab are Ignored and this message comes up:

`Failed to fetch https://URL-to-my-repo.url/repository/apt-proxy-noble-gitlab/ubuntu/dists/noble/main/source/Sources 404 Not Found [IP: IP-OF-MY-REPO 443]`

Unfortunately there is no logging about any sync jobs when I try to apt update on the test machine.

Any tips?

thx in advance

br

Roland

post by mpiggott on Jul 7, 2025

There is an outbound request log you could look at to see the external request made. There is an in-memory negative cache in Nexus which will skip previously failed requests so you may need to use the invalidate cache in the repository’s configuration screen.