This integration was forked from the alexa-actions. Big thanks to this create project. I hope the open pull request will be merged at some point and the projects get married. In the meantime, I maintain the fork and some documentation in the README
I give no guarantee for the functionality and no promise of lifelong maintenance, as I do the whole thing in my free time. Of course, I am happy about every contribution and PullRequest ❤️
Please ⭐️ or sponsor this repo when you like it ❤️.
Also thanks to the amazing Tailscaleintegrations!
See for some basic information the available [wiki] (https://github.com/keatontaylor/alexa-actions/wiki)
Here are some steps you need to take. Since this guide is fairly new, please create a ticket or PR to resolve any confusion. The premise is that Tailscale Integration is installed in HA and the HA instance is available as a node.
- The Git repo must be forked so that the Docker image for the AWS Lambda can be pushed to your private repository in the Amazon Elastic Container Registry.
- Create a private repository on AWS Amazon Elastic Container Registry. The name must be ha-custom-lambda-tailscale for the repo
See for more information [AWS Introduction ECR] (https://aws.amazon.com/de/ecr/getting-started/)
- Create a keypair on AWS Identity Management (IM) to allow github action to push the Docker image to ECR. Create AWS_ACCESS_KEY_ID_ and AWS_SECRET_ACCESS_KEY
See for more information [AWS Introduction credentials] (https://docs.aws.amazon.com/de_de/keyspaces/latest/devguide/access.credentials.html#SigV4_credentials)
Remember both carefully because the secret is only displayed once and is required in the next step.
- Go to your forked repo under settings. Go to secrets and variables. Create two new secrets with AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY from the previous step
- Then build and push the Docker image under Github Actions. To do this, run
.github/workflows/docker-build-push.yml
Congratulations! This is the first step and the result should look like this. 🎊
- Create a new function. Select Container Image at the top
See for more information [AWS Lambda] (https://docs.aws.amazon.com/de_de/lambda/latest/dg/getting-started.html)
- Name the function alexa-actionable-notifications-function and select the Docker image from the ECR and click create function
- Click "Add Trigger" and copy your skill id from the previous step from the Skill
- Now we have to log in to our Tailscale account and create an ephemeral key. Go to settings --> key
-
An HA long-living token (10 years) must then be created that Lambda can access to your HA-Instance, which is only available into your VPN. Please remember the key.
-
Now the following ENV variables must be inserted into the function.
ENV | Type | Default | Description |
---|---|---|---|
DEBUG | boolean | false | Type of the card. |
HA_TOKEN | string | The long living HA token | |
HA_URL | string | Important the TAILSCALE ip from HA e.g http://{tailscale-ha-ip}:8123. Should be start with 100.xxx.xxx.xxx TAILSCALE_AUTHKEY the ephemeral key. Should be start with tskey-auth-xxxxx |
- Save function to deploy the function new
Now the Alexa skill can be tested and integrated into HA. These are the same steps like in the wiki
The only thing that changes in the Alexa Skill chapter in the editor is that you don't have to create a PY for the template. Actually always click Customize
Troubleshooting: I rarely get timeouts from tailscale. Ticket is open. That's why I increased the timeout to 10 seconds.
The ECR and the AWS Lambda can cost money. For this reason the image was kept small. But you need to have a lot of traffic and updates. With testing and everything, my most expensive month was 4 cents ❤️
- Cannot create a ephemeral key automatically
- I rarely get timeouts from tailscale. Ticket is open. That's why I increased the timeout to 10 seconds.