-
-
Notifications
You must be signed in to change notification settings - Fork 7.8k
Significantly improve Tesla Fleet config flow #39542
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
It seems that this PR is targeted against an incorrect branch. Documentation updates which apply to our current stable release should target the |
✅ Deploy Preview for home-assistant-docs ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
📝 WalkthroughWalkthroughThe Tesla Fleet integration documentation was revised to simplify the setup process. Manual steps for generating and uploading keys and registering as a Fleet API partner were removed. Now, users receive the public key during setup and are instructed to host it as required. Some formatting and explanatory adjustments were also made. Changes
Sequence Diagram(s)sequenceDiagram
participant User
participant Integration Setup
participant Hosting Environment
User->>Integration Setup: Start Tesla Fleet integration setup
Integration Setup->>User: Provide public key
User->>Hosting Environment: Save and host public key at required path
Note over User,Integration Setup: No manual key generation or partner registration required
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
🧹 Nitpick comments (3)
source/_integrations/tesla_fleet.markdown (3)
81-91
: Add parent directory creation before writing PEM file.Step 2 writes the public key under
/share/tesla/.well-known/appspecific/...
but doesn’t ensure those directories exist. Recommend prepending amkdir -p /share/tesla/.well-known/appspecific
command to avoid failures on fresh installs.
93-98
: Clarify hosting prerequisites in generic key section.The generic hosting instructions repeat the path requirement but omit directory setup and redirect warnings. Suggest calling out that users must create the
/.well-known/appspecific
folder on their host and ensure no HTTP redirects are in place, to prevent Tesla API errors.
142-146
: Fix stray character, verb usage, and bare URL.
- Remove the trailing “W” on line 142.
- Change “setup” to the verb form “set up” for correct grammar.
- Convert the bare URL on line 144 into a markdown link to satisfy lint rules, e.g.
[https://tesla.com/_ak/YOUR.DOMAIN](https://tesla.com/_ak/YOUR.DOMAIN)
.🧰 Tools
🪛 LanguageTool
[grammar] ~142-~142: Make sure that the noun ‘setup’ is correct. Did you mean the past participle “set up”?
Context: ...is is required and the key has not been setup correctly.W Your public key must be ad...(BE_VB_OR_NN)
🪛 markdownlint-cli2 (0.17.2)
144-144: Bare URL used
null(MD034, no-bare-urls)
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
Cache: Disabled due to data retention organization setting
Knowledge Base: Disabled due to data retention organization setting
📒 Files selected for processing (1)
source/_integrations/tesla_fleet.markdown
(2 hunks)
🧰 Additional context used
🪛 LanguageTool
source/_integrations/tesla_fleet.markdown
[grammar] ~142-~142: Make sure that the noun ‘setup’ is correct. Did you mean the past participle “set up”?
Context: ...is is required and the key has not been setup correctly.W Your public key must be ad...
(BE_VB_OR_NN)
🪛 markdownlint-cli2 (0.17.2)
source/_integrations/tesla_fleet.markdown
144-144: Bare URL used
null
(MD034, no-bare-urls)
⏰ Context from checks skipped due to timeout of 90000ms (3)
- GitHub Check: Redirect rules - home-assistant-docs
- GitHub Check: Header rules - home-assistant-docs
- GitHub Check: Pages changed - home-assistant-docs
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you, @Bre77 👍
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
🧹 Nitpick comments (1)
source/_integrations/tesla_fleet.markdown (1)
142-145
: Fix grammar and formatting in command signing section
- Replace “has not been setup correctly.W” with “has not been set up correctly.” (remove stray “W” and correct “setup”→“set up”).
- Convert the bare URL to a markdown link, e.g.:
[Tesla key pairing page](https://tesla.com/_ak/YOUR.DOMAIN)
.🧰 Tools
🪛 LanguageTool
[grammar] ~142-~142: Make sure that the noun ‘setup’ is correct. Did you mean the past participle “set up”?
Context: ...is is required and the key has not been setup correctly.W Your public key must be ad...(BE_VB_OR_NN)
🪛 markdownlint-cli2 (0.17.2)
144-144: Bare URL used
null(MD034, no-bare-urls)
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
Cache: Disabled due to data retention organization setting
Knowledge Base: Disabled due to data retention organization setting
📒 Files selected for processing (1)
source/_integrations/tesla_fleet.markdown
(2 hunks)
🧰 Additional context used
🪛 LanguageTool
source/_integrations/tesla_fleet.markdown
[grammar] ~142-~142: Make sure that the noun ‘setup’ is correct. Did you mean the past participle “set up”?
Context: ...is is required and the key has not been setup correctly.W Your public key must be ad...
(BE_VB_OR_NN)
🪛 markdownlint-cli2 (0.17.2)
source/_integrations/tesla_fleet.markdown
144-144: Bare URL used
null
(MD034, no-bare-urls)
⏰ Context from checks skipped due to timeout of 90000ms (3)
- GitHub Check: Redirect rules - home-assistant-docs
- GitHub Check: Header rules - home-assistant-docs
- GitHub Check: Pages changed - home-assistant-docs
{% details "Hosting a Public/Private Key Pair with the NGINX Home Assistant SSL proxy Add-on" %} | ||
|
||
With this method, it is assumed that the [NGINX Home Assistant SSL proxy Add-on](https://github.com/home-assistant/addons/blob/master/nginx_proxy/DOCS.md) is running as a reverse proxy for external access to your Home Assistant installation. | ||
|
||
1. **Open an SSH Terminal** on your Home Assistant installation using the [Terminal & SSH Add-on](https://www.home-assistant.io/common-tasks/os#installing-and-using-the-ssh-add-on). | ||
2. During the integration setup, you will be provided your public key. Copy this content to a file at `/share/tesla/.well-known/appspecific/com.tesla.3p.public-key.pem`. | ||
3. Create a **NGINX configuration file** `nginx_proxy_default_tesla.conf` in `/share` with: `echo 'location /.well-known/appspecific/com.tesla.3p.public-key.pem {\n root /share/tesla;\n}' > /share/nginx_proxy_default_tesla.conf` | ||
4. Close the Terminal and go to **Settings** >**Add-Ons** > **NGINX Home Assistant SSL proxy** > Configuration page. Change the `customize.active` option from the default `false` to `true`. Leave the `config.default` option at its default value: `nginx_proxy_default*.conf`. | ||
5. **Restart the NGINX Home Assistant SSL proxy Add-on** on the **Settings** > **Add-Ons** > **NGINX Home Assistant SSL proxy** > **Info** page and test if the public key file is accessible at `https://my.domain.com/.well-known/appspecific/com.tesla.3p.public-key.pem` | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🛠️ Refactor suggestion
Remove or update NGINX proxy hosting instructions to match simplified flow
The detailed step-by-step for the NGINX SSL proxy add-on conflicts with the new config flow where Home Assistant now provides the public key (and QR code) directly during setup. Consider moving these instructions to an optional appendix or noting they’re only needed if you cannot host the key yourself, and reference the integration’s built-in key display. Also tighten formatting (add space in **Settings** > **Add-Ons**
, use fenced code blocks for the echo
command, etc.).
🤖 Prompt for AI Agents
In source/_integrations/tesla_fleet.markdown around lines 81 to 90, the NGINX
proxy hosting instructions are outdated and conflict with the new simplified
integration flow where Home Assistant provides the public key and QR code
directly. Update this section by either removing the detailed step-by-step
instructions or moving them to an optional appendix with a note that they are
only necessary if the user cannot host the key themselves. Also, improve
formatting by adding spaces in "**Settings** > **Add-Ons**" and enclosing the
echo command in fenced code blocks for clarity.
This is going to merge conflict hard at release time |
Proposed change
There has been a lot of comments about how hard the Tesla Fleet setup is since Tesla force me to remove the build in client ID. So many issues are raised due to issues people have with the external prerequisites, and its hard to know where exactly a user has made the mistake.
To address this, the config flow now:
This elimates the need for users to run openssl to generate their own keys and curl or postman to regsiter their application domain. As such these have been removed from the documentation.
Type of change
current
branch).current
branch).next
branch).next
branch).Additional information
Checklist
current
branch.next
branch.Summary by CodeRabbit
Summary by CodeRabbit