Install Dependency
apt-get install -y python3 python3-dev python3-venv python3-pip libffi-dev libssl-dev libjpeg-dev zlib1g-dev autoconf build-essential libopenjp2-7 libtiff5 libturbojpeg0-dev tzdata
Create HA User
useradd -rm homeassistant
Create Virtual ENV
mkdir /srv/homeassistant
chown homeassistant:homeassistant /srv/homeassistant
# Change User
sudo -u homeassistant -H -s
cd /srv/homeassistant
python3 -m venv .
source bin/activate
Install HomeAssistant And Package
python3 -m pip install wheel
pip3 install homeassistant
Use hass
To Start HA Process
hass
Use Browser Visit http://ha:8123
Trouble Shoot
If You Get When You Run hass
(homeassistant) homeassistant@raspberrypi:~ $ hass
Traceback (most recent call last):
File "/srv/homeassistant/bin/hass", line 10, in <module>
sys.exit(main())
.
.
.
.
ImportError: cannot import name 'contextfilter' from 'jinja2' (/srv/homeassistant/lib/python3.7/site-packages/jinja2/__init__.py)
Sulotions
(homeassistant) homeassistant@raspberrypi:~ $ pip uninstall jinja2
Uninstalling Jinja2-3.1.1:
Would remove:
/srv/homeassistant/lib/python3.7/site-packages/Jinja2-3.1.1.dist-info/*
/srv/homeassistant/lib/python3.7/site-packages/jinja2/*
Proceed (y/n)? y
Successfully uninstalled Jinja2-3.1.1
(homeassistant) homeassistant@raspberrypi:~ $ pip install jinja2==3.0.3
Top comments (0)