voxpupuli / puppet-gitlab_ci_runner

Module to mange gitlab CI runners. Extracted from https://github.com/voxpupuli/puppet-gitlab
Apache License 2.0
14 stars 52 forks source link

Internet connection required when installing gitlab-runner package on debian #99

Open micedre opened 3 years ago

micedre commented 3 years ago

Affected Puppet, Ruby, OS and module versions/distributions

How to reproduce (e.g Puppet code you use)

On a machine without internet access, I am trying to install gitlab-runner through one of my internal repos with a hiera conf like:

gitlab_ci_runner::manage_repo: true
gitlab_ci_runner::repo_base_url: 'https://myrepo/repository/debian-gitlab'

What are you seeing

The module tries to fetch apt key for the repo on the internet (keyserver.ubuntu.com). I do not have a mirror for this and do not wish to install one.

What behaviour did you expect instead

I would like to be able to use all options on apt::key, like providing source or content directly: https://forge.puppet.com/modules/puppetlabs/apt/reference#parameters-3

Output log

Debug: Prefetching apt_key resources for apt_key
Debug: Executing: '/usr/bin/apt-key adv --no-tty --list-keys --with-colons --fingerprint --fixed-list-mode'
Debug: Executing: '/usr/bin/apt-key adv --no-tty --keyserver keyserver.ubuntu.com --recv-keys F6403F6544A38863DAA0B6E03F01618A51312F3F'
Error: Execution of '/usr/bin/apt-key adv --no-tty --keyserver keyserver.ubuntu.com --recv-keys F6403F6544A38863DAA0B6E03F01618A51312F3F' returned 2: Warning: apt-key output should not be parsed (stdout is not a terminal)
Executing: /tmp/apt-key-gpghome.ZVaLy4HGvt/gpg.1.sh --no-tty --keyserver keyserver.ubuntu.com --recv-keys F6403F6544A38863DAA0B6E03F01618A51312F3F
gpg: keyserver receive failed: Connection timed out
Error: /Stage[main]/Gitlab_ci_runner::Repo/Apt::Source[apt_gitlabci]/Apt::Key[Add key: F6403F6544A38863DAA0B6E03F01618A51312F3F from Apt::Source apt_gitlabci]/Apt_key[Add key: F6403F6544A38863DAA0B6E03F01618A51312F3F from Apt::Source apt_gitlabci]/ensure: change from 'absent' to 'present' failed: Execution of '/usr/bin/apt-key adv --no-tty --keyserver keyserver.ubuntu.com --recv-keys F6403F6544A38863DAA0B6E03F01618A51312F3F' returned 2: Warning: apt-key output should not be parsed (stdout is not a terminal)
Executing: /tmp/apt-key-gpghome.ZVaLy4HGvt/gpg.1.sh --no-tty --keyserver keyserver.ubuntu.com --recv-keys F6403F6544A38863DAA0B6E03F01618A51312F3F
gpg: keyserver receive failed: Connection timed out