HomeFreeBSD

service(8): Add support for interfacing with services in jails

Description

service(8): Add support for interfacing with services in jails

Provide a -j option that can take a jail name or id. If -j is specified,
check that the jail exists and proxy the service request through to
service(8) in the jail.

This allows for cleaner workflows when updating services in a jail, turning
the following:

pkg -j dns upgrade
jexec dns service named restart

into:

pkg -j dns upgrade
service -j dns named restart

PR: 223325
Submitted by: David O'Rourke (with slight changes)
MFC after: 2 weeks

Details

Provenance
kevansAuthored on
Parents
rS328031: Need to free uv after we're done using it.
Branches
Unknown
Tags
Unknown