[{"data":1,"prerenderedAt":4},["ShallowReactive",2],{"docs:\u002Fdocs\u002Freference\u002Fcli":3},"\u003Cp>Every command the bundle registers, under the \u003Ccode>k8s:\u003C\u002Fcode> prefix: rendering to standard output, dumping to files, and scaffolding new classes. How to take the output to a cluster is in \u003Ca href=\"\u002Fdocs\u002Fdeploying\u002Frendering-and-deploying\">Rendering and deploying\u003C\u002Fa>.\u003C\u002Fp>\n\u003Cp>The environment for all of them is Symfony&#39;s: \u003Ccode>APP_ENV=prod bin\u002Fconsole k8s:render:apps\u003C\u002Fcode>.\u003C\u002Fp>\n\u003Ch2 id=\"render-yaml-to-stdout\">\u003Ca class=\"anchor\" href=\"#render-yaml-to-stdout\" aria-label=\"Link to this section\">\u003C\u002Fa>Render: YAML to stdout\u003C\u002Fh2>\n\u003Cdiv class=\"table-wrap\">\u003Ctable>\u003Cthead>\u003Ctr>\u003Cth>Command\u003C\u002Fth>\u003Cth>Arguments\u003C\u002Fth>\u003Cth>Renders\u003C\u002Fth>\u003C\u002Ftr>\u003C\u002Fthead>\u003Ctbody>\u003Ctr>\u003Ctd>\u003Ccode>k8s:render:apps\u003C\u002Fcode>\u003C\u002Ftd>\u003Ctd>\u003Ccode>[apps-aliases…]\u003C\u002Fcode> (default: all)\u003C\u002Ftd>\u003Ctd>App manifests\u003C\u002Ftd>\u003C\u002Ftr>\n\u003Ctr>\u003Ctd>\u003Ccode>k8s:render:helm\u003C\u002Fcode>\u003C\u002Ftd>\u003Ctd>\u003Ccode>[helm-releases…]\u003C\u002Fcode> (default: all)\u003C\u002Ftd>\u003Ctd>Helm releases (adds missing \u003Ccode>helm\u003C\u002Fcode> repos first)\u003C\u002Ftd>\u003C\u002Ftr>\n\u003Ctr>\u003Ctd>\u003Ccode>k8s:render:all\u003C\u002Fcode>: alias \u003Ccode>k8s:render\u003C\u002Fcode>\u003C\u002Ftd>\u003Ctd>:\u003C\u002Ftd>\u003Ctd>everything: Apps first, then releases, one stream\u003C\u002Ftd>\u003C\u002Ftr>\u003C\u002Ftbody>\u003C\u002Ftable>\u003C\u002Fdiv>\n\u003Cp>Output is a multi-document YAML stream, documents joined with \u003Ccode>---\u003C\u002Fcode> and each prefixed by a \u003Ccode># File:\u003C\u002Fcode> comment naming its virtual path (\u003Ccode># File: \u002Fshop\u002Fapi.deployment.yaml\u003C\u002Fcode>). The stream is deterministic and pipe-friendly:\u003C\u002Fp>\n\u003Cfigure class=\"plain\">\u003Cdiv class=\"block-pane\">\u003Cbutton type=\"button\" class=\"copy\" data-copy aria-label=\"Copy the code\">Copy\u003C\u002Fbutton>\u003Cpre class=\"shiki shiki-themes klass8s-light klass8s-dark\" style=\"--k8s-light:#191b2e;--k8s-dark:#e7e9f2;--k8s-light-bg:#fbfbf8;--k8s-dark-bg:#181b33\" tabindex=\"0\">\u003Ccode>\u003Cspan class=\"line\">\u003Cspan style=\"--k8s-light:#1B5C96;--k8s-dark:#92CCFF\">bin\u002Fconsole\u003C\u002Fspan>\u003Cspan style=\"--k8s-light:#0B6B55;--k8s-dark:#86D9BF\"> k8s:render:apps\u003C\u002Fspan>\u003Cspan style=\"--k8s-light:#0B6B55;--k8s-dark:#86D9BF\"> shop\u003C\u002Fspan>\u003Cspan style=\"--k8s-light:#5A5F73;--k8s-dark:#A7ABC0\"> |\u003C\u002Fspan>\u003Cspan style=\"--k8s-light:#1B5C96;--k8s-dark:#92CCFF\"> kubectl\u003C\u002Fspan>\u003Cspan style=\"--k8s-light:#0B6B55;--k8s-dark:#86D9BF\"> diff\u003C\u002Fspan>\u003Cspan style=\"--k8s-light:#9A3D0C;--k8s-dark:#F3A978\"> -f\u003C\u002Fspan>\u003Cspan style=\"--k8s-light:#0B6B55;--k8s-dark:#86D9BF\"> -\u003C\u002Fspan>\u003C\u002Fspan>\u003C\u002Fcode>\u003C\u002Fpre>\u003C\u002Fdiv>\u003C\u002Ffigure>\n\u003Ch2 id=\"dump-yaml-to-files\">\u003Ca class=\"anchor\" href=\"#dump-yaml-to-files\" aria-label=\"Link to this section\">\u003C\u002Fa>Dump: YAML to files\u003C\u002Fh2>\n\u003Cdiv class=\"table-wrap\">\u003Ctable>\u003Cthead>\u003Ctr>\u003Cth>Command\u003C\u002Fth>\u003Cth>Arguments\u003C\u002Fth>\u003Cth>Dumps\u003C\u002Fth>\u003C\u002Ftr>\u003C\u002Fthead>\u003Ctbody>\u003Ctr>\u003Ctd>\u003Ccode>k8s:dump:apps\u003C\u002Fcode>\u003C\u002Ftd>\u003Ctd>\u003Ccode>[apps-aliases…]\u003C\u002Fcode>\u003C\u002Ftd>\u003Ctd>App manifests\u003C\u002Ftd>\u003C\u002Ftr>\n\u003Ctr>\u003Ctd>\u003Ccode>k8s:dump:helm\u003C\u002Fcode>\u003C\u002Ftd>\u003Ctd>\u003Ccode>[helm-releases…]\u003C\u002Fcode>\u003C\u002Ftd>\u003Ctd>Helm releases\u003C\u002Ftd>\u003C\u002Ftr>\n\u003Ctr>\u003Ctd>\u003Ccode>k8s:dump:all\u003C\u002Fcode>: alias \u003Ccode>k8s:dump\u003C\u002Fcode>\u003C\u002Ftd>\u003Ctd>:\u003C\u002Ftd>\u003Ctd>both\u003C\u002Ftd>\u003C\u002Ftr>\u003C\u002Ftbody>\u003C\u002Ftable>\u003C\u002Fdiv>\n\u003Cp>Options (all three):\u003C\u002Fp>\n\u003Cdiv class=\"table-wrap\">\u003Ctable>\u003Cthead>\u003Ctr>\u003Cth>Option\u003C\u002Fth>\u003Cth>Meaning\u003C\u002Fth>\u003C\u002Ftr>\u003C\u002Fthead>\u003Ctbody>\u003Ctr>\u003Ctd>\u003Ccode>-D\u003C\u002Fcode>, \u003Ccode>--output-dir &lt;dir&gt;\u003C\u002Fcode>\u003C\u002Ftd>\u003Ctd>override the configured \u003Ccode>manifests_dir\u003C\u002Fcode>\u003C\u002Ftd>\u003C\u002Ftr>\n\u003Ctr>\u003Ctd>\u003Ccode>-R\u003C\u002Fcode>, \u003Ccode>--recreate-output-dir\u003C\u002Fcode>\u003C\u002Ftd>\u003Ctd>delete and recreate the target env directory first: guarantees no stale files from removed manifests\u003C\u002Ftd>\u003C\u002Ftr>\u003C\u002Ftbody>\u003C\u002Ftable>\u003C\u002Fdiv>\n\u003Cp>The output base is always suffixed with the current environment, then split by origin:\u003C\u002Fp>\n\u003Cfigure class=\"plain\">\u003Cdiv class=\"block-pane\">\u003Cbutton type=\"button\" class=\"copy\" data-copy aria-label=\"Copy the code\">Copy\u003C\u002Fbutton>\u003Cpre class=\"shiki shiki-themes klass8s-light klass8s-dark\" style=\"--k8s-light:#191b2e;--k8s-dark:#e7e9f2;--k8s-light-bg:#fbfbf8;--k8s-dark-bg:#181b33\" tabindex=\"0\">\u003Ccode>\u003Cspan class=\"line\">\u003Cspan>&#x3C;manifests_dir>\u002F&#x3C;env>\u002Fapps\u002F&#x3C;app-alias>\u002F&#x3C;short-name>.&#x3C;kind>.yaml\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>&#x3C;manifests_dir>\u002F&#x3C;env>\u002Fhelm\u002F&#x3C;release>\u002F&#x3C;resource-name>.&#x3C;kind>.yaml\u003C\u002Fspan>\u003C\u002Fspan>\u003C\u002Fcode>\u003C\u002Fpre>\u003C\u002Fdiv>\u003C\u002Ffigure>\n\u003Cp>Kinds are kebab-cased in file names (\u003Ccode>api.deployment.yaml\u003C\u002Fcode>, \u003Ccode>session-prune.cron-job.yaml\u003C\u002Fcode>). The \u003Ccode># File:\u003C\u002Fcode> headers appear only in \u003Cem>rendered\u003C\u002Fem> streams, not in dumped files: dumped YAML is exactly what \u003Ccode>kubectl\u003C\u002Fcode> will see.\u003C\u002Fp>\n\u003Cblockquote>\u003Cp>Without \u003Ccode>-R\u003C\u002Fcode>, dumping never deletes: a manifest you removed from code leaves its old file behind. Use \u003Ccode>-R\u003C\u002Fcode> (or a fresh \u003Ccode>-D\u003C\u002Fcode> target) for anything that feeds a deploy.\u003C\u002Fp>\n\u003C\u002Fblockquote>\n\u003Ch2 id=\"make-scaffolding\">\u003Ca class=\"anchor\" href=\"#make-scaffolding\" aria-label=\"Link to this section\">\u003C\u002Fa>Make: scaffolding\u003C\u002Fh2>\n\u003Cdiv class=\"table-wrap\">\u003Ctable>\u003Cthead>\u003Ctr>\u003Cth>Command\u003C\u002Fth>\u003Cth>Arguments\u003C\u002Fth>\u003Cth>Creates\u003C\u002Fth>\u003C\u002Ftr>\u003C\u002Fthead>\u003Ctbody>\u003Ctr>\u003Ctd>\u003Ccode>k8s:make:app &lt;name&gt;\u003C\u002Fcode>\u003C\u002Ftd>\u003Ctd>App name \u003Cem>without\u003C\u002Fem> the \u003Ccode>App\u003C\u002Fcode> suffix (\u003Ccode>shop\u003C\u002Fcode> → \u003Ccode>ShopApp\u003C\u002Fcode>)\u003C\u002Ftd>\u003Ctd>the App class plus its \u003Ccode>Manifest\u002F\u003C\u002Fcode>, \u003Ccode>Container\u002F\u003C\u002Fcode>, and \u003Ccode>Resources\u002F\u003C\u002Fcode> directories\u003C\u002Ftd>\u003C\u002Ftr>\n\u003Ctr>\u003Ctd>\u003Ccode>k8s:make:manifest &lt;name&gt; [type]\u003C\u002Fcode>\u003C\u002Ftd>\u003Ctd>manifest short name (DNS-subdomain-validated) + kind\u003C\u002Ftd>\u003Ctd>a manifest class in the chosen App\u003C\u002Ftd>\u003C\u002Ftr>\u003C\u002Ftbody>\u003C\u002Ftable>\u003C\u002Fdiv>\n\u003Cp>\u003Ccode>k8s:make:manifest\u003C\u002Fcode> options and behavior:\u003C\u002Fp>\n\u003Cul>\n\u003Cli>\u003Ccode>--app=&lt;alias&gt;\u003C\u002Fcode> selects the target App; omitted, the command asks interactively: as it does for the \u003Ccode>type\u003C\u002Fcode> argument.\u003C\u002Fli>\n\u003Cli>Available kinds out of the box: \u003Ccode>config-map\u003C\u002Fcode>, \u003Ccode>cron-job\u003C\u002Fcode>, \u003Ccode>deployment\u003C\u002Fcode>, \u003Ccode>ingress\u003C\u002Fcode>, \u003Ccode>job\u003C\u002Fcode>, \u003Ccode>secret\u003C\u002Fcode>, \u003Ccode>service\u003C\u002Fcode>. Kinds without a template (StatefulSet, HPA, PVC, RBAC, Gateway API, …) are written by hand: the \u003Ca href=\"\u002Fdocs\u002Freference\u002Fmanifest-types\">manifest types reference\u003C\u002Fa> is the map.\u003C\u002Fli>\n\u003Cli>The generator refuses duplicate short names per kind within an App, and validates the name against Kubernetes&#39; DNS-subdomain rules before writing anything.\u003C\u002Fli>\n\u003C\u002Ful>\n\u003Cp>Scaffolding targets are controlled by \u003Ccode>code_dir\u003C\u002Fcode> and \u003Ccode>namespace_prefix\u003C\u002Fcode> (see the \u003Ca href=\"\u002Fdocs\u002Freference\u002Fconfiguration#locations\">configuration reference\u003C\u002Fa>); the directory is created by the first command that writes there. The commands write a new class next to the App class they find. In a Phaenon project (a \u003Ccode>phaenon.json\u003C\u002Fcode> beside \u003Ccode>composer.json\u003C\u002Fcode>) the App class loads from a compiled output, so the class is written instead as Phaenon, from the templates under \u003Ccode>templates\u002Fphn\u002F\u003C\u002Fcode>, into the source root that output is built from (\u003Ccode>src\u002F\u003C\u002Fcode> for \u003Ccode>.src\u002F\u003C\u002Fcode>), and laid out by the project&#39;s own \u003Ccode>vendor\u002Fbin\u002Fphn fmt\u003C\u002Fcode>; the command&#39;s message names that path. When the formatter fails, the file stays written and the command fails with \u003Ccode>&quot;&lt;file&gt;&quot; was written, but &quot;phn fmt&quot; could not lay it out: …\u003C\u002Fcode> (\u003Ca href=\"\u002Fdocs\u002Fgetting-started\u002Finstallation#write-in-phaenon\">what it writes\u003C\u002Fa>).\u003C\u002Fp>\n\u003Cp>The kind list is extensible: manifest generator \u003Cem>contexts\u003C\u002Fem> are tagged services (\u003Ccode>klass8s.manifest_generator.context\u003C\u002Fcode>), so a platform team can teach \u003Ccode>k8s:make:manifest\u003C\u002Fcode> its own house kinds: e.g. a \u003Ccode>worker\u003C\u002Fcode> type scaffolding your \u003Ccode>AbstractWorkerDeployment\u003C\u002Fcode> subclass.\u003C\u002Fp>\n\u003Ch2 id=\"exit-behavior\">\u003Ca class=\"anchor\" href=\"#exit-behavior\" aria-label=\"Link to this section\">\u003C\u002Fa>Exit behavior\u003C\u002Fh2>\n\u003Cp>Render and dump commands succeed (exit \u003Ccode>0\u003C\u002Fcode>) or fail with an uncaught exception: a missing referenced Secret, an invalid name, a failed \u003Ccode>helm template\u003C\u002Fcode> all abort the render with a stack trace rather than emitting partial output. Make commands print a friendly error and exit \u003Ccode>1\u003C\u002Fcode>. There is deliberately no &quot;best effort&quot; mode: partial manifest streams applied to a cluster are worse than no stream. An App with no manifests renders nothing, without an error.\u003C\u002Fp>\n\u003Ch2 id=\"see-also\">\u003Ca class=\"anchor\" href=\"#see-also\" aria-label=\"Link to this section\">\u003C\u002Fa>See also\u003C\u002Fh2>\n\u003Cul>\n\u003Cli>\u003Ca href=\"\u002Fdocs\u002Fdeploying\u002Frendering-and-deploying\">Rendering &amp; Deploying\u003C\u002Fa>: workflows built on these commands\u003C\u002Fli>\n\u003Cli>\u003Ca href=\"\u002Fdocs\u002Freference\u002Fconfiguration\">Configuration\u003C\u002Fa>: \u003Ccode>manifests_dir\u003C\u002Fcode>, \u003Ccode>code_dir\u003C\u002Fcode>, and friends\u003C\u002Fli>\n\u003C\u002Ful>\n",1794928319759]