Compare commits

..

8 Commits

Author SHA1 Message Date
34175a20bd chore: Set RUST_LOG to something sensible by default when running with cargo
All checks were successful
Build and deploy / build (push) Successful in 10m21s
Build and deploy / Deploy container (push) Successful in 37s
2025-09-05 03:34:51 +02:00
c2ba4ffbb5 feat(config)!: Reworked how configuration is loaded
All checks were successful
Build and deploy / build (push) Successful in 11m1s
Build and deploy / Deploy container (push) Successful in 40s
The environment variable `AUTOMATION_CONFIG` has been renamed to
`AUTOMATION__ENTRYPOINT` and can now also be set in `automation.toml` by
specifying:
```
automation = "<path>"
```

Directly accessing the environment variables in lua in no longer
possible. To pass in configuration or secrets you can now instead make
use of the `variables` and `secrets` modules.

To set values in these modules you can either specify them in
`automation.toml`:
```
[variables]
<name> = <value>

[secrets]
<name> = <value>
```
Note that these values will get converted to a string.

You can also specify the environment variables
`AUTOMATION__VARIABLES__<name>` and `AUTOMATION__SECRETS__<name>` to
set variables and secrets respectively. By adding the suffix `__FILE` to
the environment variable name the contents of a file can be loaded into
the variable or secret.

Note that variables and secrets are identical in functionality and the
name difference exists purely to make it clear that secret values are
meant to be kept secret.
2025-09-05 03:14:44 +02:00
7a9f464e61 feat(config)!: Move new_mqtt_client out of global automation table into separate module
All checks were successful
Build and deploy / build (push) Successful in 10m30s
Build and deploy / Deploy container (push) Successful in 45s
The function `new_mqtt_client` was the last remaining entry in the
global `automation` table. The function was renamed to `new` and placed
in the new `mqtt` module. As `automation` is now empty, it has been
removed.
2025-09-04 04:28:03 +02:00
3d5f6c308c feat(config)!: Move device_manager out of global automation table into separate module
Moved `automation.device_manager` into a separate module called
`device_manager`
2025-09-04 04:28:03 +02:00
c6a6265d6c feat(config)!: Move util out of global automation table into separate module
Move `automation.util` into a separate module called `utils`.
2025-09-04 04:28:02 +02:00
d6816bc693 feat(config)!: Fulfillment config is now returned at the end of the config
Previously the fulfillment config was set by setting
`automation.fulfillment`, this will no longer work in the future when
the global automation gets split into modules.
2025-09-04 04:28:02 +02:00
c8d5df753f style: Sort crates by name 2025-09-04 04:28:02 +02:00
96cb814495 style: Enforce conventional commits formatting 2025-09-04 04:28:02 +02:00

View File

@@ -22,7 +22,7 @@ repos:
hooks:
- id: conventional-pre-commit
stages: [commit-msg]
args: [--verbose]
args: []
- repo: https://github.com/JohnnyMorganz/StyLua
rev: v2.1.0