Documentation
¶
Overview ¶
SPDX-License-Identifier: Apache-2.0 Package compose deterministically maps a docker-compose file into an engine.Spec so the web wizard's "Import a docker-compose file" option can pre-fill the same review form the prompt and manual options land in.
The compose file is authoritative for STRUCTURE (which services exist, which are built from source vs. pulled as infrastructure images, their ports and replica counts) — so this mapping is a pure function with no LLM: what the user already wrote is honored exactly, offline and for free. Compose is silent on semantic ROLE, so the pattern (which drives every trait default) is only a light heuristic that the user corrects in the form. Anything we cannot map cleanly is surfaced as a human-readable note rather than silently dropped or invented — see ToSpec.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ToSpec ¶
ToSpec maps a docker-compose file to an engine.Spec plus notes describing anything that couldn't be mapped cleanly (renamed services, unrecognized images kept as subcharts, dropped extra ports, an all-infrastructure file). It returns an error only when the file can't be parsed or has no services; the drafted spec is intentionally NOT hard-validated (the user edits it in the form before /generate validates).
Types ¶
This section is empty.