Use docker profile in docker_registry
authorDan Prince <dprince@redhat.com>
Fri, 7 Apr 2017 20:07:12 +0000 (16:07 -0400)
committerDan Prince <dprince@redhat.com>
Fri, 7 Apr 2017 20:27:03 +0000 (16:27 -0400)
The docker_registry profile has resources to configure
the docker service and package. These conflict with the
entries in the tripleo::profile::base::docker class which
exists specifically to manage these resources (and has
unit tests).

This patch removes the duplicate resources and updates
the docker_registry profile to simply include the
base docker profile instead.

This instack-undercloud change below needs to land first.
Depends-On: I6154f4c7435b02b92f6f64687e9ee89d6b86186a

Change-Id: I75c740e7efc6662861c28caeb7fa965ba55438cb

manifests/profile/base/docker_registry.pp

index 2f1783d..73fb6e0 100644 (file)
@@ -36,13 +36,15 @@ class tripleo::profile::base::docker_registry (
   $registry_port       = 8787,
   $registry_admin_host = hiera('controller_admin_host'),
 ) {
+
+  include ::tripleo::profile::base::docker
+
   # We want a v2 registry
   package{'docker-registry':
     ensure        => absent,
     allow_virtual => false,
   }
   package{'docker-distribution': }
-  package{'docker': }
   package{'openstack-kolla': }
   file { '/etc/docker-distribution/registry/config.yml' :
     ensure  => file,
@@ -68,9 +70,4 @@ class tripleo::profile::base::docker_registry (
     enable  => true,
     require => Package['docker-distribution'],
   }
-  service { 'docker':
-    ensure  => running,
-    enable  => true,
-    require => Package['docker'],
-  }
 }