From d3d206a6b95e9fc5801d0adb50df6c3e0da56b83 Mon Sep 17 00:00:00 2001 From: lonerr Date: Tue, 23 Apr 2013 21:40:50 +0400 Subject: [PATCH] FreeBSD startup scripts (rc) supports optional arguments. --- service | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/service b/service index 61aa48990bc..e972c35e81c 100644 --- a/service +++ b/service @@ -600,7 +600,7 @@ class FreeBsdService(Service): self.module.fail_json(msg='unable to find service binary') def get_service_status(self): - rc, stdout, stderr = self.execute_command("%s %s %s" % (self.svc_cmd, self.name, 'onestatus')) + rc, stdout, stderr = self.execute_command("%s %s %s %s" % (self.svc_cmd, self.name, 'onestatus', self.arguments)) if rc == 1: self.running = False elif rc == 0: @@ -630,7 +630,7 @@ class FreeBsdService(Service): if self.action is "reload": self.action = "onereload" - return self.execute_command("%s %s %s" % (self.svc_cmd, self.name, self.action)) + return self.execute_command("%s %s %s %s" % (self.svc_cmd, self.name, self.action, self.arguments)) # =========================================== # Subclass: OpenBSD