]> code.ossystems Code Review - openembedded-core.git/commitdiff
nfs-utils: systemd fixes
authorAndreas Oberritter <obi@opendreambox.org>
Wed, 30 Nov 2016 22:43:01 +0000 (23:43 +0100)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Thu, 8 Dec 2016 10:26:13 +0000 (10:26 +0000)
- Start daemons by default like the initscripts do, but only if
  /etc/exports exists.
- Inform systemd.bbclass about nfs-utils-client package.

Signed-off-by: Andreas Oberritter <obi@opendreambox.org>
Signed-off-by: Ross Burton <ross.burton@intel.com>
meta/recipes-connectivity/nfs-utils/nfs-utils/nfs-mountd.service
meta/recipes-connectivity/nfs-utils/nfs-utils/nfs-server.service
meta/recipes-connectivity/nfs-utils/nfs-utils_1.3.4.bb

index 613ddc003ad6af059c239e9b09926647753bfc51..28b7388f6759d1a68991c1d184c9851fb1619af7 100644 (file)
@@ -2,6 +2,7 @@
 Description=NFS Mount Daemon
 After=rpcbind.service nfs-server.service
 Requires=rpcbind.service nfs-server.service
+ConditionPathExists=@SYSCONFDIR@/exports
 
 [Service]
 EnvironmentFile=-@SYSCONFDIR@/nfs-utils.conf
index 147d7a7b5fde185f0227e4a632e273c689166510..b9dfe74273c0e8682a5b6c3f3421c4b2a29a8083 100644 (file)
@@ -2,6 +2,7 @@
 Description=NFS Server
 Requires=rpcbind.service nfs-mountd.service
 After=rpcbind.service
+ConditionPathExists=@SYSCONFDIR@/exports
 
 [Service]
 Type=oneshot
index 4d6d8080f4f6ecc19ce5da7f24eed9547c31fcba..d4b401efa028ca805380d3d573641ca2d4073405 100644 (file)
@@ -48,9 +48,9 @@ INITSCRIPT_PARAMS_${PN}-client = "defaults 19 21"
 
 inherit autotools-brokensep update-rc.d systemd pkgconfig
 
+SYSTEMD_PACKAGES = "${PN} ${PN}-client"
 SYSTEMD_SERVICE_${PN} = "nfs-server.service nfs-mountd.service"
 SYSTEMD_SERVICE_${PN}-client = "nfs-statd.service"
-SYSTEMD_AUTO_ENABLE = "disable"
 
 # --enable-uuid is need for cross-compiling
 EXTRA_OECONF = "--with-statduser=rpcuser \