Skip to content

Commit

Permalink
set __virtualname__ to 'service' (saltstack#36330)
Browse files Browse the repository at this point in the history
  • Loading branch information
silenius authored and Nicole Thomas committed Sep 15, 2016
1 parent fee3be4 commit 9451141
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion salt/modules/daemontools.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,8 @@

log = logging.getLogger(__name__)

__virtualname__ = 'service'

VALID_SERVICE_DIRS = [
'/service',
'/var/service',
Expand All @@ -46,7 +48,7 @@
def __virtual__():
# Ensure that daemontools is installed properly.
BINS = frozenset(('svc', 'supervise', 'svok'))
return all(salt.utils.which(b) for b in BINS)
return __virtualname__ if all(salt.utils.which(b) for b in BINS) else False


def _service_path(name):
Expand Down

0 comments on commit 9451141

Please sign in to comment.