leylines/leylines-ansible/templates/leylines-worker.service

14 lines
693 B
SYSTEMD
Raw Normal View History

2021-06-15 08:37:57 +00:00
[Unit]
Description=Dask worker for leylines
[Service]
Type=simple
Environment=PATH=%h/.local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
Environment=LD_LIBRARY_PATH=%h/.local/lib:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
ExecStart=/bin/bash -c 'source dask-venv/bin/activate && exec dask-worker --dashboard-address {{leylines_ip}}:31336 --host {{leylines_ip}} --protocol tcp --nthreads 1 --nprocs auto --name {{inventory_hostname}} --local-directory $CACHE_DIRECTORY --resources "{{leylines_resources}}" --death-timeout 31536000 {{leylines_server_addr}}:31337'
2021-06-15 08:37:57 +00:00
WorkingDirectory=%h/dask
CacheDirectory=leylines-worker
[Install]
WantedBy=default.target