ReleaseKit.Manifest (ReleaseKit v0.1.0)

Copy Markdown

Manifest describing a built OTP release artifact.

The manifest is intentionally deployment-tool neutral. It records the release tarball, runtime command, environment hints, and an optional HTTP health check. ReleaseKit writes the external map form as ETF so consumers can inspect it with ordinary BEAM tooling without depending on ReleaseKit at runtime.

Summary

Functions

Builds a manifest struct from normalized options.

Converts a manifest struct to the stable external map stored in ETF files.

Writes a manifest as ETF.

Types

env()

@type env() :: %{clear: %{required(String.t()) => String.t()}, secret: [String.t()]}

health_check()

@type health_check() :: %{path: String.t(), port: pos_integer(), url: String.t()}

runtime()

@type runtime() :: %{command: [String.t()]}

t()

@type t() :: %ReleaseKit.Manifest{
  app: String.t(),
  env: env(),
  format: atom(),
  format_version: pos_integer(),
  health_check: health_check() | nil,
  mix_env: String.t(),
  release: String.t(),
  runtime: runtime(),
  tarball: Path.t(),
  tool: String.t(),
  version: String.t()
}

Functions

new(opts)

@spec new(keyword()) :: t()

Builds a manifest struct from normalized options.

to_external_map(manifest)

@spec to_external_map(t()) :: map()

Converts a manifest struct to the stable external map stored in ETF files.

write!(manifest, path)

@spec write!(t(), Path.t()) :: :ok

Writes a manifest as ETF.