Add service infrastructure for long-running deployment
- Add configuration system (config/*.exs, OrgGarden.Config) - Refactor supervision tree with DynamicSupervisor and Registry - Add OrgGarden.Server for serve mode lifecycle management - Add health check HTTP endpoints (Bandit/Plug on :9090) - Add telemetry events for export and watcher operations - Implement graceful shutdown with SIGTERM handling - Add Mix Release support with overlay scripts - Add NixOS module for systemd service deployment - Update documentation with service usage
This commit is contained in:
20
mix.exs
20
mix.exs
@@ -8,7 +8,8 @@ defmodule OrgGarden.MixProject do
|
||||
elixir: "~> 1.17",
|
||||
start_permanent: Mix.env() == :prod,
|
||||
deps: deps(),
|
||||
escript: escript()
|
||||
escript: escript(),
|
||||
releases: releases()
|
||||
]
|
||||
end
|
||||
|
||||
@@ -23,12 +24,27 @@ defmodule OrgGarden.MixProject do
|
||||
[main_module: OrgGarden.CLI]
|
||||
end
|
||||
|
||||
defp releases do
|
||||
[
|
||||
org_garden: [
|
||||
include_executables_for: [:unix],
|
||||
applications: [runtime_tools: :permanent],
|
||||
steps: [:assemble, :tar]
|
||||
]
|
||||
]
|
||||
end
|
||||
|
||||
defp deps do
|
||||
[
|
||||
{:finch, "~> 0.19"},
|
||||
{:req, "~> 0.5"},
|
||||
{:jason, "~> 1.4"},
|
||||
{:file_system, "~> 1.0"}
|
||||
{:file_system, "~> 1.0"},
|
||||
# Health check HTTP server
|
||||
{:bandit, "~> 1.0"},
|
||||
{:plug, "~> 1.15"},
|
||||
# Telemetry
|
||||
{:telemetry, "~> 1.0"}
|
||||
]
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user