Compare commits

..

1 Commits

Author SHA1 Message Date
2523c900bc feat(config)!: Config now returns the mqtt config instead of the client
Some checks failed
Build and deploy / Deploy container (push) Blocked by required conditions
Build and deploy / build (push) Has been cancelled
Instead the client is now created on the rust side based on the config.
Devices that require the mqtt client will now instead need to be
constructor using a function. This function receives the mqtt client.
2025-10-19 04:58:53 +02:00
3 changed files with 4 additions and 2 deletions

View File

@@ -21,5 +21,6 @@ RUN cargo auditable build --release
FROM gcr.io/distroless/cc-debian12:nonroot AS runtime FROM gcr.io/distroless/cc-debian12:nonroot AS runtime
COPY --from=builder /app/target/release/automation /app/automation COPY --from=builder /app/target/release/automation /app/automation
COPY ./config /app/config ENV AUTOMATION__ENTRYPOINT=/app/config.lua
COPY ./config.lua /app/config.lua
CMD [ "/app/automation" ] CMD [ "/app/automation" ]

View File

@@ -1,4 +1,5 @@
local devices = require("automation:devices") local devices = require("automation:devices")
local device_manager = require("automation:device_manager")
local utils = require("automation:utils") local utils = require("automation:utils")
local secrets = require("automation:secrets") local secrets = require("automation:secrets")
local debug = require("automation:variables").debug and true or false local debug = require("automation:variables").debug and true or false

View File

@@ -20,7 +20,7 @@ pub struct Setup {
} }
fn default_entrypoint() -> String { fn default_entrypoint() -> String {
"./config/config.lua".into() "./config.lua".into()
} }
#[derive(Debug, Deserialize, Typed)] #[derive(Debug, Deserialize, Typed)]