Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
smartpublicbuilding
openhab-pb-stack
Commits
999af97c
Commit
999af97c
authored
Mar 11, 2019
by
dobli
Browse files
fixed systmctl commands
parent
e4c9da6a
Changes
1
Hide whitespace changes
Inline
Side-by-side
building_manager.py
View file @
999af97c
...
...
@@ -1508,14 +1508,11 @@ def device_link_menu(base_dir):
choices
=
USB_DEVICES
,
style
=
st
).
ask
()
# Start systemd service that ensures link (escapes of backslash needed)
link_cmd_start
=
f
"sudo systemctl status swarm-device@"
+
\
f
"
{
device
}
\\\\\\\\
x20openhab.service"
link_cmd_enable
=
f
"sudo systemctl status swarm-device@"
+
\
link_cmd
=
f
"sudo systemctl status swarm-device@"
+
\
f
"
{
device
}
\\\\\\\\
x20openhab.service"
# Needs enable to keep after reboot
execute_command_on_machine
(
link_cmd_start
,
machine
)
execute_command_on_machine
(
link_cmd_enable
,
machine
)
execute_command_on_machine
(
link_cmd
,
machine
)
print
(
f
"Linked device
{
device
}
to openHAB service on machine
{
machine
}
"
)
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment