X-Git-Url: https://git.openstreetmap.org./chef.git/blobdiff_plain/28d9a1d5b4c58ebc33e94780753e6c1e2a2e2181..1bc290ecce828f4a28d096c383815d2aa9199253:/cookbooks/docker/recipes/default.rb diff --git a/cookbooks/docker/recipes/default.rb b/cookbooks/docker/recipes/default.rb index fd3773634..80fd15b3f 100644 --- a/cookbooks/docker/recipes/default.rb +++ b/cookbooks/docker/recipes/default.rb @@ -17,28 +17,29 @@ # limitations under the License. # +include_recipe "apt" + package %w[ - apt-transport-https - ca-certificates - curl - software-properties-common - gnupg2 + docker-ce + docker-ce-cli + containerd.io ] +directory "/etc/docker" do + owner "root" + group "root" + mode "755" +end + template "/etc/docker/daemon.json" do source "daemon.json.erb" owner "root" group "root" - mode 0o644 + mode "644" end -package %w[ - docker-ce - docker-ce-cli - containerd.io -] - service "docker" do action [:enable, :start] subscribes :restart, "template[/etc/docker/daemon.json]" + not_if { kitchen? } end