Permalink
Browse files

Use /etc/default/docker properly.

  • Loading branch information...
darron committed Jan 19, 2014
1 parent c6e99a9 commit 77309c615a848173ad4db3ba110e6bfe3fd0979c
Showing with 16 additions and 10 deletions.
  1. +0 −3 attributes/default.rb
  2. +1 −1 metadata.rb
  3. +3 −4 recipes/default.rb
  4. +2 −2 spec/default_spec.rb
  5. +10 −0 templates/default/docker.erb
View
@@ -21,6 +21,3 @@
default['docker']['package']['distribution'] = 'docker'
default['docker']['package']['repo_url'] = 'https://get.docker.io/ubuntu'
default['docker']['package']['repo_key'] = 'https://get.docker.io/gpg'
-
-default['docker']['upstart_file_path'] = '/etc/init/docker.conf'
-default['docker']['upstart_file'] = 'https://raw.github.com/octohost/octohost/master/config/docker.conf'
View
@@ -4,7 +4,7 @@
maintainer_email 'darron@froese.org'
license 'Apache 2.0'
description 'Installs/configures docker'
-version '0.1.0'
+version '0.2.0'
recipe 'docker::default', 'Installs/configures docker'
depends 'apt'
View
@@ -32,12 +32,11 @@
action [:enable, :stop]
end
-remote_file node['docker']['upstart_file_path'] do
- source node['docker']['upstart_file']
+template '/etc/default/docker' do
+ source 'docker.erb'
+ mode 0644
owner 'root'
group 'root'
- mode 00644
- action :create
end
service 'docker' do
View
@@ -9,8 +9,8 @@
expect(chef_run).to install_package('lxc-docker')
end
- it 'creates a remote_file' do
- expect(chef_run).to create_remote_file('/etc/init/docker.conf')
+ it 'creates the docker defaults file' do
+ expect(chef_run).to create_template('/etc/default/docker')
end
it 'enables the docker service' do
@@ -0,0 +1,10 @@
+# Docker Upstart and SysVinit configuration file
+
+# Customize location of Docker binary (especially for development testing).
+#DOCKER="/usr/local/bin/docker"
+
+# Use DOCKER_OPTS to modify the daemon startup options.
+DOCKER_OPTS="-H tcp://0.0.0.0:4243 -H unix:///var/run/docker.sock"
+
+# If you need Docker to use an HTTP proxy, it can also be specified here.
+#export http_proxy=http://127.0.0.1:3128/

0 comments on commit 77309c6

Please sign in to comment.