switch glean.sh path in gentoo openrc init
Change-Id: Ibc601616537c652bee82cd3be37250e4741606bf Signed-off-by: Matthew Thode <mthode@mthode.org>
This commit is contained in:
@@ -5,7 +5,7 @@
|
|||||||
description="basic instance setup"
|
description="basic instance setup"
|
||||||
|
|
||||||
start() {
|
start() {
|
||||||
/usr/bin/glean.sh
|
%%GLEANSH_PATH%%/glean.sh
|
||||||
eend 0
|
eend 0
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -87,6 +87,7 @@ def main():
|
|||||||
action="store_true")
|
action="store_true")
|
||||||
|
|
||||||
args = parser.parse_args()
|
args = parser.parse_args()
|
||||||
|
p = _find_gleansh_path()
|
||||||
|
|
||||||
if args.quiet:
|
if args.quiet:
|
||||||
logging.basicConfig(level=logging.ERROR)
|
logging.basicConfig(level=logging.ERROR)
|
||||||
@@ -96,7 +97,8 @@ def main():
|
|||||||
# needs to go first because gentoo can have systemd along side openrc
|
# needs to go first because gentoo can have systemd along side openrc
|
||||||
if os.path.exists('/etc/gentoo-release'):
|
if os.path.exists('/etc/gentoo-release'):
|
||||||
log.info('installing openrc services')
|
log.info('installing openrc services')
|
||||||
install('glean.openrc', '/etc/init.d/glean')
|
install('glean.openrc', '/etc/init.d/glean',
|
||||||
|
replacements={'GLEANSH_PATH': p})
|
||||||
# Needs to check for the presence of systemd and systemctl
|
# Needs to check for the presence of systemd and systemctl
|
||||||
# as apparently some packages may stage systemd init files
|
# as apparently some packages may stage systemd init files
|
||||||
# when systemd is not present.
|
# when systemd is not present.
|
||||||
@@ -107,7 +109,6 @@ def main():
|
|||||||
if (os.path.exists('/usr/lib/systemd/system') and
|
if (os.path.exists('/usr/lib/systemd/system') and
|
||||||
(os.path.exists('/usr/bin/systemctl') or
|
(os.path.exists('/usr/bin/systemctl') or
|
||||||
os.path.exists('/bin/systemctl'))):
|
os.path.exists('/bin/systemctl'))):
|
||||||
p = _find_gleansh_path()
|
|
||||||
|
|
||||||
log.info("Installing systemd services")
|
log.info("Installing systemd services")
|
||||||
log.info("glean.sh in %s" % p)
|
log.info("glean.sh in %s" % p)
|
||||||
|
|||||||
Reference in New Issue
Block a user