cli 0.1.9 try fix to periphery start systemd

This commit is contained in:
mbecker20
2023-01-11 22:22:57 +00:00
parent 572560d5b2
commit 1674f066ea
3 changed files with 3 additions and 7 deletions

2
Cargo.lock generated
View File

@@ -1472,7 +1472,7 @@ dependencies = [
[[package]]
name = "monitor_cli"
version = "0.1.8"
version = "0.1.9"
dependencies = [
"async_timing_util",
"clap",

View File

@@ -1,6 +1,6 @@
[package]
name = "monitor_cli"
version = "0.1.8"
version = "0.1.9"
edition = "2021"
authors = ["MoghTech"]
description = "monitor cli | tools to setup monitor system"

View File

@@ -548,13 +548,9 @@ fn periphery_unit_file(config_path: &str) -> String {
let user = env::var("USER").expect("failed to find $USER env var");
format!("[Unit]
Description=agent to connect with monitor core
After=network.target
[Service]
Type=simple
User={user}
WorkingDirectory={home}
ExecStart=/bin/bash --login -c 'source {home}/.bashrc; $HOME/.cargo/bin/periphery --config-path {config_path} --home-dir $HOME'
ExecStart={home}/.cargo/bin/periphery --config-path {config_path} --home-dir {home}
TimeoutStartSec=0
[Install]