- Add explicit cookie to release config to fix missing COOKIE file - Add config/runtime.exs for environment-based configuration - Release now supports runtime environment variables - Binary starts successfully without COOKIE errors Environment variables supported: - SYSTANT_MQTT_HOST, SYSTANT_MQTT_PORT - SYSTANT_MQTT_USERNAME, SYSTANT_MQTT_PASSWORD - SYSTANT_STATS_TOPIC, SYSTANT_COMMAND_TOPIC - SYSTANT_PUBLISH_INTERVAL 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
41 lines
787 B
Elixir
41 lines
787 B
Elixir
defmodule SystemStatsDaemon.MixProject do
|
|
use Mix.Project
|
|
|
|
def project do
|
|
[
|
|
app: :systant,
|
|
version: "0.1.0",
|
|
elixir: "~> 1.18",
|
|
start_permanent: Mix.env() == :prod,
|
|
deps: deps(),
|
|
releases: releases()
|
|
]
|
|
end
|
|
|
|
# Run "mix help compile.app" to learn about applications.
|
|
def application do
|
|
[
|
|
extra_applications: [:logger],
|
|
mod: {Systant.Application, []}
|
|
]
|
|
end
|
|
|
|
# Run "mix help deps" to learn about dependencies.
|
|
defp deps do
|
|
[
|
|
{:tortoise, "~> 0.9.5"},
|
|
{:jason, "~> 1.4"}
|
|
]
|
|
end
|
|
|
|
defp releases do
|
|
[
|
|
systant: [
|
|
include_executables_for: [:unix],
|
|
applications: [runtime_tools: :permanent],
|
|
cookie: "systant-cookie-change-in-production"
|
|
]
|
|
]
|
|
end
|
|
end
|