Eric Callahan
8c7b93c6dd
machine: fix supervisord active state reporting
...
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2023-02-08 17:00:39 -05:00
Eric Callahan
8010f1dda2
machine: add shutdown action option
...
Signed-off-by: Eric Callahan <arkisne.code@gmail.com>
2023-02-08 11:11:34 -05:00
Eric Callahan
f0b82afde4
machine: remove unnecessary supervisord handlers
...
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2023-02-08 06:02:25 -05:00
Eric Callahan
645f0c9acf
machine: add container detection logging
...
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2023-02-08 06:00:01 -05:00
Eric Callahan
b02224485e
machine: rename supervisord provider
...
This is a cli providers, so rename it to supervisord_cli.
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2023-02-08 05:36:57 -05:00
Eric Callahan
c69441955a
machine: support supervisord service info extraction
...
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2023-02-07 19:10:17 -05:00
Eric Callahan
5aa645f974
machine: simplify extract_service_info() call
...
Don't require the caller to specifiy properties, use the default
property list if not specified.
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2023-02-07 19:10:17 -05:00
Eric Callahan
2fb136449a
machine: fix supervisorctl command arguments
...
According to the supervisord documentation the `-c` option is used to
specify the configuraiton file.
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2023-02-07 19:10:17 -05:00
Eric Callahan
8335906443
machine: automate supervisord process init
...
Don't hardcode klipper and moonraker, detect them along with all other
allowed services.
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2023-02-07 19:10:16 -05:00
Quinn Damerell
babf97be3b
Adding OctoEverywhere to the default service list
...
module: Adding OctoEverywhere to the default service list.
Adding OctoEverywhere to the default service list in machine.py so future installs of moonraker will allow the octoeverywhere service to be managed from frontends.
Signed-off-by: Quinn Damerell <quinnd@outlook.com>
2023-02-03 19:09:34 -05:00
Eric Callahan
db81607370
machine: use direct systemctl commands for reboot/shutdown
...
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2023-01-16 12:42:21 -05:00
Eric Callahan
a154c5fa51
machine: add moonraker-obico to default services
...
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2023-01-12 18:10:30 -05:00
Eric Callahan
690f841768
machine: introduce custom allow list for service control
...
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2023-01-02 07:46:43 -05:00
Pedro Lamas
b67a08a65b
machine: use virtualization.virt_identifier property
...
Signed-off-by: Pedro Lamas <pedrolamas@gmail.com>
2022-11-22 05:59:18 -05:00
Eric Callahan
362bc1a3d3
machine: fix typos and clarify supervisord docs
...
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2022-11-18 10:42:44 -05:00
mirokymac
48f3bb2189
machine.py: add support for supervisord service management
...
Signed-off-by: mirokymac <toufubomb@gmail.com>
2022-11-18 10:37:33 -05:00
Eric Callahan
68f5de6d2d
machine: report canbus info
...
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2022-11-16 14:20:07 -05:00
Eric Callahan
bb7cd27be5
machine: fix typo in sudo access request
...
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2022-11-06 11:43:52 -05:00
Eric Callahan
1ef34b8b60
machine: improve default database handling
...
Don't force a symlink to the default database if
the subfolder exits.
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2022-10-22 16:44:51 -04:00
Eric Callahan
4df0b4d532
machine: abort validation if the backup config is loaded
...
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2022-10-21 10:26:25 -04:00
Eric Callahan
1190aba4b7
machine: add logging to validation init
...
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2022-10-21 10:26:25 -04:00
Eric Callahan
974b37dad8
machine: improve multi-instance validation
...
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2022-10-20 20:27:02 -04:00
Eric Callahan
4954cc74cd
machine: change sudo folder access test
...
The previous "/lost+found" is not available on all systems. Change to
"/root", which should be available.
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2022-10-19 06:21:18 -04:00
Eric Callahan
d6bdad3a9d
machine: announce required update via gcode terminal
...
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2022-10-18 14:07:27 -04:00
Eric Callahan
f1c4d6b143
machine: validation fix for new installs
...
Add a missing return statement to _link_data_subfolder.
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2022-10-17 06:30:54 -04:00
Eric Callahan
7e35e54a71
machine: increase timeout for sudo access check
...
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2022-10-15 20:01:19 -04:00
Eric Callahan
05ca71f5a8
machine: relax config validation
...
Don't raise an exception if the option in a path does not exist. Remove
the option and fall back to the default path location
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2022-10-15 19:58:34 -04:00
Eric Callahan
53fcc7386f
machine: increase timeouts for sudo commands
...
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2022-10-15 10:52:04 -04:00
Eric Callahan
00c4846d11
machine: validation fixes
...
Protect the sudo request with a lock. Add retries to the sudo
commands.
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2022-10-15 08:37:45 -04:00
th33xitus
fb327a6ca9
machine: use term "sudo" instead of "root"
...
Signed-off-by: Dominik Willner <th33xitus@gmail.com>
2022-10-15 06:11:14 -04:00
Eric Callahan
500e8f3b68
machine: disable file write access when validation fails
...
Prevent users from uploading files before validation is complete, as
this can populate one of the subfolders resulting in a failure when
attempting to symlink the original path.
When validating the config symlink the database first. This should
allow Moonraker to correctly move the database should an error
be encountered when validating the other config options.
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2022-10-15 06:01:36 -04:00
Eric Callahan
485b29490a
update_manager: deprecate repo debug option
...
Use the "debug" command line option to enable debug
features for the update manager.
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2022-10-14 15:15:41 -04:00
Eric Callahan
86fc1057f7
server: deprecate debug logging option
...
Add a debug option to the command line to enable
debug features.
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2022-10-14 15:15:41 -04:00
Eric Callahan
9021fbea48
machine: use default password for validation
...
For legacy Raspberry Pi installations attempt to automate
the update using the default password.
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2022-10-14 15:15:41 -04:00
Eric Callahan
41ea45a486
moonraker: remove alias option
...
Differentiate instances based on the data path provided.
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2022-10-14 15:15:41 -04:00
Eric Callahan
266c5b53d1
machine: extend system info request with unit names
...
Report the unit names for both Moonarker and Klipper.
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2022-10-14 15:15:41 -04:00
Eric Callahan
6e56815b42
machine: implement install validation
...
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2022-10-14 15:15:41 -04:00
Eric Callahan
db7474aa88
machine: use sudo password for commands if available
...
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2022-08-21 06:30:28 -04:00
Eric Callahan
272f7b946d
machine: add endpoint to check sudo access
...
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2022-08-21 05:59:38 -04:00
Eric Callahan
12161d12f5
machine: improve private ip detection
...
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2022-08-21 05:16:06 -04:00
Eric Callahan
4efb6575b7
machine: report provider type and container info
...
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2022-08-21 05:15:19 -04:00
Eric Callahan
c154d92499
machine: add support for setting a sudo password
...
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2022-08-21 05:13:44 -04:00
Eric Callahan
a7b50a8068
machine: extract moonraker systemd unit info
...
This allows moonraker to validate and log the current unit file.
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2022-08-21 05:13:31 -04:00
Eric Callahan
3424f1b3e2
machine: fix IP detection broadcast setting
...
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2022-08-08 19:26:19 -04:00
Eric Callahan
c4e370fcff
machine: improve LAN IP detection
...
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2022-08-08 19:20:56 -04:00
Eric Callahan
bdd0222a1c
machine: handle exception if iwgetid fails
...
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2022-07-24 17:16:34 -04:00
Eric Callahan
3b76d81155
machine: add sonar and crowsnest to allowed services
...
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2022-06-07 06:51:40 -04:00
Eric Callahan
d3003a1584
machine: return default values for find public interface
...
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2022-04-15 17:27:36 -04:00
Eric Callahan
393cfa2a0e
machine: implement get_public_network method
...
This allows components to determine the current local
ip address that routes to the internet.
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2022-04-04 17:18:02 -04:00
Eric Callahan
221df0937d
machine: fix typo in cpu description parser
...
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2022-03-02 19:25:53 -05:00