Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support docker::registry_mirror config option. #244

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 0 additions & 3 deletions modules/agent_files/files/docker-daemon.json

This file was deleted.

4 changes: 4 additions & 0 deletions modules/agent_files/templates/docker-daemon.json.erb
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
<% if ! scope.function_hiera(["docker::registry_mirror"], "").empty? %> "registry-mirrors": ["<%= scope.function_hiera(["docker::registry_mirror"])%>"],<% end -%>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm unsure about how puppet is going to return the scope.function_hiera(["docker::registry_mirror"]) being docker::registry_mirror an array. Probably worth to take a look once running this to be sure the format (plain string?) is the expected.

"seccomp-profile": "/etc/docker/seccomp-profiles/docker-default-with-personality.json"
}
2 changes: 1 addition & 1 deletion modules/profile/manifests/jenkins/agent.pp
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@
}

file { '/etc/docker/daemon.json':
source => 'puppet:///modules/agent_files/docker-daemon.json',
source => template('agent_files/docker-daemon.json'),
require => Class[docker],
}

Expand Down