aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChen Qi <Qi.Chen@windriver.com>2022-06-12 01:00:01 -0700
committerBruce Ashfield <bruce.ashfield@gmail.com>2022-06-20 12:09:51 -0400
commit0642784cb137466460a79da9e86f9958089ea2f6 (patch)
treeea3bddecf66186f71df1d662b83bcef4a144a986
parenta2dd7d887fa4ed5ef36ff17537ec0a9e59c610e0 (diff)
downloadmeta-virtualization-0642784cb137466460a79da9e86f9958089ea2f6.tar.gz
meta-virtualization-0642784cb137466460a79da9e86f9958089ea2f6.tar.bz2
meta-virtualization-0642784cb137466460a79da9e86f9958089ea2f6.zip
docker-distribution: fix the inehrit and systemd settings
In order for systemd variables such as SYSTEMD_AUTO_ENABLE to have effect, we need to inherit the systemd class. We also need to specify the package which contains the service. As go.bbclass already inherits goarch.bbclass, we only need to inehrit go.bbclass. Signed-off-by: Chen Qi <Qi.Chen@windriver.com> Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
-rw-r--r--recipes-containers/docker-distribution/docker-distribution_git.bb4
1 files changed, 2 insertions, 2 deletions
diff --git a/recipes-containers/docker-distribution/docker-distribution_git.bb b/recipes-containers/docker-distribution/docker-distribution_git.bb
index 0dbdc49..395694a 100644
--- a/recipes-containers/docker-distribution/docker-distribution_git.bb
+++ b/recipes-containers/docker-distribution/docker-distribution_git.bb
@@ -16,8 +16,7 @@ S = "${WORKDIR}/git/src/github.com/docker/distribution"
GO_IMPORT = "import"
-inherit goarch
-inherit go
+inherit goarch go systemd
# This disables seccomp and apparmor, which are on by default in the
# go package.
@@ -66,6 +65,7 @@ FILES:docker-registry += "${systemd_unitdir}/system/docker-registry.service"
FILES:docker-registry += "${sysconfdir}/docker-distribution/*"
FILES:docker-registry += "${localstatedir}/lib/registry/"
+SYSTEMD_PACKAGES = "docker-registry"
SYSTEMD_SERVICE:docker-registry = "${@bb.utils.contains('DISTRO_FEATURES','systemd','docker-registry.service','',d)}"
SYSTEMD_AUTO_ENABLE:docker-registry = "enable"