the command works apt -y upgrade
I ran the following commands:
apt -y install python libffi openssl coreutils clang libjpeg-turbo
python -m venv homeassistant
source homeassistant/bin/activate
pip install --upgrade pip
pip install wheel
pip install homeassistant
Resolved!
Thank you!
This is awesome, I was able to install home assistant on my Nvidia Shield. Has anyone successfully installed SSL? I can’t figure this one out
What about ssl? Maybe ssh instead of ssl?
no I mean SSL using letsencrypt. I’d like to access home assistant through https. There’s a tutorial how to do it
but it’s meant for Pi, it’s probably going to be problematic to achieve on Termux
That won’t work on termux. A see on internet some posts about termux and acme_tiny working with nginx reverse proxy. You can try to explore that.
Hello,
Is it possible to connect a zigbee gateway directly like conbee on termux with an OTG cable ?
No. There is no support for usb devices. Only usb disks or keyboards.
Hello,
what is the right pocedere to upgrade homeassistant to the actual version homeassistant 2021.3.1 from 2021.1.3? Please can you help me? Also I need Information for automatical startup via pm2.
If you install hass in venv activate it and than run this command
python -m pip install --upgrade homeassistant
To install pm2 first you need to install nodejs-lts. See post 313.
Hello vladosan,
thanks a lot for your friendly help, the procedere for the upgrade was working very well.
Regards Andy
Greetings all,
Thank you @vladosam for this thread and introducing us to the termux/ha environment. It feels like it is one of the hidden gems and highly underrated.
I would like to contribute to this with a thread with a recent requirement I had and got working within the termux/ha ecosystem: Adding letsencrypt certs (wildcard) to your ha deployment running under termux and have them autorew.
This is not a beginners guide and it assumes the user is familiar with:
- command line, pip, cron
- has access to DNS (for TXT record changes)
- make changes to their configuration.yaml for http on their own
- is capable of using a search engine
This should serve as a sufficient starting point to adopt the commands issue a single domain cert.
In short:
- Create venv for certbot
- Install requirements for certbot to compile (rust)
- Install certbot via pip
- Run certbot with command line arguments to generate wildcard cert
- Install crontab to update certs (untested to see if it does updates correctly)
The details are here: https://gist.github.com/meijerwynand/d2627fd2d45299ac70330f957de2d545
Hi
My mosquitto broker is not working anymore. I may have deleted some conf file. It is starting on boot with pm2. I tried mosquitto -v
How can I restart mosquitto ?
I tried pkg uninstall mosquitto and pkg install mosquitto.
Can someone help me ?
That looks like mosquitto is already stared. pm2 restart mosquitto or just restart termux.
From 2.0 version of mosquitto you need to define listeners to bind on specific interface or on all interfaces. If listener is not defined mosquitto listens only on localhost. You need to add something like this in mosquitto config to listen on all interfaces:
listener 1883 0.0.0.0
allow_anonymous true
Thank you it is working now
when i try to run hass the following error appears:
(homeassistant) ~/.homeassistant $ pm2 logs hass
[TAILING] Tailing last 15 lines for [hass] process (change the value with --lines option)
/data/data/com.termux/files/home/.pm2/logs/hass-out.log last 15 lines:
2|hass | Unable to find configuration. Creating default one in /data/data/com.termux/files/home/.homeassistant
/data/data/com.termux/files/home/.pm2/logs/hass-error.log last 15 lines:
2|hass | File "/data/data/com.termux/files/home/homeassistant/lib/python3.9/site-packages/homeassistant/components/ssdp/__init__.py", line 51, in _async_initialize
2|hass | await scanner.async_scan(None)
2|hass | File "/data/data/com.termux/files/home/homeassistant/lib/python3.9/site-packages/homeassistant/components/ssdp/__init__.py", line 91, in async_scan
2|hass | await self._process_entries()
2|hass | File "/data/data/com.termux/files/home/homeassistant/lib/python3.9/site-packages/homeassistant/components/ssdp/__init__.py", line 138, in _process_entries
2|hass | await asyncio.gather(*tasks)
2|hass | File "/data/data/com.termux/files/home/homeassistant/lib/python3.9/site-packages/homeassistant/data_entry_flow.py", line 150, in async_init
2|hass | flow, result = await task
2|hass | File "/data/data/com.termux/files/home/homeassistant/lib/python3.9/site-packages/homeassistant/data_entry_flow.py", line 176, in _async_init
2|hass | result = await self._async_handle_step(flow, flow.init_step, data, init_done)
2|hass | File "/data/data/com.termux/files/home/homeassistant/lib/python3.9/site-packages/homeassistant/data_entry_flow.py", line 257, in _async_handle_step
2|hass | result: FlowResult = await getattr(flow, method)(user_input)
2|hass | File "/data/data/com.termux/files/home/homeassistant/lib/python3.9/site-packages/homeassistant/components/fritz/config_flow.py", line 115, in async_step_ssdp
2|hass | "name": self._name.replace("FRITZ!Box ", "")
2|hass | AttributeError: 'NoneType' object has no attribute 'replace'