This is for generating systemd service configuration files. It can also copy it directly to the system service directory.
- Python3(latest)
- Pip
[app]
description="Hello Service"
exec_start="python /mnt/coding/coding/pysystemdgenerator/systemdgenerator/test/hello.py"
working_dir="/mnt/coding/coding/pysystemdgenerator/systemdgenerator/test"
user="root"
[environment]
envs=[
{ key = "message", value = "Hello There!"},
{ key = "name", value = "Secret"}
]
env_files = ["/mnt/coding/coding/pysystemdgenerator/systemdgenerator/test/.env"]- Install requirements
pip install -r requirements.txt - Prepare the configuration file at place in under the
configdirectory. - A. Generate with arguments.
python main.py <config> <output> - B. Generate with input.
python main.py