mirror of
https://github.com/home-assistant/home-assistant.io.git
synced 2025-07-13 12:26:50 +00:00
Added virtualenv example
This commit is contained in:
parent
037fd26972
commit
ecf53028d7
@ -35,6 +35,23 @@ WantedBy=multi-user.target
|
|||||||
EOF'
|
EOF'
|
||||||
```
|
```
|
||||||
|
|
||||||
|
If you've setup `hass` in virtualenv following the guide the following template should work for you.
|
||||||
|
|
||||||
|
```
|
||||||
|
[Unit]
|
||||||
|
Description=Home Assistant
|
||||||
|
After=network.target
|
||||||
|
|
||||||
|
[Service]
|
||||||
|
Type=simple
|
||||||
|
User=hass
|
||||||
|
ExecStartPre=source source /srv/hass/bin/activate
|
||||||
|
ExecStart=/srv/hass/bin/hass -c "/home/hass/.homeassistant"
|
||||||
|
|
||||||
|
[Install]
|
||||||
|
WantedBy=multi-user.target
|
||||||
|
```
|
||||||
|
|
||||||
There is also another [sample service file](https://raw.githubusercontent.com/home-assistant/home-assistant/master/script/home-assistant%40.service) available. To use this one, just download it.
|
There is also another [sample service file](https://raw.githubusercontent.com/home-assistant/home-assistant/master/script/home-assistant%40.service) available. To use this one, just download it.
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
|
Loading…
x
Reference in New Issue
Block a user