docs.rs failed to build cross-platform-service-0.1.0
Please check the build logs for more information.
See Builds for ideas on how to fix a failed build, or Metadata for how to configure docs.rs builds.
If you believe this is docs.rs' fault, open an issue.
Please check the build logs for more information.
See Builds for ideas on how to fix a failed build, or Metadata for how to configure docs.rs builds.
If you believe this is docs.rs' fault, open an issue.
cross-platform-service
The "cross-platform-service" crate lets you developing cross-platform services and service managers for Windows, Linux, and macOS. It supports install, delete, start and stop.
On Windows, API is called by using the microsoft/windows-rs crate, And it is also possible to call the Windows API directory if the service has special needs for Windows.
On Linux, D-Bus used for communication with systemd. The default behavior is defining a systemd service unit, in "/etc/systemd/system" path.
Getting started
use OpenOptions;
use Write;
use Arc;
use ;
use Duration;
use start_service;
const SERVICE_NAME: &str = "MyCrPlSVC";
To compile the project on Linux, D-Bus developing libraries are required, which is may be installed with the following command:
apt install libdbus-1-dev
Examples
cross-platform
Install a cross-platform Service
Delete a cross-platform service
Start a cross-platform service