Commit Graph
223 Commits
Author SHA1 Message Date
JakobLichterfeld 274a8ffde9 docs: add NixOS installation guide (#4768)
* docs: add NixOS installation guide

* docs: update changelog

* docs: add reverse proxy configuration for TeslaMate with Caddy

* docs: update NixOS installation guide for secure connection recommendations
2025-05-29 09:22:04 +02:00
Brett AdamsandJakob Lichterfeld 8933d1d187 docs: clarify pricing for Teslemetry (#4705)
* Update Teslemetry

* docs: update changelog

* docs: update changelog

* ci: update typos false positive list

---------

Co-authored-by: Jakob Lichterfeld <jakob-lichterfeld@gmx.de>
2025-05-26 12:59:17 +02:00
Matthias WirtzandJakob Lichterfeld 571ae70b6f feat: use Grafana 12.0.1 (#4756)
* Grafana 12.0.1

* remove workarounds as all supported platforms have 12.0.0 or later

* docs: update changelog

---------

Co-authored-by: Jakob Lichterfeld <jakob-lichterfeld@gmx.de>
2025-05-24 13:16:47 +02:00
Dario Mader 2bbe3aed6d docs: add note on accessory power functionality can prevent car sleep (#4737)
accessory power functionality can prevent
cars from going to sleep even when no
accessory is connected.

Signed-off-by: darox <maderdario@gmail.com>
2025-05-22 19:26:20 +02:00
Iustin PopandJakob Lichterfeld e1e15042a8 docs: improvement to the Debian installation instructions (#4734)
* Slight improvement to the Debian installation instructions

I've managed to do an install on Debian Trixie with most of the required
dependencies from Debian, with the exception of Grafana (which is not)
packaged. As such, I've modified the instructions to reflect this.

It's possible that in the future, TeslaMate will require newer versions,
and these instructions would become outdated. But that's not worse than
the current state, where for example Erlang/Elixir are no longer
available upstream as documented, so better to have two sets of
instructions for redundancy.

* Improve the separate Grafana server explanation

* Rewrap the text

* Further improve the remot grafana URL

* docs: update changelog

---------

Co-authored-by: Jakob Lichterfeld <jakob-lichterfeld@gmx.de>
2025-05-19 09:01:48 +02:00
JakobLichterfeld db68283520 chore: rename branch to main (#4700)
* chore: rename branch to main

* docs: update changelog
2025-04-26 11:06:31 +02:00
Matthias WirtzandJakob Lichterfeld f4cdc6c2b2 feat: use Grafana 11.6.1 to fix issues when using browser locale for date formats (#4662)
* Grafana 11.6.1

* fix #4690

* increase dateTimeAsLocal column width to 210 for en-us locale, remove obsolete config entries

* docs: update changelog

---------

Co-authored-by: Jakob Lichterfeld <jakob-lichterfeld@gmx.de>
2025-04-25 16:24:36 +02:00
Matthias WirtzandJakob Lichterfeld 4b6e5bb559 fix: set $__timezone explicitly in dashboards to ensure truncation is done with respect to the Grafana timezone (#4684)
* set $__timezone explicitly

* convert to grafana timezone before to_char()

* exclude incomplete drives

* exclude incomplete drives in additional places

* docs: update changelog

* style: linter findings

---------

Co-authored-by: Jakob Lichterfeld <jakob-lichterfeld@gmx.de>
2025-04-22 11:45:36 +02:00
Alexandros Sapranidis d835e28888 docs: allow to add energy added to the Home Assistant's Energy tab to measure how much energy each session uses (#4659)
This commit adds the `state_class: total` in the energy sensor that allows to add it in the energy tab to measure how much energy each session consumes.
The value is set to `total` as each charge session does not cumulative increase.
2025-04-15 12:46:25 +02:00
54a4ee8b61 feat: check Postgres version on startup, require 16.7 / 17.3, update earthdistance extension (#4648)
* check postgres version on startup

* update earthdistance to 1.2

* detail postgres requirement

* align additional requirements

* 17 is available on nixpkgs now

* allow upcoming major as well but issue a warning

* style: linter findings

* ci: skip ghcr build for PRs from outside repo (#4660)

* ci: skip ghcr build for PRs from outside repo

* docs: update changelog

* ci: early exit if check paths triggers

* ci: improve ghcr check_if_pr_from_outside_repo logging

* feat:show tpms value to the low pressure tooltip in webview (#4654)

* Added the tpms value to the tooltip

* Update pot files

* mix format

* Revert "mix format"

This reverts commit bbfe5aaa9f.

* style: linter findings

* Update pot files

* docs: update changelog

---------

Co-authored-by: Jakob Lichterfeld <jakob-lichterfeld@gmx.de>

* docs: update changelog

---------

Co-authored-by: Jakob Lichterfeld <jakob-lichterfeld@gmx.de>
Co-authored-by: Nir Klinger <45952578+NirKli@users.noreply.github.com>
2025-04-15 10:53:38 +02:00
JakobLichterfeld 29b5cdb9ed ci(sec): remove pull_request_target workflow triggers to improve sec even further, the downside is that test images are now only created for repo's own PRs (#4637)
* ci(sec): remove pull_request_target workflow triggers to improve sec even further, the downside is that test images are now only created for repo's own PRs

* docs: update changelog
2025-04-06 13:03:30 +02:00
JakobLichterfeld 6e3a5164da docs: show screenshots entry in sidebar (#4602)
* docs: show screenshots entry in sidebar

* docs: add screenshots entry to sidebar
2025-04-04 11:48:18 +02:00
JakobLichterfeld 26c84b124f docs: add Entity Relationship Model section to development documentation (#4586)
* docs: add Entity Relationship Model section to development documentation

* docs: correct spelling in Entity Relationship Model section

* docs: update changelog

* docs: update image path for Entity Relationship Model
2025-03-28 18:25:54 +01:00
JakobLichterfeld fb3eaefc56 docs: enhance TeslaFi import documentation with updated Python script for bulk data export (#4575)
* docs: enhance TeslaFi import documentation with Python script for bulk data export

* docs: update changelog
2025-03-28 18:22:41 +01:00
Matthias Wirtz f3dc81480d docs: fix and rearrange screenshot links (alphabetical) (#4580)
* fix and rearrange links (alphabetical) - add missing ones

* update screenshots

* add info about screenshots to contribution guideline.
2025-03-24 09:21:58 +01:00
Juan Carlos Heredia 499701833b docs: Update projects using TeslaMate (#4573)
* Get file ready for markdown suggestions

* Rearrange projects by name
2025-03-15 09:05:34 +01:00
Juan Carlos Heredia ab47b1471e feat: add Database Information Dashboard (#4578)
* Migrate dashboard from custom repo

* Edit links, tags and grafana plug-in version

* Update comment on Manually fixing data

* Update Index hints

* Rearrange panels and hints

* Update screenshots

* MD Format

* Update screenshots.mdx file

* Format with treefmt
2025-03-09 11:36:00 +01:00
Juan Carlos Heredia fca5fd7921 docs: Update REINDEX notes (#4574)
* Rename file for previews

* Use REINDEX DATABASE and notes when to do it manually table by table

* Rename file to merge in project

* Remove notes of older versions

* Use treefmt to format file
2025-03-03 13:13:14 +01:00
JakobLichterfeld e936ec31b8 docs: add reindexing instructions for database maintenance to improve performance in case of index bloat due to frequent updates or deletions (#4558)
* docs: add reindexing instructions for database maintenance to improve performance in case of index bloat due to frequent updates or deletions

* docs: fix links to use markdown format to fix netlify build

* docs: update changelog

* docs: fix links to use markdown format to fix netlify build
2025-02-28 08:44:36 +01:00
Jakob Lichterfeld 1972584d8f style(docs): fix line length fenced-code-style, no bare url links, multiple whitespaces, alt text, header style 2025-02-23 14:20:57 +01:00
Jakob Lichterfeld 603ff824b0 style(environment_variables): remove multiple whitespaces 2025-02-23 13:49:13 +01:00
Matthias Wirtz 1902dc5d2f feat: Grafana 11.5.0 (#4509) 2025-02-02 09:52:40 +01:00
James BakerandJakob Lichterfeld 21d3b520e1 feat: support accessing PostgreSQL on unix domain sockets (#4456)
* Support configuring teslamate with unix domain sockets for Postgres

* docs

* reorder

* format, cleanup

* style: update environment variables documentation for DATABASE_SOCKET_DIR formatting

---------

Co-authored-by: Jakob Lichterfeld <jakob-lichterfeld@gmx.de>
2025-01-13 17:15:38 +01:00
Long Zheng 95dbb9017e doc: Simplify Home Assistant sensors, add device_class to allow changing measurement units (#4472) 2025-01-06 11:42:07 +01:00
JakobLichterfeld 761a7a6398 Revert "doc: Fixing typo for sensor psi calculation (#4470)" (#4479)
This reverts commit 33ca94a273.
2025-01-06 11:41:38 +01:00
Pierre Lempérière 33ca94a273 doc: Fixing typo for sensor psi calculation (#4470)
The psi sensors were not referencing the correct sensor for their calculation.
2025-01-06 11:38:15 +01:00
Matthias Wirtz f0d146661b docs: Grafana 11.4 for manual install on FreeBSD (#4474) 2025-01-06 11:30:48 +01:00
Beme99andJakob Lichterfeld c642e2de86 doc: added missing topic "charging_state" in mqtt doc (#4466)
* Update mqtt.md

Added "charging_state" in mqtt doc

* style: linter findings

---------

Co-authored-by: Jakob Lichterfeld <jakob-lichterfeld@gmx.de>
2025-01-04 13:28:07 +01:00
Matthias Wirtz fdbf76c741 align node req with what is used in CI (#4430) 2024-12-09 11:11:09 +01:00
Matthias Wirtz 1416165147 bump elixir based on availability (#4431) 2024-12-09 11:09:27 +01:00
Matthias Wirtz 38cca3ce7c feat: Update Grafana to 11.4.0 (#4299)
* Grafana 11.4.0

* clean up annotations json

* small consistency improvements
2024-12-08 06:55:41 +01:00
Kursat Aktas 74c6a66a02 docs: Introducing TeslaMate Guru on Gurubase.io (#4390)
* Introducing TeslaMate Guru on Gurubase.io

Signed-off-by: Kursat Aktas <kursat.ce@gmail.com>

* TeslaMate Guru section added to projects.md

* guru badge removed from the README

---------

Signed-off-by: Kursat Aktas <kursat.ce@gmail.com>
2024-11-20 09:09:53 +01:00
Long Zheng 2a6ecb3426 docs: Remove availability from Home Assistant MQTT sensors, as it can be misleading and prevent sensors from receiving updated values (#4362) 2024-11-07 10:33:50 +01:00
JakobLichterfeld 31c082a69b docs: update Home Assistant integration documentation with configuration URL and model name hints (#4359)
* feat: add CONTRIBUTING file to exclusion lists for treefmt

* docs: update Home Assistant integration documentation with configuration URL and model name hints

* docs: update changelog

* docs: improve Home Assistant integration documentation with additional configuration details and clarifications

* docs: update Home Assistant integration documentation with placeholders for car model and name

* docs: move car ID configuration details to the Configuration section in Home Assistant integration documentation
2024-11-06 15:50:05 +01:00
Matthias Wirtz 10217dabbe Grafana 11.2.3 2024-11-05 15:20:35 +01:00
JakobLichterfeld cfaa4b8915 fix: use elixir-1.17.3-otp-26 to avoid beam.smp chewing CPU on arm (#4319)
* fix: use elixir-1.17.3-otp-26 to avoid beam.smp chewing CPU on arm

fixes: #4307

* docs: update changelog
2024-10-29 18:59:27 +01:00
Matthias Wirtz bfe5e171aa fix image path (#4309) 2024-10-28 09:18:02 +01:00
dependabot[bot]dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>Jakob Lichterfeld
1b89ae7fd3 build(deps): bump elixir from 1.16.2-otp-26 to 1.17.2-otp-27 (#4296)
* build(deps): bump elixir from 1.16.2-otp-26 to 1.17.2-otp-27

Bumps elixir from 1.16.2-otp-26 to 1.17.2-otp-27.

---
updated-dependencies:
- dependency-name: elixir
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

* build(deps): bump elixir from 1.16.2-otp-26 to 1.17.2-otp-27 in workflow, flake and docs

* docs: update changelog

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Jakob Lichterfeld <jakob-lichterfeld@gmx.de>
2024-10-23 11:27:20 +02:00
Matthias WirtzandJakob Lichterfeld 93fb64e846 docs: add best practice section to contribution guide (#4288)
* add some notes about db performance to contribution guide

* add docs for usage of timestamp columns

* format prettier

* fix: remove unneeded apostrophe

---------

Co-authored-by: Jakob Lichterfeld <jakob-lichterfeld@gmx.de>
2024-10-21 16:04:13 +02:00
JakobLichterfeld c87b8976c3 docs: add recommended RAM size (#4278)
* docs: add recommended RAM size

* docs: update changelog
2024-10-19 16:22:55 +02:00
Long Zheng 123f7ab63c docs: fix Home Assistant MQTT sensor JSON templates warnings (#4257)
* Fix Home Assistant active route MQTT sensor JSON templates

More gracefully handles JSONs with error (not actively routing)

* Fix tesla_active_route_distance_to_arrival_km sensor

* Fix template sensors

Conditionally convert values if the sensor actually has a value, to prevent converting invalid non-numeric values

* Fix copy/paste mistakes
2024-10-19 15:51:28 +02:00
JakobLichterfeldandscottbot95 fdf8185ce2 ci: add treefmt as code formatting multiplexer, refactor CI to avoid duplication, reorg CI into DevOps workflow (#4219)
* ci: add treefmt as code formatting multiplexer

* style: linter findings in entrypoint.sh script

* style: linter findings for yaml and yml

* style: linter findings for json files

* style: linter findings for nix files

* style: linter findings for js files

* style: linter findings for dashboards.sh

* style: linter findings for md and mdx files

* chore: remove unused clang formatter in treefmt config

* style: linter findings for mdx files

* ci: exclude Grafana dashboard JSON files from prettier formatting

* Revert "style: linter findings for json files"

This reverts commit f40c2e1759.

* ci: exclude Grafana dashboard JSON files from all formatting as we use the grafana export style

* style: linter findings for json files

* doc: update changelog

* ci(refactor): use composite action to avoid duplication in elixir workflow

* doc: update changelog

* ci: prevent workflow runs for certain conditions and allow scheduled runs

* ci(refactor): use reusable workflow to check paths

* ci(fix): correct output syntax for check_paths workflow and setting base branch

* ci(refactor): use reusable workflows for streamlined DevOps pipeline

* ci(fix): add write permission for packages in DevOps workflow

* ci(test): test DevOps workflow

* ci(test): test DevOps workflow

* ci(fix): Update condition for spell_check, ensure_linting, elixir, and ghcr_build workflows to reflect empty result instead of false

* ci: revert test DevOps

* ci(refactor): allow ghcr_build parallel to elixir test

* ci(refactor): Remove redundant check_paths job from elixir.yml, elixir_test.yml, and spell_check.yml workflows, check is done in devops.yml

* feat: add treefmt-nix to nix flake (#4219 - @JakobLichterfeld)

* ci: ensure proper linting via treefmt

* ci(test): test ensure_linting workflow

* ci(fix): checkout code for spell_checker to access file to check

* ci(fix): allow impure in ensure_linting workflow

* Revert "ci(test): test ensure_linting workflow"

This reverts commit a67b17ec09.

* ci(fix): correct use of flake-utils for formatter and checks

Co-authored-by: scottbot95 <scottbot95@gmail.com>

* ci(fix): correct use of flake-utils for treefmt

Co-authored-by: scottbot95 <scottbot95@gmail.com>

* refactor: Remove unnecessary imports in flake

* ci(fix): correct syntax in flake

* ci(refactor): Remove unused code in flake.nix

* style: standardised style for input url in flake

* ci(fix): treefmt-nix config with existing options

* ci(feat): Add Nix binary cache and update treefmt command in CI workflow

* ci(refactor): Remove unused code in flake.nix

* fix: include devShell packages only on supported platforms

* fix: update hash for mix-deps package in flake.nix

* ci(fix): Update treefmt command in CI workflow

* ci(test): test ensure_linting workflow

* feat: ensure mix deps are present in devShell

* ci(feat): use flake-parts to enable treefmt-nix

* feat: use flake-parts

* fix: correct use of flake-parts for package build

* doc: update CI badge URL for devops workflow

* ci(fix): handle empty path filter output

* ci: remove --impure flag from treefmt command in CI workflow

* fix: correct treefmt.config settings in formatter.nix

* fix: correct flake-parts inputs, avoid with in imports

* fix: correct program name for mix-format in formatter.nix

* feat: devenv via flake-parts

* fix: correct use of legacy nix code with flake-parts

* ci(fix): correct nix develop command in ensure_linting.yml

* refactor: list imports explicitly in flake, rename folder to flake-modules to be precise

* style: use tabs for indent size to format sh

* style: use nixfmt-rfc-style

* Revert "style: use nixfmt-rfc-style"

This reverts commit 082056159e.

* style: use nixfmt style

* fix: remove glibcLocales from optional dependencies to avoid  "A definition for option `packages."[definition 4-entry 16]"' is not of type `package'."

* fix: remove inotify-tools from optional dependencies to avoid  "A definition for option `packages."[definition 4-entry 16]"' is not of type `package'."

* fix: Remove inotify-tools and glibcLocales from optional dependencie

* fix: correct file paths in flake.nix to version

* fix: add ELIXIR_ERL_OPTIONS to shell environment to force utf8 locale

* fix: add LOCALE_ARCHIVE to shell environment in flake.nix

* Revert "fix: add LOCALE_ARCHIVE to shell environment in flake.nix"

This reverts commit d45f6e32ee.

* ci(refactor): rename workflow to elixir_dep_verification_and_static_analysis.yml to better reflect the intention,, remove duplicate checks

* ci(debug): debug locale settings

* Revert "ci(debug): debug locale settings"

This reverts commit 9b402f3c5f.

* Revert "fix: add ELIXIR_ERL_OPTIONS to shell environment to force utf8 locale"

This reverts commit d02419cba4.

* fix: add LOCALE_ARCHIVE to shell environment in flake.nix

* Revert "fix: add LOCALE_ARCHIVE to shell environment in flake.nix"

This reverts commit 761b437e69.

* fix: add LANG=C.UTF-8 to shell environment in flake.nix

* fix: add mix local.rebar and mix local.hex commands to flake.nix

* fix: pin devenv to version without unix socket bug

* chore: update nixpkgs to nixos-24.05 and update dependencies

* doc: add treefmt config comments

* ci: do not expose treefmt formatter programs in devshell

* fix: correct use of module option to enable PostgreSQL server in flake.nix

* Revert "chore: update nixpkgs to nixos-24.05 and update dependencies"

This reverts commit a6ea3f25aa.

* feat: consistent use of erlang 26 and elixir 1_16 in flake

* ci: switch to macOS runner for linting workflow

* Revert "ci: do not expose treefmt formatter programs in devshell"

This reverts commit 1ecfa451dc.

* Revert "ci: switch to macOS runner for linting workflow"

This reverts commit 7b430667d8.

* ci: Remove nixpkgs channel specification in ensure_linting workflow

* ci(debug): Add debug output for PATH and NIX_PATH in flake.nix

* Revert "ci(debug): Add debug output for PATH and NIX_PATH in flake.nix"

This reverts commit 07faec5ddf.

* fix: avoid the need for impure for devenv

see #4245

* fix: remove invalid custom build.check for formatter and use default

* style: linter findings

* fix: Add emptyTest to avoid nix flake check test execution on non-Linux systems

* chore: Remove LANG=C.UTF-8 from enterShell in flake.nix

* ci(fix): Remove --impure flag from treefmt command in CI mode

* ci(fix): avoid impure mode in ensure_linting workflow

* style: linter findings

* ci(debug): debug elixir version and locale

* chore: Update flake.lock dependencies

* feat: use newer devenv as unix socket bug is fixed in upstream

https://github.com/cachix/devenv/issues/1497

* fix: set rebar3 path in devenv

* Revert "ci(debug): debug elixir version and locale"

This reverts commit 7ecdc77c16.

* ci: re-enable path check in DevOps workflow

* doc: update Development and Contributing guide with nix and treefmt

* ci: use PostgreSQL 17

* style: linter findings

* ci(fix): ensure cache name in build action does not contain invalid characters to avoid invalid reference format

* doc: update changelog

* Revert "ci(fix): ensure cache name in build action does not contain invalid characters to avoid invalid reference format"

This reverts commit 02abb0359d.

* ci: remove branch restriction for check_paths workflow to increase sec

* ci(fix): run ghcr build workflow only for specific conditions

- Ensure workflow only run if there are no changes to the .github folder
- Allow workflow to run on workflow call or PRs from forks
- Prevent duplicate runs for PRs from non-forks
- Avoid invalid reference format for cache name in PRs from our repository

* doc: update changelog

* fix: update hash for mix-deps package in flake.nix

* fix: disable flakeCheck for formatter, as mix format need the dep to be fetched beforehand

* ci(fix): run ghcr build workflow only for specific conditions

* fix: move nixosModules.default to top-level attribute set

* refactor: remove unnecessary config nesting in formatter.nix

* ci(fix): ensure version for buildx is set to correct name

---------

Co-authored-by: scottbot95 <scottbot95@gmail.com>
2024-10-14 08:54:10 +02:00
Matthias Wirtz c67573e708 feat: PostgreSQL 17 (#4231) 2024-09-29 11:17:31 +02:00
JakobLichterfeld fedb206f50 doc: clarify using fleet api has lots of drawbacks (#4173)
* doc: fix markdownlint warnings in fleet api documentation

* doc: update changelog

* doc: clarify using fleet api has lots of drawbacks
2024-08-31 16:32:15 +02:00
Juan Carlos Heredia cdd489fb53 doc: Update screenshots and rearrange links (#4151) 2024-08-22 18:25:57 +02:00
Herman van Rink 94da8f6d92 doc: align TPMS Pressure naming in sensor config to match ui config for home assistant (#4104) 2024-07-29 11:14:55 +02:00
yangiakandYangkai Lyu 92baa5a330 doc: add steps to the guide regarding how to switch to Fleet API (#4103)
* Added steps to the guide regarding how to switching from Owners API to Fleet API from my experience

* minor heading change adopted

---------

Co-authored-by: Yangkai Lyu <lyk119@gmail.com>
2024-07-28 09:21:19 +02:00
JakobLichterfeld a36610e2bd build: update website dependencies, doc: fix markdown linter warnings in faq (#4046)
* chore: update @docusaurus/core and @docusaurus/preset-classic dependencies to v3.4.0

* Revert "chore: update @docusaurus/core and @docusaurus/preset-classic dependencies to v3.4.0"

This reverts commit d5b38711a1.

* chore: npm audit fix

* chore: update @docusaurus/core and @docusaurus/preset-classic dependencies to v3.4.0 and react and react-dom to 18.3.1

* build: specify node.js version for Netlify

* doc: fix markdown linter warnings to trigger new Netlify build

* build: specify node.js version for Netlify in base dir

* doc: update changelog

* build: specify node.js version for Netlify in base dir as major version

* build: specify node.js version for Netlify in base dir as latest lts major version

* doc: update changelog
2024-07-06 15:15:14 +02:00
JakobLichterfeld 4a32f6eb28 doc: fix typo in MQTT location JSON format (#4047)
* doc: fix typo in MQTT location JSON format

* doc: fix typo in MQTT location JSON format
2024-07-06 14:47:13 +02:00
Atrox 21439f1a14 publish center_display_state to mqtt (#3813) 2024-07-05 16:55:03 +02:00