Comments (5)
I didn't want to expose a home assistant endpoint so I used an SSH tunnel instead. If anyone else is interested, I can parameterize this a bit and kick off a PR.
def event_handler(event, context):
config = Configuration('config.json')
if config.debug:
logger.setLevel(logging.DEBUG)
ssh_key_pass = boto3.client('kms').decrypt(CiphertextBlob=b64decode(os.environ['ssh_key_pass']))['Plaintext']
with SSHTunnelForwarder(
("myhomeassistantserver.com", 8124),
ssh_username="homeassistant",
ssh_pkey="./hass.key",
ssh_private_key_password=ssh_key_pass,
remote_bind_address=("0.0.0.0", 8123),
local_bind_address=('0.0.0.0', 8123)
) as tunnel:
ha = HomeAssistant(config)
return ha.post('alexa/smart_home', event, wait=True).json()
from haaska.
@fotiDim Hi there, thanks for checking out Haaska.
It doesn’t require an SSL certificate, but it does require your Home Assistant install is reachable from the internet. For that reason, it’s best that you take every step possible to secure your Home Assistant install.
With HA Cloud, it opens its own secure connection outbound to the Alexa Voice Service.
Haaska goes the other direction, where when a command is sent from Alexa, it must go out and contact your local HA install.
Does that make sense?
Let me know if you have any questions or concerns.
from haaska.
@puppetcoder Wow! Anything is on the table, so if you want to make a PR, I’ll definitely review/merge.
from haaska.
Thanks to @puppetcoder, better security is now an option. Will update the docs soon.
@fotiDim Are we good to close this out?
from haaska.
@anthonylavado sure closing it and happy to test it out!
from haaska.
Related Issues (20)
- IPV6 connection HOT 1
- Skill can't find devices HOT 1
- Make failed
- core-2022.2.6 HOT 1
- “Unable to import module ‘lambda_function’” HOT 4
- Upgrade to Python 3.9 HOT 8
- 404 Client Error HOT 2
- Help with 401 Error with Haaska integration HOT 1
- get_url method breaking some URLs HOT 1
- 502 bad gateway going through NGINS reverse proxy
- tts not working HOT 2
- Linking Alexa Skills Kit to Login With Amazon scope incorrect HOT 1
- IPv6 support HOT 1
- I'm having an issue HOT 1
- SKILL_DISABLED_EXCEPTION after enabling proactive events HOT 1
- Address family not supported by protocol
- Wiki step #5 & #6 ?
- The wiki documentation is outdated HOT 1
- smart_home: still working? HOT 1
- Linking Skill I get 404:not found HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from haaska.