{"id":314193,"date":"2020-12-02T15:02:07","date_gmt":"2020-12-02T15:02:07","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=314193"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=314193","title":{"rendered":"\u041f\u0440\u043e\u0434\u0432\u0438\u043d\u0443\u0442\u0430\u044f Helm-\u0448\u0430\u0431\u043b\u043e\u043d\u0438\u0437\u0430\u0446\u0438\u044f: \u0432\u044b\u0436\u0438\u043c\u0430\u0435\u043c \u043c\u0430\u043a\u0441\u0438\u043c\u0443\u043c"},"content":{"rendered":"\n<div class=\"post__text post__text-html post__text_v1\" id=\"post-content-body\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/ci\/cl\/mk\/ciclmkkss_ijl1_dbsjfv6brgmo.png\"><\/p>\n<p>  \u0421\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u043e\u0439 Helm-\u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 \u0438 \u043f\u0440\u0438\u0432\u044b\u0447\u043d\u044b\u0445 \u043f\u043e\u0434\u0445\u043e\u0434\u043e\u0432 \u043a \u043d\u0430\u043f\u0438\u0441\u0430\u043d\u0438\u044e Helm-\u0447\u0430\u0440\u0442\u043e\u0432 \u043e\u0431\u044b\u0447\u043d\u043e \u0445\u0432\u0430\u0442\u0430\u0435\u0442 \u0434\u043b\u044f \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0437\u0430\u0446\u0438\u0438 \u043d\u0435\u0441\u043b\u043e\u0436\u043d\u044b\u0445 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0439. \u041d\u043e \u043a\u043e\u0433\u0434\u0430 \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e \u0438 \u0441\u043b\u043e\u0436\u043d\u043e\u0441\u0442\u044c Helm-\u0447\u0430\u0440\u0442\u043e\u0432 \u0440\u0430\u0441\u0442\u0443\u0442, \u0442\u043e \u043c\u0438\u043d\u0438\u043c\u0430\u043b\u0438\u0441\u0442\u0438\u0447\u043d\u044b\u0445 Go-\u0448\u0430\u0431\u043b\u043e\u043d\u043e\u0432 \u0438 \u043d\u0435\u043e\u0434\u043d\u043e\u0437\u043d\u0430\u0447\u043d\u043e\u0439 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u043e\u0439 Helm-\u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 \u0431\u044b\u0441\u0442\u0440\u043e \u043f\u0435\u0440\u0435\u0441\u0442\u0430\u0451\u0442 \u0445\u0432\u0430\u0442\u0430\u0442\u044c. \u0412 \u044d\u0442\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0435 \u0440\u0435\u0447\u044c \u043f\u043e\u0439\u0434\u0435\u0442 \u043e \u0442\u043e\u043c, \u043a\u0430\u043a \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0432\u0430\u0448\u0438 Helm-\u0448\u0430\u0431\u043b\u043e\u043d\u044b \u0433\u043e\u0440\u0430\u0437\u0434\u043e \u0431\u043e\u043b\u0435\u0435 \u0433\u0438\u0431\u043a\u0438\u043c\u0438 \u0438 \u0434\u0438\u043d\u0430\u043c\u0438\u0447\u043d\u044b\u043c\u0438, \u0440\u0435\u0430\u043b\u0438\u0437\u0443\u044f \u0441\u0432\u043e\u0438 \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u0435 \u00ab\u0444\u0443\u043d\u043a\u0446\u0438\u0438\u00bb \u0432 Helm, \u0430 \u0442\u0430\u043a\u0436\u0435 \u044d\u043a\u0441\u043f\u043b\u0443\u0430\u0442\u0438\u0440\u0443\u044f <code>tpl<\/code>.<\/p>\n<p>  <i><b>NB<\/b>. \u0412\u0441\u0451 \u043e\u043f\u0438\u0441\u0430\u043d\u043d\u043e\u0435 \u0431\u044b\u043b\u043e \u043f\u0440\u043e\u0432\u0435\u0440\u0435\u043d\u043e \u0441 <a href=\"https:\/\/ru.werf.io\/\">werf<\/a>, \u043d\u043e \u0442\u0430\u043a \u043a\u0430\u043a \u0448\u0430\u0431\u043b\u043e\u043d\u044b \u0432 \u044d\u0442\u043e\u0439 \u0443\u0442\u0438\u043b\u0438\u0442\u0435 \u043f\u0440\u0430\u043a\u0442\u0438\u0447\u0435\u0441\u043a\u0438 \u0438\u0434\u0435\u043d\u0442\u0438\u0447\u043d\u044b Helm-\u0448\u0430\u0431\u043b\u043e\u043d\u0430\u043c, \u0442\u043e \u0438 \u0432\u0441\u0451 \u043d\u0438\u0436\u0435\u043f\u0440\u0438\u0432\u0435\u0434\u0435\u043d\u043d\u043e\u0435 \u0431\u0443\u0434\u0435\u0442 \u043f\u043e\u043b\u043d\u043e\u0441\u0442\u044c\u044e \u0438\u043b\u0438 \u043f\u043e\u0447\u0442\u0438 \u043f\u043e\u043b\u043d\u043e\u0441\u0442\u044c\u044e \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u0438\u043c\u043e \u0441 \u043e\u0431\u044b\u0447\u043d\u044b\u043c Helm \u043e\u0431\u0435\u0438\u0445 \u0432\u0435\u0440\u0441\u0438\u0439 (v2 \u0438 v3).<\/i><\/p>\n<p>  \u0410 \u0442\u0435\u043f\u0435\u0440\u044c \u0440\u0430\u0437\u0431\u0435\u0440\u0435\u043c, \u043a\u0430\u043a \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u043e\u0442 Helm-\u0448\u0430\u0431\u043b\u043e\u043d\u043e\u0432 \u0432\u0441\u0451, \u0447\u0442\u043e \u043c\u043e\u0436\u043d\u043e\u2026 \u0438 \u0434\u0430\u0436\u0435 \u0432\u0441\u0451, \u0447\u0442\u043e \u043d\u0435\u043b\u044c\u0437\u044f!<a name=\"habracut\"><\/a><\/p>\n<h2>1. Include\/define-\u0448\u0430\u0431\u043b\u043e\u043d\u044b \u043a\u0430\u043a \u043f\u043e\u043b\u043d\u043e\u0446\u0435\u043d\u043d\u044b\u0435 \u0444\u0443\u043d\u043a\u0446\u0438\u0438<\/h2>\n<p>  \u0412 Helm-\u0447\u0430\u0440\u0442\u0430\u0445 \u0440\u0435\u0433\u0443\u043b\u044f\u0440\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u0444\u0443\u043d\u043a\u0446\u0438\u044f <code>define<\/code> \u0434\u043b\u044f \u0442\u043e\u0433\u043e, \u0447\u0442\u043e\u0431\u044b \u0432\u044b\u043d\u043e\u0441\u0438\u0442\u044c \u0447\u0430\u0441\u0442\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c\u044b\u0435 \u0447\u0430\u0441\u0442\u0438 \u0448\u0430\u0431\u043b\u043e\u043d\u043e\u0432 \u0432 \u043e\u0434\u043d\u043e \u043e\u0431\u0449\u0435\u0435 \u043c\u0435\u0441\u0442\u043e. \u0412 \u0431\u043e\u043b\u044c\u0448\u0438\u043d\u0441\u0442\u0432\u0435 \u0441\u043b\u0443\u0447\u0430\u0435\u0432 \u043f\u0440\u0438\u043c\u0435\u043d\u0435\u043d\u0438\u0435 <code>define<\/code> (\u0438 \u0441\u043e\u043f\u0443\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0435\u0433\u043e \u0435\u0439 <code>include<\/code>) \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0438\u0432\u0430\u0435\u0442\u0441\u044f \u0432\u044b\u043d\u0435\u0441\u0435\u043d\u0438\u0435\u043c \u0432 define&#8217;\u044b \u043f\u0440\u043e\u0441\u0442\u044b\u0445 \u0444\u0440\u0430\u0433\u043c\u0435\u043d\u0442\u043e\u0432 \u0448\u0430\u0431\u043b\u043e\u043d\u043e\u0432: \u0430\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u0439, \u043b\u0435\u0439\u0431\u043b\u043e\u0432, \u0438\u043c\u0435\u043d \u0440\u0435\u0441\u0443\u0440\u0441\u043e\u0432.<\/p>\n<p>  \u041d\u0430 \u0441\u0430\u043c\u043e\u043c \u0436\u0435 \u0434\u0435\u043b\u0435 define&#8217;\u044b \u043c\u043e\u0436\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0435\u0449\u0451 \u0438 \u043a\u0430\u043a \u043f\u043e\u043b\u043d\u043e\u0446\u0435\u043d\u043d\u044b\u0435 \u0444\u0443\u043d\u043a\u0446\u0438\u0438, \u044d\u0444\u0444\u0435\u043a\u0442\u0438\u0432\u043d\u043e \u0430\u0431\u0441\u0442\u0440\u0430\u0433\u0438\u0440\u0443\u044f \u0437\u0430 \u043d\u0438\u043c\u0438 \u043d\u0430\u0448\u0443 \u043b\u043e\u0433\u0438\u043a\u0443.<\/p>\n<h3>1.1. \u041f\u0435\u0440\u0435\u0434\u0430\u0447\u0430 \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u043e\u0432<\/h3>\n<p>  \u0425\u043e\u0442\u044f <code>include<\/code> \u043f\u0440\u0438\u043d\u0438\u043c\u0430\u0435\u0442 \u0442\u043e\u043b\u044c\u043a\u043e \u043e\u0434\u0438\u043d \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442, \u043d\u0438\u0447\u0442\u043e \u043d\u0435 \u043c\u0435\u0448\u0430\u0435\u0442 \u043f\u0440\u043e\u0431\u0440\u043e\u0441\u0438\u0442\u044c \u0441\u043f\u0438\u0441\u043e\u043a \u0441 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u0438\u043c\u0438 \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u0430\u043c\u0438:<\/p>\n<pre><code class=\"go\">{{- include &quot;testFunc&quot; (list $val1 $val2) }}<\/code><\/pre>\n<p>  \u2026 \u0438 \u043f\u043e\u0442\u043e\u043c, \u0432\u043d\u0443\u0442\u0440\u0438 \u0448\u0430\u0431\u043b\u043e\u043d\u0430, \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u044b \u0432\u043e\u0442 \u0442\u0430\u043a:<\/p>\n<pre><code class=\"go\">{{- define &quot;testFunc&quot; }}   {{- $arg1 := index . 0 }}   {{- $arg2 := index . 1 }} <\/code><\/pre>\n<p>  \u041f\u043e\u043b\u043d\u044b\u0439 \u043f\u0440\u0438\u043c\u0435\u0440:<\/p>\n<pre><code class=\"go\">{{- define &quot;testFunc&quot; }}   {{- $arg1 := index . 0 }}   {{- $arg2 := index . 1 }}    # \u041e\u0431\u044a\u0435\u0434\u0438\u043d\u0438\u043c \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u044b \u0432 \u043e\u0434\u043d\u0443 \u0441\u0442\u0440\u043e\u043a\u0443 \u0438 \u0432\u0435\u0440\u043d\u0435\u043c \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442:   {{ print $arg1 $arg2 }} {{- end }}  --- {{- $val1 := &quot;foo&quot; }} {{- $val2 := &quot;bar&quot; }}  {{- include &quot;testFunc&quot; (list $val1 $val2) }} #   ==&gt; string &quot;foobar&quot; <\/code><\/pre>\n<p>  <\/p>\n<h3>1.2. \u041f\u0435\u0440\u0435\u0434\u0430\u0447\u0430 \u0442\u0435\u043a\u0443\u0449\u0435\u0433\u043e \u0438 \u0433\u043b\u043e\u0431\u0430\u043b\u044c\u043d\u043e\u0433\u043e \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442\u0430<\/h3>\n<p>  \u0413\u043b\u043e\u0431\u0430\u043b\u044c\u043d\u044b\u0439 \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442 (<code>$<\/code>) \u2014 \u0441\u043b\u043e\u0432\u0430\u0440\u044c, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0432 \u0441\u0435\u0431\u0435 \u0432\u0441\u0435 <a href=\"https:\/\/helm.sh\/docs\/chart_template_guide\/builtin_objects\/\">\u0432\u0441\u0442\u0440\u043e\u0435\u043d\u043d\u044b\u0435 \u043e\u0431\u044a\u0435\u043a\u0442\u044b<\/a>, \u0432 \u0442\u043e\u043c \u0447\u0438\u0441\u043b\u0435 \u043e\u0431\u044a\u0435\u043a\u0442 <code>Values<\/code>. \u0422\u0435\u043a\u0443\u0449\u0438\u0439 \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442 (<code>.<\/code>) \u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442 \u043d\u0430 \u0433\u043b\u043e\u0431\u0430\u043b\u044c\u043d\u044b\u0439 \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442, \u043d\u043e \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c \u043c\u043e\u0436\u0435\u0442 \u043c\u0435\u043d\u044f\u0442\u044c, \u043d\u0430 \u043a\u0430\u043a\u0443\u044e \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u0443\u044e \u0442\u0435\u043a\u0443\u0449\u0438\u0439 \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442 \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442.<\/p>\n<p>  \u0412\u043d\u0443\u0442\u0440\u0438 \u0448\u0430\u0431\u043b\u043e\u043d\u0430 \u0442\u0435\u043a\u0443\u0449\u0438\u043c (\u0438 \u0433\u043b\u043e\u0431\u0430\u043b\u044c\u043d\u044b\u043c) \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442\u043e\u043c \u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u0441\u044f \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442, \u043f\u0435\u0440\u0435\u0434\u0430\u043d\u043d\u044b\u0439 \u0432 <code>include<\/code>, \u0432 \u043d\u0430\u0448\u0435\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u2014 \u0441\u043f\u0438\u0441\u043e\u043a \u0438\u0437 \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u043e\u0432. \u041d\u043e \u0442\u0430\u043a\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c \u0432\u043d\u0443\u0442\u0440\u0438 \u0448\u0430\u0431\u043b\u043e\u043d\u0430 \u043d\u0430\u043c \u0442\u0435\u043f\u0435\u0440\u044c \u043d\u0438\u0447\u0435\u0433\u043e \u043a\u0440\u043e\u043c\u0435 \u0441\u043f\u0438\u0441\u043a\u0430 \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u043e\u0432 \u043d\u0435 \u0434\u043e\u0441\u0442\u0443\u043f\u043d\u043e, \u0434\u0430\u0436\u0435 $.Values. \u0418\u0441\u043f\u0440\u0430\u0432\u0438\u0442\u044c \u044d\u0442\u043e \u043c\u043e\u0436\u043d\u043e, \u043f\u0435\u0440\u0435\u0434\u0430\u0432 \u0447\u0435\u0440\u0435\u0437 \u0441\u043f\u0438\u0441\u043e\u043a \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u043e\u0432 \u0442\u0430\u043a\u0436\u0435 \u0438 \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442\u044b:<\/p>\n<pre><code class=\"go\">{{- include &quot;testFunc&quot; (list $ . $arg) }}<\/code><\/pre>\n<p>  \u0422\u0435\u043f\u0435\u0440\u044c \u043e\u0441\u0442\u0430\u0451\u0442\u0441\u044f \u0432\u043e\u0441\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u0433\u043b\u043e\u0431\u0430\u043b\u044c\u043d\u044b\u0439 \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0431\u044b\u043b \u0437\u0430 \u043f\u0440\u0435\u0434\u0435\u043b\u0430\u043c\u0438 include&#8217;\u0430, \u0447\u0442\u043e\u0431\u044b \u043a \u043d\u0435\u043c\u0443 \u0441\u043d\u043e\u0432\u0430 \u043c\u043e\u0436\u043d\u043e \u0431\u044b\u043b\u043e \u043e\u0431\u0440\u0430\u0449\u0430\u0442\u044c\u0441\u044f \u0447\u0435\u0440\u0435\u0437 <code>$<\/code>:<\/p>\n<pre><code class=\"go\">{{- define &quot;testFunc&quot; }}   {{- $ := index . 0 }} <\/code><\/pre>\n<p>  \u2026 \u0430 \u0442\u0430\u043a\u0436\u0435 \u0432\u043e\u0441\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u0442\u0435\u043a\u0443\u0449\u0438\u0439 \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442, \u0447\u0442\u043e\u0431\u044b \u043e\u0431\u0440\u0430\u0449\u0430\u0442\u044c\u0441\u044f \u043a \u043d\u0435\u043c\u0443, \u043a\u0430\u043a \u0438 \u0440\u0430\u043d\u044c\u0448\u0435, \u0447\u0435\u0440\u0435\u0437 \u0442\u043e\u0447\u043a\u0443:<\/p>\n<pre><code class=\"go\">  {{- with index . 1 }}<\/code><\/pre>\n<p>  \u0412 \u043a\u043e\u043d\u0435\u0447\u043d\u043e\u043c \u0438\u0442\u043e\u0433\u0435 \u0432\u0441\u0451 \u0431\u0443\u0434\u0435\u0442 \u0432\u044b\u0433\u043b\u044f\u0434\u0435\u0442\u044c \u0442\u0430\u043a:<\/p>\n<pre><code class=\"go\">.helm\/values.yaml: ------------------------------------------------------------- key: &quot;value&quot;  ------------------------------------------------------------- .helm\/templates\/testFunc.yaml: ------------------------------------------------------------- {{- define &quot;testFunc&quot; }}   {{- $ := index . 0 }}   {{- $stringArg := index . 2 }}    {{- with index . 1 }}     # \u0418 \u0432\u043e\u0442 \u043c\u044b \u0438\u043c\u0435\u0435\u043c \u0434\u043e\u0441\u0442\u0443\u043f \u043a &quot;\u0440\u0435\u0430\u043b\u044c\u043d\u044b\u043c&quot; \u0433\u043b\u043e\u0431\u0430\u043b\u044c\u043d\u043e\u043c\u0443     # \u0438 \u043e\u0442\u043d\u043e\u0441\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u043c\u0443 \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442\u0430\u043c, \u043f\u0440\u044f\u043c\u043e \u043a\u0430\u043a \u0437\u0430 \u043f\u0440\u0435\u0434\u0435\u043b\u0430\u043c\u0438     # include\/define:     {{ cat $stringArg $.Values.key .Values.key }}   {{- end }} {{- end }}  --- {{- $arg := &quot;explicitlyPassed&quot; }} {{- include &quot;testFunc&quot; (list $ . $arg) }} #   ==&gt; string &quot;explicitlyPassed value value&quot; <\/code><\/pre>\n<p>  <\/p>\n<h3>1.3. \u041f\u0435\u0440\u0435\u0434\u0430\u0447\u0430 \u043e\u043f\u0446\u0438\u043e\u043d\u0430\u043b\u044c\u043d\u044b\u0445 \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u043e\u0432<\/h3>\n<p>  \u0415\u0441\u0442\u044c \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0441\u043f\u043e\u0441\u043e\u0431\u043e\u0432 \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u043f\u0435\u0440\u0435\u0434\u0430\u0447\u0443 \u043e\u043f\u0446\u0438\u043e\u043d\u0430\u043b\u044c\u043d\u044b\u0445 \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u043e\u0432 \u0432 \u0448\u0430\u0431\u043b\u043e\u043d. \u0421\u0430\u043c\u044b\u0439 \u0433\u0438\u0431\u043a\u0438\u0439 \u0438 \u0443\u0434\u043e\u0431\u043d\u044b\u0439 \u0438\u0437 \u043d\u0438\u0445 \u2014 \u043f\u0435\u0440\u0435\u0434\u0430\u0432\u0430\u0442\u044c \u0432 \u0441\u043f\u0438\u0441\u043a\u0435 \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u043e\u0432 \u0442\u0430\u043a\u0436\u0435 \u0438 \u0441\u043b\u043e\u0432\u0430\u0440\u044c \u0441 \u043e\u043f\u0446\u0438\u043e\u043d\u0430\u043b\u044c\u043d\u044b\u043c\u0438 \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u0430\u043c\u0438:<\/p>\n<pre><code class=\"go\">{{- include &quot;testFunc&quot; (list $requiredArg (dict &quot;optionalArg2&quot; &quot;optionalValue2&quot;)) }}<\/code><\/pre>\n<p>  \u0410 \u0442\u0435\u043f\u0435\u0440\u044c \u0434\u043e\u0431\u0430\u0432\u0438\u043c \u043d\u0435\u043c\u043d\u043e\u0433\u043e \u043c\u0430\u0433\u0438\u0438 \u0432 \u0448\u0430\u0431\u043b\u043e\u043d, \u0447\u0442\u043e\u0431\u044b \u043a\u043e\u0440\u0440\u0435\u043a\u0442\u043d\u043e \u043e\u0431\u0440\u0430\u0431\u0430\u0442\u044b\u0432\u0430\u0442\u044c \u043e\u0442\u0441\u0443\u0442\u0441\u0442\u0432\u0438\u0435 \u043e\u043f\u0446\u0438\u043e\u043d\u0430\u043b\u044c\u043d\u044b\u0445 \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u043e\u0432:<\/p>\n<pre><code class=\"go\">{{- define &quot;testFunc&quot; }}   ...   {{- $optionalArgs := dict }}   {{- if ge (len .) 2 }}{{ $optionalArgs = index . 1 }}{{ end }} <\/code><\/pre>\n<p>  \u041f\u043e\u0441\u043b\u0435 \u044d\u0442\u043e\u0433\u043e \u043c\u043e\u0436\u043d\u043e \u043e\u0431\u0440\u0430\u0449\u0430\u0442\u044c\u0441\u044f \u043a \u043e\u043f\u0446\u0438\u043e\u043d\u0430\u043b\u044c\u043d\u044b\u043c \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u0430\u043c \u0447\u0435\u0440\u0435\u0437 <code>{{ $optionalArgs.optionalArg2 }}<\/code>. \u041f\u043e\u043b\u043d\u044b\u0439 \u043f\u0440\u0438\u043c\u0435\u0440:<\/p>\n<pre><code class=\"go\">{{- define &quot;testFunc&quot; }}   {{- $requiredArg := index . 0 }}   {{- $optionalArgs := dict }}   {{- if ge (len .) 2 }}{{ $optionalArgs = index . 1 }}{{ end }}    # \u041f\u0440\u043e\u0432\u0435\u0440\u044f\u0435\u043c \u043d\u0430 \u043d\u0430\u043b\u0438\u0447\u0438\u0435 \u043e\u043f\u0446\u0438\u043e\u043d\u0430\u043b\u044c\u043d\u044b\u0445 \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u043e\u0432   # \u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c \u0438\u0445, \u0435\u0441\u043b\u0438 \u043d\u0430\u0448\u043b\u0438:   {{- if hasKey $optionalArgs &quot;optionalArg1&quot; }}     {{- cat &quot;Along with&quot; $requiredArg &quot;we have at least&quot; $optionalArgs.optionalArg1 }}   {{- else if hasKey $optionalArgs &quot;optionalArg2&quot; }}     {{- cat &quot;Along with&quot; $requiredArg &quot;we have&quot; $optionalArgs.optionalArg2 }}   {{- else }}     {{- cat &quot;We only have&quot; $requiredArg }}   {{- end }} {{- end }}  --- {{- $requiredArg := &quot;requiredValue&quot; }}  # \u0412\u044b\u0437\u043e\u0432\u0435\u043c \u0448\u0430\u0431\u043b\u043e\u043d \u0431\u0435\u0437 \u043e\u043f\u0446\u0438\u043e\u043d\u0430\u043b\u044c\u043d\u044b\u0445 \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u043e\u0432: {{- include &quot;testFunc&quot; (list $requiredArg) }} #   ==&gt; string &quot;We only have requiredValue&quot;  # \u0410 \u0442\u0435\u043f\u0435\u0440\u044c - \u0441 \u043e\u0434\u043d\u0438\u043c \u0438\u0437 \u0434\u0432\u0443\u0445 \u043e\u043f\u0446\u0438\u043e\u043d\u0430\u043b\u044c\u043d\u044b\u0445 \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u043e\u0432: {{- include &quot;testFunc&quot; (list $requiredArg (dict &quot;optionalArg2&quot; &quot;optionalValue2&quot;)) }} #   ==&gt; string &quot;Along with requiredValue we have optionalValue2&quot; <\/code><\/pre>\n<p>  <\/p>\n<h3>1.4. \u0412\u043b\u043e\u0436\u0435\u043d\u043d\u044b\u0435 include&#8217;\u044b, \u0440\u0435\u043a\u0443\u0440\u0441\u0438\u044f<\/h3>\n<p>  \u0422\u0430\u043a\u0436\u0435, \u043d\u0430\u0445\u043e\u0434\u044f\u0441\u044c \u0432\u043d\u0443\u0442\u0440\u0438 \u0448\u0430\u0431\u043b\u043e\u043d\u0430, \u0435\u0441\u0442\u044c \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u0434\u0435\u043b\u0430\u0442\u044c <code>include<\/code> \u0434\u0440\u0443\u0433\u0438\u0445 \u0448\u0430\u0431\u043b\u043e\u043d\u043e\u0432. \u0412 \u0442\u043e\u043c \u0447\u0438\u0441\u043b\u0435, \u043c\u044b \u043c\u043e\u0436\u0435\u043c \u0440\u0435\u043a\u0443\u0440\u0441\u0438\u0432\u043d\u043e \u0432\u044b\u0437\u044b\u0432\u0430\u0442\u044c \u0442\u043e\u0442 \u0436\u0435 \u0448\u0430\u0431\u043b\u043e\u043d, \u0432\u043d\u0443\u0442\u0440\u0438 \u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u043c\u044b \u0441\u0435\u0439\u0447\u0430\u0441 \u043d\u0430\u0445\u043e\u0434\u0438\u043c\u0441\u044f, \u2014 \u0432\u0441\u0451 \u043a\u0430\u043a \u0441 \u0444\u0443\u043d\u043a\u0446\u0438\u044f\u043c\u0438 \u0432 \u043f\u043e\u043b\u043d\u043e\u0446\u0435\u043d\u043d\u044b\u0445 \u044f\u0437\u044b\u043a\u0430\u0445:<\/p>\n<pre><code class=\"go\">{{- define &quot;testFunc&quot; }}   {{- $num := . }}    {{- if lt $num 10 }}     # \u0414\u0435\u043b\u0430\u0435\u043c include \u0434\u0440\u0443\u0433\u043e\u0433\u043e \u0448\u0430\u0431\u043b\u043e\u043d\u0430:     {{- include &quot;print&quot; $num }}     # \u0420\u0435\u043a\u0443\u0440\u0441\u0438\u0432\u043d\u043e \u0432\u044b\u0437\u044b\u0432\u0430\u0435\u043c \u0442\u043e\u0442 \u0436\u0435 \u0448\u0430\u0431\u043b\u043e\u043d, \u0432\u043d\u0443\u0442\u0440\u0438 \u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e     # \u043c\u044b \u0441\u0435\u0439\u0447\u0430\u0441 \u043d\u0430\u0445\u043e\u0434\u0438\u043c\u0441\u044f:     {{- include &quot;testFunc&quot; (add 1 $num) }}   {{- end }} {{- end }}  {{- define &quot;print&quot; }}   {{- print . }} {{- end }}  --- {{- include &quot;testFunc&quot; 0 }} #   ==&gt; string &quot;0123456789&quot; <\/code><\/pre>\n<p>  <\/p>\n<h3>1.5. \u0412\u043e\u0437\u0432\u0440\u0430\u0449\u0435\u043d\u0438\u0435 \u0438\u0437 \u0448\u0430\u0431\u043b\u043e\u043d\u043e\u0432 \u043f\u043e\u043b\u043d\u043e\u0446\u0435\u043d\u043d\u044b\u0445 \u0442\u0438\u043f\u043e\u0432 \u0434\u0430\u043d\u043d\u044b\u0445<\/h3>\n<p>  <code>include<\/code> \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u043f\u0440\u0435\u0434\u0435\u043b\u044c\u043d\u043e \u043f\u0440\u043e\u0441\u0442\u043e: \u043d\u0430 \u043c\u0435\u0441\u0442\u043e <code>{{ include }}<\/code> \u043f\u0440\u043e\u0441\u0442\u043e \u043f\u043e\u0434\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442\u0441\u044f <code>\u0442\u0435\u043a\u0441\u0442<\/code>, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0431\u044b\u043b \u043e\u0442\u0440\u0435\u043d\u0434\u0435\u0440\u0435\u043d \u0432\u043d\u0443\u0442\u0440\u0438 \u0448\u0430\u0431\u043b\u043e\u043d\u0430. \u041f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u0432\u0435\u0440\u043d\u0443\u0442\u044c \u0438\u0437 \u0448\u0430\u0431\u043b\u043e\u043d\u0430 \u0447\u0442\u043e-\u0442\u043e \u043a\u0440\u043e\u043c\u0435 \u0441\u0442\u0440\u043e\u043a\u0438 \u043e\u0442\u0441\u0443\u0442\u0441\u0442\u0432\u0443\u0435\u0442. \u0422\u0430\u043a\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c, \u043c\u044b \u043d\u0435 \u043c\u043e\u0436\u0435\u043c, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0432\u0435\u0440\u043d\u0443\u0442\u044c \u0441\u043f\u0438\u0441\u043e\u043a \u0438\u043b\u0438 \u0441\u043b\u043e\u0432\u0430\u0440\u044c \u0432 \u0441\u043b\u043e\u0432\u0430\u0440\u0435, \u0447\u0442\u043e\u0431\u044b \u043f\u043e\u0442\u043e\u043c \u043f\u0440\u043e\u0439\u0442\u0438\u0441\u044c \u043f\u043e \u043d\u0438\u043c \u0446\u0438\u043a\u043b\u043e\u043c \u0438 \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0438\u0445 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f. \u041d\u043e \u0435\u0441\u0442\u044c \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u044d\u0442\u043e \u043e\u0431\u043e\u0439\u0442\u0438 \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u0441\u0435\u0440\u0438\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438.<\/p>\n<p>  \u0421\u0435\u0440\u0438\u0430\u043b\u0438\u0437\u0443\u0435\u043c \u0434\u0430\u043d\u043d\u044b\u0435 \u0432 JSON (\u0438\u043b\u0438 YAML) \u0432\u043d\u0443\u0442\u0440\u0438 \u0448\u0430\u0431\u043b\u043e\u043d\u0430:<\/p>\n<pre><code class=\"go\">{{- define &quot;returnJson&quot; }}   {{- $result := dict &quot;key1&quot; (dict &quot;nestedKey1&quot; &quot;nestedVal1&quot;) }}   {{- $result | toJson }} {{- end }} <\/code><\/pre>\n<p>  \u041f\u0440\u0438 \u0432\u044b\u0437\u043e\u0432\u0435 \u044d\u0442\u043e\u0433\u043e \u0448\u0430\u0431\u043b\u043e\u043d\u0430 \u043d\u0430\u0448\u0438 \u0441\u0435\u0440\u0438\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u043d\u043d\u044b\u0435 \u0434\u0430\u043d\u043d\u044b\u0435 \u0432\u0435\u0440\u043d\u0443\u0442\u0441\u044f \u043a\u0430\u043a \u0441\u0442\u0440\u043e\u043a\u0430. \u0423\u0431\u0435\u0434\u0438\u043c\u0441\u044f \u0432 \u044d\u0442\u043e\u043c:<\/p>\n<pre><code class=\"go\">{{ include &quot;returnJson&quot; . | typeOf }} #   ==&gt; string &quot;string&quot; <\/code><\/pre>\n<p>  \u0410 \u0442\u0435\u043f\u0435\u0440\u044c \u0441\u0434\u0435\u043b\u0430\u0435\u043c \u0434\u0435\u0441\u0435\u0440\u0438\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044e \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u043d\u043e\u0439 \u0438\u0437 \u0448\u0430\u0431\u043b\u043e\u043d\u0430 \u0441\u0442\u0440\u043e\u043a\u0438 \u0438 \u043f\u0440\u043e\u0432\u0435\u0440\u0438\u043c, \u043a\u0430\u043a\u043e\u0439 \u0442\u0438\u043f \u0434\u0430\u043d\u043d\u044b\u0445 \u043c\u044b \u043f\u043e\u043b\u0443\u0447\u0438\u043b\u0438:<\/p>\n<pre><code class=\"go\">{{- include &quot;returnJson&quot; . | fromJson | typeOf }} #   ==&gt; string &quot;map[string]interface {}&quot; <\/code><\/pre>\n<p>  \u0422\u0430\u043a\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c, \u0432\u043e \u0432\u0442\u043e\u0440\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u043c\u044b \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u043c \u043d\u0435 \u043f\u0440\u043e\u0441\u0442\u043e \u0441\u0442\u0440\u043e\u043a\u0443, \u0430 \u043f\u043e\u043b\u043d\u043e\u0446\u0435\u043d\u043d\u044b\u0439 \u0441\u043b\u043e\u0432\u0430\u0440\u044c \u0441 \u0432\u043b\u043e\u0436\u0435\u043d\u043d\u044b\u043c \u0432 \u043d\u0435\u0433\u043e \u0434\u0440\u0443\u0433\u0438\u043c \u0441\u043b\u043e\u0432\u0430\u0440\u0435\u043c. \u0421 \u043d\u0438\u043c \u043c\u043e\u0436\u043d\u043e \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u043e\u0431\u044b\u0447\u043d\u044b\u043c\u0438 \u0434\u043b\u044f \u0441\u043b\u043e\u0432\u0430\u0440\u0435\u0439 \u0444\u0443\u043d\u043a\u0446\u0438\u044f\u043c\u0438:<\/p>\n<pre><code class=\"go\">{{- include &quot;returnJson&quot; . | fromJson | values }} #   ==&gt; string &quot;[map[nestedKey1:nestedVal1]]&quot; <\/code><\/pre>\n<p>  \u0422\u0430\u043a\u0443\u044e \u0441\u0435\u0440\u0438\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044e, \u043e\u0447\u0435\u0432\u0438\u0434\u043d\u043e, \u043c\u043e\u0436\u043d\u043e \u043f\u0440\u0438\u043c\u0435\u043d\u044f\u0442\u044c \u0434\u043b\u044f \u043b\u044e\u0431\u044b\u0445 \u0442\u0438\u043f\u043e\u0432: \u0441\u043f\u0438\u0441\u043a\u043e\u0432, \u0441\u043b\u043e\u0432\u0430\u0440\u0435\u0439, \u0431\u0443\u043b\u0435\u0432\u044b\u0445 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0439 \u0438 \u0442. \u043f., \u0432 \u0442\u043e\u043c \u0447\u0438\u0441\u043b\u0435 \u0432\u043b\u043e\u0436\u0435\u043d\u043d\u044b\u0445 \u0434\u0440\u0443\u0433 \u0432 \u0434\u0440\u0443\u0433\u0430.<\/p>\n<h3>1.6. Include \u0432 \u0443\u0441\u043b\u043e\u0432\u0438\u044f\u0445 if-\u0431\u043b\u043e\u043a\u043e\u0432 \u0438 \u0432 \u0444\u0443\u043d\u043a\u0446\u0438\u0438 ternary<\/h3>\n<p>  \u0412\u0441\u0451, \u0447\u0442\u043e \u0432\u043e\u0437\u0432\u0440\u0430\u0449\u0430\u0435\u0442 <code>include<\/code> \u0432 \u0443\u0441\u043b\u043e\u0432\u0438\u044f\u0445 \u0431\u043b\u043e\u043a\u043e\u0432 <code>if<\/code>, \u0442\u0430\u043a \u0438 \u043e\u0441\u0442\u0430\u0451\u0442\u0441\u044f \u0441\u0442\u0440\u043e\u043a\u043e\u0439, \u043d\u0435 \u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u0432 \u0431\u0443\u043b\u0435\u0432\u044b\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u0438 \u0434\u0440\u0443\u0433\u0438\u0435 \u0442\u0438\u043f\u044b. \u0422\u043e \u0435\u0441\u0442\u044c, \u0435\u0441\u043b\u0438 \u043c\u044b \u0432\u043e\u0437\u0432\u0440\u0430\u0449\u0430\u0435\u043c \u0438\u0437 \u0448\u0430\u0431\u043b\u043e\u043d\u0430 <code>true<\/code>, \u043e\u043d\u043e \u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u0441\u044f \u0441\u0442\u0440\u043e\u043a\u043e\u0439 <code>&quot;true&quot;<\/code>. \u041b\u044e\u0431\u0430\u044f \u043d\u0435\u043f\u0443\u0441\u0442\u0430\u044f \u0441\u0442\u0440\u043e\u043a\u0430 \u044d\u043a\u0432\u0438\u0432\u0430\u043b\u0435\u043d\u0442\u043d\u0430 \u0432 \u0443\u0441\u043b\u043e\u0432\u0438\u0438 if-\u0431\u043b\u043e\u043a\u0430 \u0431\u0443\u043b\u0435\u0432\u043e\u043c\u0443 <code>true<\/code>. \u041f\u043e\u044d\u0442\u043e\u043c\u0443, \u0435\u0441\u043b\u0438 \u043c\u044b \u0432\u043e\u0437\u0432\u0440\u0430\u0449\u0430\u0435\u043c <code>false<\/code>, \u0442\u043e \u043e\u043d\u043e \u0442\u043e\u0436\u0435 \u043f\u0440\u0435\u0432\u0440\u0430\u0449\u0430\u0435\u0442\u0441\u044f \u0432 \u043d\u0435\u043f\u0443\u0441\u0442\u0443\u044e \u0441\u0442\u0440\u043e\u043a\u0443 <code>&quot;false&quot;<\/code>, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u0442\u043e\u0436\u0435 \u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u0441\u044f \u0431\u0443\u043b\u0435\u0432\u044b\u043c <code>true<\/code>.<\/p>\n<p>  \u0418\u0437\u0431\u0435\u0436\u0430\u0442\u044c \u043f\u0440\u0435\u0432\u0440\u0430\u0449\u0435\u043d\u0438\u044f <code>false<\/code> \u0432 <code>true<\/code> \u0432 \u0443\u0441\u043b\u043e\u0432\u0438\u0438 if-\u0431\u043b\u043e\u043a\u0430 \u043c\u043e\u0436\u043d\u043e, \u0435\u0441\u043b\u0438 <i>\u043d\u0438\u0447\u0435\u0433\u043e<\/i> \u043d\u0435 \u0432\u043e\u0437\u0432\u0440\u0430\u0449\u0430\u0442\u044c \u0438\u0437 \u0448\u0430\u0431\u043b\u043e\u043d\u0430 \u2014 \u0432\u043c\u0435\u0441\u0442\u043e \u0442\u043e\u0433\u043e, \u0447\u0442\u043e\u0431\u044b \u0432\u043e\u0437\u0432\u0440\u0430\u0449\u0430\u0442\u044c <code>false<\/code>. \u0412 \u0442\u0430\u043a\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u0438\u0437 \u0448\u0430\u0431\u043b\u043e\u043d\u0430 \u0432\u0435\u0440\u043d\u0435\u0442\u0441\u044f \u043f\u0443\u0441\u0442\u0430\u044f \u0441\u0442\u0440\u043e\u043a\u0430, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u0432 \u0443\u0441\u043b\u043e\u0432\u0438\u0438 if-\u0431\u043b\u043e\u043a\u0430 \u0441\u0442\u0430\u043d\u0435\u0442 \u043d\u0430\u043c \u0431\u0443\u043b\u0435\u0432\u044b\u043c <code>false<\/code>:<\/p>\n<pre><code class=\"go\">{{- define &quot;returnPseudoBoolean&quot; }}   {{- if eq . &quot;pleaseReturnTrue&quot; }} true   {{- else if eq . &quot;pleaseReturnFalse&quot; }}   {{- end }} {{- end }} <\/code><\/pre>\n<p>  \u0422\u0430\u043a \u043c\u044b \u043c\u043e\u0436\u0435\u043c \u0434\u0435\u043b\u0430\u0442\u044c include&#8217;\u044b, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0431\u0443\u0434\u0443\u0442 \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u0432 \u0443\u0441\u043b\u043e\u0432\u0438\u044f\u0445 if-\u0431\u043b\u043e\u043a\u043e\u0432:<\/p>\n<pre><code class=\"go\">{{- if include &quot;returnPseudoBoolean&quot; &quot;pleaseReturnTrue&quot; }}   {{- print &quot;\u041f\u0435\u0440\u0432\u044b\u0439 if \u0432\u0435\u0440\u043d\u0451\u0442 True&quot; }} {{- end }} #   ==&gt; string &quot;\u041f\u0435\u0440\u0432\u044b\u0439 if \u0432\u0435\u0440\u043d\u0451\u0442 True&quot;  {{- if include &quot;returnPseudoBoolean&quot; &quot;pleaseReturnFalse&quot; }} {{- else }}   {{- print &quot;\u0412\u0442\u043e\u0440\u043e\u0439 if \u0432\u0435\u0440\u043d\u0451\u0442 False&quot; }} {{- end }} #   ==&gt; string &quot;\u0412\u0442\u043e\u0440\u043e\u0439 if \u0432\u0435\u0440\u043d\u0451\u0442 False&quot; <\/code><\/pre>\n<p>  \u0414\u0440\u0443\u0433\u043e\u0435 \u0434\u0435\u043b\u043e \u2014 \u0444\u0443\u043d\u043a\u0446\u0438\u044f <code>ternary<\/code>: \u043e\u043d\u0430 \u043a\u0430\u043a \u0440\u0430\u0437 \u043e\u0436\u0438\u0434\u0430\u0435\u0442 \u0440\u0435\u0430\u043b\u044c\u043d\u044b\u0435 \u0431\u0443\u043b\u0435\u0432\u044b\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f, \u0430 \u043d\u0435 \u0441\u0442\u0440\u043e\u043a\u0438. \u0412\u0435\u0440\u043d\u0443\u0442\u044c \u0431\u0443\u043b\u0435\u0432\u044b\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u0438\u0437 \u0448\u0430\u0431\u043b\u043e\u043d\u0430 \u043c\u043e\u0436\u043d\u043e, \u0434\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u043f\u0440\u043e\u0433\u043d\u0430\u0432 \u0432\u044b\u0432\u043e\u0434 \u0448\u0430\u0431\u043b\u043e\u043d\u0430 \u0447\u0435\u0440\u0435\u0437 \u0444\u0443\u043d\u043a\u0446\u0438\u044e <code>empty<\/code>. \u041f\u043e\u043b\u0443\u0447\u0438\u0442\u0441\u044f \u0430\u043d\u0430\u043b\u043e\u0433 \u0442\u043e\u0433\u043e, \u0447\u0442\u043e \u043f\u0440\u043e\u0438\u0441\u0445\u043e\u0434\u0438\u0442 \u043f\u043e\u0434 \u043a\u0430\u043f\u043e\u0442\u043e\u043c \u0443\u0441\u043b\u043e\u0432\u0438\u0439 if-\u0431\u043b\u043e\u043a\u043e\u0432:<\/p>\n<pre><code class=\"go\">{{- ternary &quot;\u0421\u0440\u0430\u0431\u043e\u0442\u0430\u043b\u043e True&quot; &quot;\u0421\u0440\u0430\u0431\u043e\u0442\u0430\u043b\u043e False&quot; (include &quot;returnBoolean&quot; &quot;pleaseReturnTrue&quot; | not | empty) }} #   ==&gt; string &quot;\u0421\u0440\u0430\u0431\u043e\u0442\u0430\u043b\u043e True&quot; <\/code><\/pre>\n<p>  <\/p>\n<h2>2. \u042d\u0444\u0444\u0435\u043a\u0442\u0438\u0432\u043d\u043e\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 \u0444\u0443\u043d\u043a\u0446\u0438\u0438 tpl<\/h2>\n<p>  \u0424\u0443\u043d\u043a\u0446\u0438\u044f <code>tpl<\/code> \u2014 \u043c\u043e\u0449\u043d\u044b\u0439 \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442 \u0434\u043b\u044f \u0448\u0430\u0431\u043b\u043e\u043d\u0438\u0437\u0430\u0446\u0438\u0438 \u0442\u0430\u043c, \u0433\u0434\u0435 \u043e\u043d\u0430 \u0431\u044b\u043b\u0430 \u043d\u0435\u0432\u043e\u0437\u043c\u043e\u0436\u043d\u0430. \u041e\u043d\u0430 \u043f\u043e\u043a\u0430\u0437\u0430\u043b\u0430 \u0441\u0435\u0431\u044f \u043f\u043e\u043b\u0435\u0437\u043d\u043e\u0439 \u043f\u0440\u0435\u0436\u0434\u0435 \u0432\u0441\u0435\u0433\u043e \u0434\u043b\u044f \u0448\u0430\u0431\u043b\u043e\u043d\u0438\u0437\u0430\u0446\u0438\u0438 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0439 \u0432 <code>values.yaml<\/code>. \u041d\u043e \u0443 \u044d\u0442\u043e\u0439 \u0444\u0443\u043d\u043a\u0446\u0438\u0438 \u0435\u0441\u0442\u044c \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0435\u043d\u0438\u0439, \u043d\u0435 \u0434\u0430\u044e\u0449\u0438\u0445 \u0435\u0439 \u043f\u043e\u043b\u043d\u043e\u0441\u0442\u044c\u044e \u0440\u0430\u0441\u043a\u0440\u044b\u0442\u044c\u0441\u044f. \u0420\u0430\u0437\u0431\u0435\u0440\u0435\u043c \u044d\u0442\u0438 \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0435\u043d\u0438\u044f \u0438 \u0441\u043f\u043e\u0441\u043e\u0431\u044b \u0438\u0445 \u043e\u0431\u0445\u043e\u0434\u0430.<\/p>\n<h3>2.1. \u0421\u0434\u0435\u043b\u0430\u0435\u043c \u043e\u0431\u0451\u0440\u0442\u043a\u0443 \u0434\u043b\u044f Values<\/h3>\n<p>  \u0427\u0442\u043e\u0431\u044b \u043d\u0435 \u0434\u0443\u0431\u043b\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u043a\u0430\u0436\u0434\u044b\u0439 \u0440\u0430\u0437 \u043b\u043e\u0433\u0438\u043a\u0443, \u0432 \u043a\u043e\u0442\u043e\u0440\u0443\u044e \u043c\u044b \u0441\u0435\u0439\u0447\u0430\u0441 \u043e\u0431\u0435\u0440\u043d\u0451\u043c \u043d\u0430\u0448\u0443 \u0444\u0443\u043d\u043a\u0446\u0438\u044e <code>tpl<\/code>, \u043c\u043e\u0436\u043d\u043e \u0432\u044b\u043d\u0435\u0441\u0442\u0438 \u044d\u0442\u0443 \u043b\u043e\u0433\u0438\u043a\u0443 \u0432 \u0448\u0430\u0431\u043b\u043e\u043d. \u041d\u0430\u0437\u043e\u0432\u0451\u043c \u0435\u0433\u043e <code>&quot;value&quot;<\/code> \u0438 \u0431\u0443\u0434\u0435\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043a\u0430\u043a \u043e\u0431\u0435\u0440\u0442\u043a\u0443 \u0434\u043b\u044f \u0432\u0441\u0435\u0445 \u043d\u0430\u0448\u0438\u0445 <code>Values<\/code>. \u0422\u0430\u043a \u0447\u0442\u043e \u0442\u0435\u043f\u0435\u0440\u044c \u0432\u043c\u0435\u0441\u0442\u043e <code>{{ $.Values.key }}<\/code> \u0432\u0435\u0437\u0434\u0435 \u0431\u0443\u0434\u0435\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f <code>{{ include &quot;value&quot; (list $ . $.Values.key }}<\/code>.<\/p>\n<p>  \u0421\u0430\u043c \u0448\u0430\u0431\u043b\u043e\u043d \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u0441\u044f \u0442\u0430\u043a\u0438\u043c:<\/p>\n<pre><code class=\"go\">.helm\/values.yaml: ------------------------------------------------------------- key1: &quot;\u0417\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043a\u043b\u044e\u0447\u0430 key2: {{ $.Values.key2 }}&quot; key2: &quot;value2&quot;  ------------------------------------------------------------- .helm\/templates\/test.yaml: ------------------------------------------------------------- {{- define &quot;value&quot; }}   # \u0421\u0440\u0430\u0437\u0443 \u043f\u0440\u043e\u0431\u0440\u043e\u0441\u0438\u043c \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442\u044b, \u043e\u043d\u0438 \u043f\u043e\u043d\u0430\u0434\u043e\u0431\u044f\u0442\u0441\u044f \u043d\u0430\u043c \u043f\u043e\u0437\u0436\u0435:   {{- $ := index . 0 }}   {{- $val := index . 2 }}    {{- with index . 1 }}     {{- tpl $val $ }}   {{- end }} {{- end }}  --- {{- include &quot;value&quot; (list $ . $.Values.key1) }} #   ==&gt; String &quot;\u0417\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043a\u043b\u044e\u0447\u0430 key2: value2&quot; <\/code><\/pre>\n<p>  \u041f\u043e\u043a\u0430 \u0447\u0442\u043e \u043c\u044b \u043f\u0440\u043e\u0441\u0442\u043e \u043f\u0435\u0440\u0435\u0434\u0430\u0451\u043c \u0432 \u0444\u0443\u043d\u043a\u0446\u0438\u044e <code>tpl<\/code> \u0442\u0440\u0435\u0442\u0438\u0439 \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442 \u0448\u0430\u0431\u043b\u043e\u043d\u0430. \u042d\u0442\u043e\u0442 \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442 \u2014 \u043f\u0440\u043e\u0441\u0442\u043e\u0435 <code>Value<\/code>. \u041d\u0438\u0447\u0435\u0433\u043e \u043a\u0440\u043e\u043c\u0435 \u044d\u0442\u043e\u0433\u043e \u043d\u0435 \u0434\u0435\u043b\u0430\u0435\u043c \u0438 \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u043c \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442.<\/p>\n<p>  <i>NB: \u041e\u0431\u0440\u0430\u0431\u043e\u0442\u043a\u0443 \u043e\u0441\u0442\u0430\u043b\u044c\u043d\u044b\u0445 \u0442\u0438\u043f\u043e\u0432 \u0434\u0430\u043d\u043d\u044b\u0445 (\u043d\u0435 \u0441\u0442\u0440\u043e\u043a) \u0432 \u0448\u0430\u0431\u043b\u043e\u043d\u0435 <code>&quot;value&quot;<\/code> \u043c\u044b \u0440\u0435\u0430\u043b\u0438\u0437\u043e\u0432\u044b\u0432\u0430\u0442\u044c \u043d\u0435 \u0431\u0443\u0434\u0435\u043c. \u0418\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044f \u043a\u043e\u043d\u0441\u0442\u0440\u0443\u043a\u0446\u0438\u0438 \u0432\u0438\u0434\u0430 <code>{{- if kindIs &quot;map&quot; $val }}<\/code>, \u0432\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u0441\u0430\u043c\u0438 \u043f\u043e\u043f\u0440\u043e\u0431\u043e\u0432\u0430\u0442\u044c \u0440\u0435\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u0442\u044c \u0441\u043f\u0435\u0446\u0438\u0444\u0438\u0447\u043d\u044b\u0435 \u0434\u043b\u044f \u0440\u0430\u0437\u043d\u044b\u0445 \u0442\u0438\u043f\u043e\u0432 \u0434\u0430\u043d\u043d\u044b\u0445 \u043e\u0431\u0440\u0430\u0431\u043e\u0442\u043a\u0438.<\/i><\/p>\n<h3>2.2. \u041f\u0435\u0440\u0435\u0434\u0430\u0447\u0430 \u0442\u0435\u043a\u0443\u0449\u0435\u0433\u043e \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442\u0430<\/h3>\n<p>  \u0424\u0443\u043d\u043a\u0446\u0438\u044f <code>tpl<\/code> <i>\u0442\u0440\u0435\u0431\u0443\u0435\u0442<\/i>, \u0447\u0442\u043e\u0431\u044b \u0435\u0434\u0438\u043d\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u043c \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u043e\u043c, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0435\u0439 \u043f\u0435\u0440\u0435\u0434\u0430\u0451\u0442\u0441\u044f, \u0431\u044b\u043b \u0441\u043b\u043e\u0432\u0430\u0440\u044c \u0441 <a href=\"https:\/\/helm.sh\/docs\/chart_template_guide\/builtin_objects\/\"><code>\u043e\u0431\u044a\u0435\u043a\u0442\u043e\u043c Template<\/code><\/a>. \u0422\u0430\u043a\u0438\u043c \u0441\u043b\u043e\u0432\u0430\u0440\u0451\u043c \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u0433\u043b\u043e\u0431\u0430\u043b\u044c\u043d\u044b\u0439 \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442 (<code>$<\/code>), \u0435\u0433\u043e-\u0442\u043e \u043e\u0431\u044b\u0447\u043d\u043e \u0438 \u043f\u0435\u0440\u0435\u0434\u0430\u044e\u0442 \u043a\u0430\u043a \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442 \u0432 \u0444\u0443\u043d\u043a\u0446\u0438\u044e <code>tpl<\/code>. \u0418 \u0437\u0434\u0435\u0441\u044c \u043c\u044b \u043d\u0435 \u043c\u043e\u0436\u0435\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0442\u0440\u044e\u043a \u0441 \u043f\u0435\u0440\u0435\u0434\u0430\u0447\u0435\u0439 \u0432 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u0435\u0434\u0438\u043d\u0441\u0442\u0432\u0435\u043d\u043d\u043e\u0433\u043e \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u0430 \u0441\u043f\u0438\u0441\u043a\u0430 \u0441 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u0438\u043c\u0438 \u0432\u043b\u043e\u0436\u0435\u043d\u043d\u044b\u043c\u0438 \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u0430\u043c\u0438, \u0442. \u043a. \u0432 \u044d\u0442\u043e\u043c \u0441\u043f\u0438\u0441\u043a\u0435 \u043d\u0435 \u0431\u0443\u0434\u0435\u0442 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e\u0433\u043e \u043e\u0431\u044a\u0435\u043a\u0442\u0430 <code>Template<\/code>. \u0418 \u0432\u0441\u0451 \u0436\u0435 \u0435\u0441\u0442\u044c \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0441\u043f\u043e\u0441\u043e\u0431\u043e\u0432 \u043f\u0435\u0440\u0435\u0434\u0430\u0442\u044c \u0432\u043c\u0435\u0441\u0442\u0435 \u0441 \u0433\u043b\u043e\u0431\u0430\u043b\u044c\u043d\u044b\u043c \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442\u043e\u043c \u0438 \u0442\u0435\u043a\u0443\u0449\u0438\u0439 \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442 \u2014 \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u0441\u0430\u043c\u044b\u0439 \u043f\u0440\u043e\u0441\u0442\u043e\u0439.<\/p>\n<p>  \u041f\u0435\u0440\u0432\u044b\u0439 \u0448\u0430\u0433 \u2014 \u0441\u043e\u0437\u0434\u0430\u0434\u0438\u043c \u043d\u043e\u0432\u044b\u0439 \u043a\u043b\u044e\u0447 \u0432 \u0433\u043b\u043e\u0431\u0430\u043b\u044c\u043d\u043e\u043c \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442\u0435, \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435\u043c \u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u0431\u0443\u0434\u0435\u0442 \u043d\u0430\u0448 <i>\u0442\u0435\u043a\u0443\u0449\u0438\u0439<\/i> \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442, \u0438 \u043f\u043e\u0441\u043b\u0435 \u044d\u0442\u043e\u0433\u043e \u043f\u0435\u0440\u0435\u0434\u0430\u0434\u0438\u043c \u0433\u043b\u043e\u0431\u0430\u043b\u044c\u043d\u044b\u0439 \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442 \u0432 <code>tpl<\/code>. \u0422\u0430\u043a\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c <code>{{- tpl $val $ }}<\/code> \u043f\u0440\u0435\u0432\u0440\u0430\u0442\u0438\u0442\u0441\u044f \u0432 \u044d\u0442\u043e:<\/p>\n<pre><code class=\"go\">    {{- tpl $val (merge (dict &quot;RelativeScope&quot; .) $) }}<\/code><\/pre>\n<p>  \u0422\u0435\u043f\u0435\u0440\u044c \u043b\u043e\u043a\u0430\u043b\u044c\u043d\u044b\u0439 \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442 \u0434\u043e\u0441\u0442\u0443\u043f\u0435\u043d \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e <code>{{ $.RelativeScope }}<\/code> \u0432 \u043d\u0430\u0448\u0435\u0439 \u0441\u0442\u0440\u043e\u043a\u0435-\u0448\u0430\u0431\u043b\u043e\u043d\u0435 <code>$val<\/code>, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u043f\u0435\u0440\u0435\u0434\u0430\u0451\u0442\u0441\u044f \u0432 \u0444\u0443\u043d\u043a\u0446\u0438\u044e <code>tpl<\/code> \u0434\u043b\u044f \u0440\u0435\u043d\u0434\u0435\u0440\u0438\u043d\u0433\u0430.<\/p>\n<p>  \u0412\u0442\u043e\u0440\u043e\u0439 \u0448\u0430\u0433 \u2014 \u043e\u0431\u0435\u0440\u043d\u0451\u043c \u0441\u0442\u0440\u043e\u043a\u0443-\u0448\u0430\u0431\u043b\u043e\u043d <code>$val<\/code> \u0432 \u0431\u043b\u043e\u043a <code>with<\/code>, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u00ab\u0432\u043e\u0441\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u00bb \u0442\u0435\u043a\u0443\u0449\u0438\u0439 \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442 \u0438 \u043f\u043e\u0437\u0432\u043e\u043b\u0438\u0442 \u043e\u0431\u0440\u0430\u0449\u0430\u0442\u044c\u0441\u044f \u043a \u043d\u0435\u043c\u0443 \u0447\u0435\u0440\u0435\u0437 \u043f\u0440\u0438\u0432\u044b\u0447\u043d\u0443\u044e \u0442\u043e\u0447\u043a\u0443:<\/p>\n<pre><code class=\"go\">    {{- tpl (cat &quot;{{- with $.RelativeScope -}}&quot; $val &quot;{{- end }}&quot;) (merge (dict &quot;RelativeScope&quot; .) $) }} <\/code><\/pre>\n<p>  \u0418 \u0442\u0435\u043f\u0435\u0440\u044c \u043c\u043e\u0436\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043d\u0435 \u0442\u043e\u043b\u044c\u043a\u043e \u0433\u043b\u043e\u0431\u0430\u043b\u044c\u043d\u044b\u0439, \u043d\u043e \u0438 \u043e\u0442\u043d\u043e\u0441\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0439 \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442 \u0432 \u043d\u0430\u0448\u0438\u0445 <code>values.yaml<\/code>:<\/p>\n<pre><code class=\"go\">.helm\/values.yaml: ------------------------------------------------------------- key1: &quot;\u0417\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043a\u043b\u044e\u0447\u0430 key2: {{ .key2 }}&quot; key2: &quot;value2&quot;  ------------------------------------------------------------- .helm\/templates\/test.yaml: ------------------------------------------------------------- {{- define &quot;value&quot; }}   {{- $ := index . 0 }}   {{- $val := index . 2 }}    {{- with index . 1 }}     {{- tpl (cat &quot;{{- with $.RelativeScope -}}&quot; $val &quot;{{- end }}&quot;) (merge (dict &quot;RelativeScope&quot; .) $) }}   {{- end }} {{- end }}  --- # \u0418\u0437\u043c\u0435\u043d\u0438\u043c \u0442\u0435\u043a\u0443\u0449\u0438\u0439 \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442: {{- with $.Values }} # \u041f\u043e\u043f\u0440\u043e\u0431\u0443\u0435\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043e\u0442\u043d\u043e\u0441\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0439 \u043f\u0443\u0442\u044c \u043a key1: {{- include &quot;value&quot; (list $ . .key1) }} {{- end }} #   ==&gt; String &quot;\u0417\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043a\u043b\u044e\u0447\u0430 key2: value2&quot; <\/code><\/pre>\n<p>  \u0414\u043e\u0441\u0442\u0443\u043f \u043a \u0442\u0435\u043a\u0443\u0449\u0435\u043c\u0443 \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442\u0443 \u043f\u043e\u043b\u0435\u0437\u0435\u043d, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u043f\u0440\u0438 \u0433\u0435\u043d\u0435\u0440\u0430\u0446\u0438\u0438 YAML-\u0444\u0440\u0430\u0433\u043c\u0435\u043d\u0442\u043e\u0432 \u0432 \u0446\u0438\u043a\u043b\u0435, \u0433\u0434\u0435 \u043e\u0447\u0435\u043d\u044c \u0447\u0430\u0441\u0442\u043e \u043d\u0443\u0436\u0435\u043d \u0434\u043e\u0441\u0442\u0443\u043f \u0438\u043c\u0435\u043d\u043d\u043e \u043a \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442\u0443 \u0432 \u0442\u0435\u043a\u0443\u0449\u0435\u0439 \u0438\u0442\u0435\u0440\u0430\u0446\u0438\u0438.<\/p>\n<p>  \u0422\u0430\u043a \u0436\u0435, \u043a\u0430\u043a \u043c\u044b \u043f\u0440\u043e\u0431\u0440\u043e\u0441\u0438\u043b\u0438 \u0442\u0435\u043a\u0443\u0449\u0438\u0439 \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442, \u043c\u043e\u0436\u043d\u043e \u043f\u0435\u0440\u0435\u0434\u0430\u0432\u0430\u0442\u044c \u0438 \u043b\u044e\u0431\u044b\u0445 \u0434\u0440\u0443\u0433\u0438\u0435 \u0434\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0435 \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u044b \u0432 \u0444\u0443\u043d\u043a\u0446\u0438\u044e <code>tpl<\/code>. \u041d\u0430\u0434\u043e \u0442\u043e\u043b\u044c\u043a\u043e \u043f\u0440\u0438\u043a\u0440\u0435\u043f\u0438\u0442\u044c \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u044b \u043a \u0433\u043b\u043e\u0431\u0430\u043b\u044c\u043d\u043e\u043c\u0443 \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442\u0443 \u0438 \u043f\u0435\u0440\u0435\u0434\u0430\u0442\u044c \u0433\u043b\u043e\u0431\u0430\u043b\u044c\u043d\u044b\u0439 \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442 \u0432 \u0444\u0443\u043d\u043a\u0446\u0438\u044e <code>tpl<\/code>.<\/p>\n<h3>2.3. \u041f\u0440\u043e\u0431\u043b\u0435\u043c\u044b \u0441 \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u044c\u044e tpl<\/h3>\n<p>  \u0423 \u0444\u0443\u043d\u043a\u0446\u0438\u0438 <code>tpl<\/code> \u0435\u0441\u0442\u044c \u0438\u0437\u0432\u0435\u0441\u0442\u043d\u044b\u0435 \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u044b \u0441 \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u044c\u044e (<a href=\"https:\/\/github.com\/helm\/helm\/issues\/8002\">Issue<\/a>). \u041f\u043e\u044d\u0442\u043e\u043c\u0443 \u0432\u044b\u0437\u043e\u0432 <code>tpl<\/code> \u0434\u043b\u044f \u043a\u0430\u0436\u0434\u043e\u0433\u043e <code>Value<\/code>, \u0434\u0430\u0436\u0435 \u043a\u043e\u0433\u0434\u0430 \u044d\u0442\u043e \u043d\u0435 \u043d\u0443\u0436\u043d\u043e, \u043c\u043e\u0436\u0435\u0442 \u0441\u0438\u043b\u044c\u043d\u043e \u0437\u0430\u043c\u0435\u0434\u043b\u0438\u0442\u044c \u0440\u0435\u043d\u0434\u0435\u0440\u0438\u043d\u0433 \u0431\u043e\u043b\u044c\u0448\u0438\u0445 \u0447\u0430\u0440\u0442\u043e\u0432. \u0427\u0442\u043e\u0431\u044b \u0438\u0437\u0431\u0435\u0436\u0430\u0442\u044c \u043d\u0435\u043d\u0443\u0436\u043d\u044b\u0445 \u0437\u0430\u043f\u0443\u0441\u043a\u043e\u0432 \u0444\u0443\u043d\u043a\u0446\u0438\u0438 <code>tpl<\/code>, \u043c\u043e\u0436\u043d\u043e \u043f\u0440\u043e\u0441\u0442\u043e \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0443 \u043d\u0430 \u043d\u0430\u043b\u0438\u0447\u0438\u0435 <code>{{<\/code> \u0432 \u0441\u0442\u0440\u043e\u043a\u0435-\u0448\u0430\u0431\u043b\u043e\u043d\u0435. \u0415\u0441\u043b\u0438 \u0444\u0438\u0433\u0443\u0440\u043d\u044b\u0445 \u0441\u043a\u043e\u0431\u043e\u043a \u0432 \u0441\u0442\u0440\u043e\u043a\u0435-\u0448\u0430\u0431\u043b\u043e\u043d\u0435 \u043d\u0435 \u0431\u0443\u0434\u0435\u0442, \u0442\u043e \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u0432\u0435\u0440\u043d\u0451\u0442\u0441\u044f \u0438\u0437 \u0448\u0430\u0431\u043b\u043e\u043d\u0430 \u00abvalue\u00bb \u043a\u0430\u043a \u0435\u0441\u0442\u044c, \u0431\u0435\u0437 \u043f\u0435\u0440\u0435\u0434\u0430\u0447\u0438 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u0432 \u0444\u0443\u043d\u043a\u0446\u0438\u044e <code>tpl<\/code>:<\/p>\n<pre><code class=\"go\">{{- define &quot;value&quot; }}   {{- $ := index . 0 }}   {{- $val := index . 2 }}    {{- with index . 1 }}     {{- if contains &quot;{{&quot; $val }}       {{- tpl (cat &quot;{{- with $.RelativeScope -}}&quot; $val &quot;{{- end }}&quot;) (merge (dict &quot;RelativeScope&quot; .) $) }}     {{- else }}       {{- $val }}     {{- end }}   {{- end }} {{- end }}  --- {{- with $.Values }} {{- include &quot;value&quot; (list $ . .key1) }} {{- end }} <\/code><\/pre>\n<p>  \u041f\u0440\u0438 \u044d\u0442\u043e\u043c, \u0435\u0441\u043b\u0438 \u0444\u0438\u0433\u0443\u0440\u043d\u044b\u0435 \u0441\u043a\u043e\u0431\u043a\u0438 \u0432 \u0441\u0442\u0440\u043e\u043a\u0435-\u0448\u0430\u0431\u043b\u043e\u043d\u0435 \u0431\u0443\u0434\u0443\u0442 \u043f\u0440\u0438\u0441\u0443\u0442\u0441\u0442\u0432\u043e\u0432\u0430\u0442\u044c, \u0442\u043e \u043e\u043d\u0430, \u043a\u0430\u043a \u0438 \u043f\u0440\u0435\u0436\u0434\u0435, \u0431\u0443\u0434\u0435\u0442 \u043f\u0440\u043e\u043f\u0443\u0449\u0435\u043d\u0430 \u0447\u0435\u0440\u0435\u0437 \u0444\u0443\u043d\u043a\u0446\u0438\u044e <code>tpl<\/code>. \u0422\u0430\u043a\u043e\u0435 \u043f\u0440\u043e\u0441\u0442\u043e\u0435 \u0440\u0435\u0448\u0435\u043d\u0438\u0435 \u043c\u043e\u0436\u0435\u0442 \u0443\u0441\u043a\u043e\u0440\u0438\u0442\u044c \u0440\u0435\u043d\u0434\u0435\u0440\u0438\u043d\u0433 \u0448\u0430\u0431\u043b\u043e\u043d\u043e\u0432 \u0432 \u0434\u0435\u0441\u044f\u0442\u043a\u0438 \u0440\u0430\u0437.<\/p>\n<h3>3. \u041e\u0442\u043b\u0430\u0434\u043a\u0430<\/h3>\n<p>  \u0421 \u0443\u0432\u0435\u043b\u0438\u0447\u0435\u043d\u0438\u0435\u043c \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u0430 \u043b\u043e\u0433\u0438\u043a\u0438 \u0432 \u0447\u0430\u0440\u0442\u0430\u0445 \u043e\u0442\u043b\u0430\u0434\u043a\u0430 \u043c\u043e\u0436\u0435\u0442 \u0441\u0438\u043b\u044c\u043d\u043e \u0443\u0441\u043b\u043e\u0436\u043d\u0438\u0442\u044c\u0441\u044f. \u041f\u043e\u043c\u0438\u043c\u043e \u0431\u0430\u043d\u0430\u043b\u044c\u043d\u044b\u0445 <code>helm render<\/code> \u0438 <code>helm lint<\/code> \u0435\u0441\u0442\u044c \u0435\u0449\u0451 \u0438 \u0444\u0443\u043d\u043a\u0446\u0438\u044f <code>fail<\/code>, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u0432\u043e \u043c\u043d\u043e\u0433\u0438\u0445 \u0441\u043b\u0443\u0447\u0430\u044f\u0445 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043b\u0443\u0447\u0448\u0435\u0439 \u0430\u043b\u044c\u0442\u0435\u0440\u043d\u0430\u0442\u0438\u0432\u043e\u0439 \u043f\u0440\u043e\u0441\u0442\u043e\u043c\u0443 <code>{{ $valueToDump }}<\/code>. \u0424\u0443\u043d\u043a\u0446\u0438\u044f <code>fail<\/code> \u043d\u0435 \u0442\u0440\u0435\u0431\u0443\u0435\u0442 \u0442\u043e\u0433\u043e, \u0447\u0442\u043e\u0431\u044b \u0447\u0430\u0440\u0442\u044b \u0440\u0435\u043d\u0434\u0435\u0440\u0438\u043b\u0438\u0441\u044c \u0431\u0435\u0437 \u043e\u0448\u0438\u0431\u043e\u043a, \u0438 \u043c\u043e\u0436\u0435\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u0432 \u043b\u044e\u0431\u043e\u043c \u043c\u0435\u0441\u0442\u0435, \u0441\u0440\u0430\u0437\u0443 \u0436\u0435 \u0434\u0430\u0432\u0430\u044f \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442, \u0431\u0435\u0437 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e\u0441\u0442\u0438 \u043f\u0435\u0440\u0435\u0434\u0430\u0432\u0430\u0442\u044c \u0435\u0433\u043e \u0432 \u043c\u0430\u043d\u0438\u0444\u0435\u0441\u0442. \u041d\u0443\u0436\u043d\u043e \u043b\u0438\u0448\u044c, \u0447\u0442\u043e\u0431\u044b \u0440\u0435\u043d\u0434\u0435\u0440\u0438\u043d\u0433 \u0434\u043e\u0431\u0440\u0430\u043b\u0441\u044f \u0434\u043e \u0432\u044b\u0437\u043e\u0432\u0430 \u044d\u0442\u043e\u0439 \u0444\u0443\u043d\u043a\u0446\u0438\u0438.<\/p>\n<p>  \u0421\u0434\u0435\u043b\u0430\u0442\u044c \u0434\u0430\u043c\u043f \u0442\u0435\u043a\u0443\u0449\u0435\u0433\u043e \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442\u0430:<\/p>\n<pre><code class=\"go\">{{- fail (toYaml $.Values) }} #   ==&gt; &quot;key1: val1 #        key2: val2 #        ....&quot; <\/code><\/pre>\n<p>  \u0412\u0430\u0440\u0438\u0430\u043d\u0442 \u0434\u043b\u044f \u0434\u0435\u0431\u0430\u0433\u0430 \u0446\u0438\u043a\u043b\u043e\u0432\/\u0440\u0435\u043a\u0443\u0440\u0441\u0438\u0439 (\u043f\u043e\u0440\u044f\u0434\u043e\u043a \u043d\u0435 \u0433\u0430\u0440\u0430\u043d\u0442\u0438\u0440\u043e\u0432\u0430\u043d, \u043d\u043e \u043f\u0440\u0438 \u0436\u0435\u043b\u0430\u043d\u0438\u0438 \u043c\u043e\u0436\u043d\u043e \u0443\u043f\u043e\u0440\u044f\u0434\u043e\u0447\u0438\u0442\u044c \u043f\u043e timestamp):<\/p>\n<pre><code class=\"go\">{{- range (list &quot;val1&quot; &quot;val2&quot;) }}   {{- $_ := set $.Values.global (toString now) (toYaml .) }} {{- end }}  {{ fail (toYaml $.Values.global) }} #   ==&gt; &quot;2020-12-12 19:52:10.750813319 +0300 MSK m=+0.202723745: | #          val1 #        2020-12-12 19:52:10.750883773 +0300 MSK m=+0.202794200: | #          val2&quot; <\/code><\/pre>\n<p>  \u0421\u0445\u043e\u0436\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c \u043c\u043e\u0436\u043d\u043e \u0441\u043e\u0445\u0440\u0430\u043d\u0438\u0442\u044c \u043b\u044e\u0431\u044b\u0435 \u043f\u0440\u043e\u043c\u0435\u0436\u0443\u0442\u043e\u0447\u043d\u044b\u0435 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u044b, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043f\u043e\u0442\u043e\u043c \u043e\u0442\u043e\u0431\u0440\u0430\u0437\u0438\u0442\u044c \u0440\u0430\u0437\u043e\u043c \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u0444\u0443\u043d\u043a\u0446\u0438\u0438 <code>fail<\/code>:<\/p>\n<pre><code class=\"go\">{{- $_ := set $.Values.global &quot;value1&quot; $val1 }} {{- $_ := set $.Values.global &quot;value2&quot; $val2 }}  {{ fail (toYaml $.Values.global) }} #   ==&gt; &quot;value1: val1 #        value2: val2&quot; <\/code><\/pre>\n<p>  <\/p>\n<h2>\u0412\u043c\u0435\u0441\u0442\u043e \u0437\u0430\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f<\/h2>\n<p>  \u0413\u0435\u043d\u0435\u0440\u0430\u0446\u0438\u044f YAML \u0448\u0430\u0431\u043b\u043e\u043d\u0438\u0437\u0430\u0442\u043e\u0440\u0430\u043c\u0438, \u0434\u0430 \u0435\u0449\u0451 \u0438 \u043d\u0435 \u0441\u0430\u043c\u044b\u043c\u0438 \u0443\u0434\u0430\u0447\u043d\u044b\u043c\u0438, \u0434\u0430 \u0435\u0449\u0451 \u0438 \u0448\u0430\u0431\u043b\u043e\u043d\u0438\u0437\u0430\u0442\u043e\u0440\u0430\u043c\u0438 \u043e\u0431\u0449\u0435\u0433\u043e \u0442\u043e\u043b\u043a\u0430, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 <i>\u043d\u0435 \u043f\u043e\u043d\u0438\u043c\u0430\u044e\u0442<\/i> YAML, \u2014 \u044d\u0442\u043e, \u043f\u043e \u043c\u043e\u0435\u043c\u0443 \u0441\u043a\u0440\u043e\u043c\u043d\u043e\u043c\u0443 \u043c\u043d\u0435\u043d\u0438\u044e, \u0437\u043d\u0430\u0447\u0438\u0442, \u0447\u0442\u043e \u043c\u044b \u0441\u0432\u0435\u0440\u043d\u0443\u043b\u0438 \u043a\u0443\u0434\u0430-\u0442\u043e \u043d\u0435 \u0442\u0443\u0434\u0430. YAML \u043d\u0435 \u0431\u044b\u043b \u043f\u0440\u0435\u0434\u043d\u0430\u0437\u043d\u0430\u0447\u0435\u043d \u0434\u043b\u044f \u0442\u043e\u0433\u043e, \u0447\u0442\u043e\u0431\u044b \u043e\u043d \u0433\u0435\u043d\u0435\u0440\u0438\u0440\u043e\u0432\u0430\u043b\u0441\u044f \u043a\u0430\u043a \u0442\u0435\u043a\u0441\u0442 \u0438\u0437 \u0448\u0430\u0431\u043b\u043e\u043d\u0430, \u0438 \u043c\u043d\u0435 \u0442\u043e\u0436\u0435 \u043e\u0447\u0435\u043d\u044c \u0433\u0440\u0443\u0441\u0442\u043d\u043e \u043e\u0442 \u0442\u043e\u0433\u043e, \u043d\u0430\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u043f\u043e\u0432\u0441\u0435\u043c\u0435\u0441\u0442\u043d\u043e\u0439 (\u0438 \u043d\u0435\u0443\u043c\u0435\u0441\u0442\u043d\u043e\u0439) \u044d\u0442\u0430 \u043f\u0440\u0430\u043a\u0442\u0438\u043a\u0430 \u0441\u0442\u0430\u043b\u0430. \u041a\u0430\u043a \u0431\u044b \u0442\u0430\u043c \u043d\u0438 \u0431\u044b\u043b\u043e, \u0447\u0430\u0441\u0442\u043e \u043f\u0440\u0438\u0445\u043e\u0434\u0438\u0442\u0441\u044f \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u0441 \u0442\u0435\u043c, \u0447\u0442\u043e \u0438\u043c\u0435\u0435\u043c, \u0438 \u0432 \u044d\u0442\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0435 \u0431\u044b\u043b\u0438 \u043f\u043e\u043a\u0430\u0437\u0430\u043d\u044b \u0441\u043f\u043e\u0441\u043e\u0431\u044b \u0432\u044b\u0436\u0430\u0442\u044c \u0438\u0437 Helm-\u0448\u0430\u0431\u043b\u043e\u043d\u043e\u0432 \u043c\u0430\u043a\u0441\u0438\u043c\u0443\u043c \u0433\u0438\u0431\u043a\u043e\u0441\u0442\u0438 \u0438 \u0434\u0438\u043d\u0430\u043c\u0438\u043a\u0438.<\/p>\n<p>  \u0427\u0443\u0432\u0441\u0442\u0432\u0443\u0435\u0442\u0435, \u0447\u0442\u043e \u0434\u0430\u0436\u0435 \u044d\u0442\u043e\u0433\u043e \u043d\u0435 \u0445\u0432\u0430\u0442\u0430\u0435\u0442, \u0447\u0442\u043e\u0431\u044b \u0434\u0435\u0440\u0436\u0430\u0442\u044c \u0447\u0430\u0440\u0442\u044b \u043e\u0431\u0441\u043b\u0443\u0436\u0438\u0432\u0430\u0435\u043c\u044b\u043c\u0438 \u0438 \u0440\u0430\u0441\u0448\u0438\u0440\u044f\u0435\u043c\u044b\u043c\u0438? \u0422\u043e\u0433\u0434\u0430, \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e, \u0441\u0442\u043e\u0438\u0442 \u0437\u0430\u0434\u0443\u043c\u0430\u0442\u044c\u0441\u044f \u043e \u0442\u043e\u043c, \u0447\u0442\u043e\u0431\u044b \u0433\u0435\u043d\u0435\u0440\u0438\u0440\u043e\u0432\u0430\u0442\u044c YAML \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u043d\u043e, \u043f\u043e\u0434\u0441\u0442\u0430\u0432\u043b\u044f\u044f \u0433\u0435\u043d\u0435\u0440\u0438\u0440\u0443\u0435\u043c\u044b\u0435 \u043c\u0430\u043d\u0438\u0444\u0435\u0441\u0442\u044b \u043f\u043e\u0434\u043e\u0431\u043d\u043e \u0442\u043e\u043c\u0443, \u043a\u0430\u043a \u044d\u0442\u043e \u0434\u0435\u043b\u0430\u0435\u0442\u0441\u044f \u0432 \u041f\u041e, \u043e\u0442\u0432\u0435\u0447\u0430\u044e\u0449\u0435\u043c \u0437\u0430 \u0440\u0430\u0437\u0432\u0435\u0440\u0442\u044b\u0432\u0430\u043d\u0438\u0435. \u041c\u043e\u0436\u043d\u043e \u043f\u0440\u0438\u0432\u0435\u0441\u0442\u0438 <a href=\"https:\/\/github.com\/awslabs\/cdk8s\">cdk8s<\/a> \u043a\u0430\u043a \u043f\u0440\u0438\u043c\u0435\u0440 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u043d\u043e\u0439 \u0433\u0435\u043d\u0435\u0440\u0430\u0446\u0438\u0438 YAML: \u043f\u0443\u0441\u0442\u044c \u043e\u043d\u043e \u0435\u0449\u0451 \u0438 \u0432\u0435\u0441\u044c\u043c\u0430 \u0441\u044b\u0440\u043e\u0435, \u0441\u0430\u043c\u0443 \u0438\u0434\u0435\u044e \u043d\u0430\u0433\u043b\u044f\u0434\u043d\u043e \u0434\u0435\u043c\u043e\u043d\u0441\u0442\u0440\u0438\u0440\u0443\u0435\u0442. \u0418 \u043f\u043e\u043a\u0430 \u0441\u0432\u0435\u0442\u043b\u043e\u0435 \u0431\u0443\u0434\u0443\u0449\u0435\u0435 \u0431\u0435\u0437 YAML-\u0448\u0430\u0431\u043b\u043e\u043d\u0438\u0437\u0430\u0446\u0438\u0438 \u043d\u0435 \u043d\u0430\u0441\u0442\u0443\u043f\u0438\u043b\u043e, \u043d\u0430\u043c \u043d\u0435 \u0434\u043e\u043b\u0436\u043d\u043e \u0431\u044b\u0442\u044c \u0441\u0442\u044b\u0434\u043d\u043e \u0437\u0430 \u0442\u043e, \u0447\u0442\u043e \u043c\u044b \u044d\u043a\u0441\u043f\u043b\u0443\u0430\u0442\u0438\u0440\u0443\u0435\u043c \u0448\u0430\u0431\u043b\u043e\u043d\u0438\u0437\u0430\u0442\u043e\u0440\u044b, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0443\u0436\u0435 \u043e\u0447\u0435\u043d\u044c \u0434\u0430\u0432\u043d\u043e \u044d\u043a\u0441\u043f\u043b\u0443\u0430\u0442\u0438\u0440\u0443\u044e\u0442 \u043d\u0430\u0441.<\/p>\n<h2>P.S.<\/h2>\n<p>  \u0427\u0438\u0442\u0430\u0439\u0442\u0435 \u0442\u0430\u043a\u0436\u0435 \u0432 \u043d\u0430\u0448\u0435\u043c \u0431\u043b\u043e\u0433\u0435:<\/p>\n<ul>\n<li> \u00ab<a href=\"https:\/\/habr.com\/ru\/company\/flant\/blog\/423239\/\">\u0421\u043e\u0437\u0434\u0430\u043d\u0438\u0435 \u043f\u0430\u043a\u0435\u0442\u043e\u0432 \u0434\u043b\u044f Kubernetes \u0441 Helm: \u0441\u0442\u0440\u0443\u043a\u0442\u0443\u0440\u0430 \u0447\u0430\u0440\u0442\u0430 \u0438 \u0448\u0430\u0431\u043b\u043e\u043d\u0438\u0437\u0430\u0446\u0438\u044f<\/a>\u00bb;<\/li>\n<li> \u00ab<a href=\"https:\/\/habr.com\/ru\/company\/flant\/blog\/420437\/\">\u041f\u0440\u0430\u043a\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0435 \u0437\u043d\u0430\u043a\u043e\u043c\u0441\u0442\u0432\u043e \u0441 \u043f\u0430\u043a\u0435\u0442\u043d\u044b\u043c \u043c\u0435\u043d\u0435\u0434\u0436\u0435\u0440\u043e\u043c \u0434\u043b\u044f Kubernetes \u2014 Helm<\/a>\u00bb.<\/li>\n<\/ul>\n<\/div>\n<p> \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"https:\/\/habr.com\/ru\/company\/flant\/blog\/529158\/\"> https:\/\/habr.com\/ru\/company\/flant\/blog\/529158\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"\n<div class=\"post__text post__text-html post__text_v1\" id=\"post-content-body\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/ci\/cl\/mk\/ciclmkkss_ijl1_dbsjfv6brgmo.png\"><\/p>\n<p>  \u0421\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u043e\u0439 Helm-\u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 \u0438 \u043f\u0440\u0438\u0432\u044b\u0447\u043d\u044b\u0445 \u043f\u043e\u0434\u0445\u043e\u0434\u043e\u0432 \u043a \u043d\u0430\u043f\u0438\u0441\u0430\u043d\u0438\u044e Helm-\u0447\u0430\u0440\u0442\u043e\u0432 \u043e\u0431\u044b\u0447\u043d\u043e \u0445\u0432\u0430\u0442\u0430\u0435\u0442 \u0434\u043b\u044f \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0437\u0430\u0446\u0438\u0438 \u043d\u0435\u0441\u043b\u043e\u0436\u043d\u044b\u0445 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0439. \u041d\u043e \u043a\u043e\u0433\u0434\u0430 \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e \u0438 \u0441\u043b\u043e\u0436\u043d\u043e\u0441\u0442\u044c Helm-\u0447\u0430\u0440\u0442\u043e\u0432 \u0440\u0430\u0441\u0442\u0443\u0442, \u0442\u043e \u043c\u0438\u043d\u0438\u043c\u0430\u043b\u0438\u0441\u0442\u0438\u0447\u043d\u044b\u0445 Go-\u0448\u0430\u0431\u043b\u043e\u043d\u043e\u0432 \u0438 \u043d\u0435\u043e\u0434\u043d\u043e\u0437\u043d\u0430\u0447\u043d\u043e\u0439 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u043e\u0439 Helm-\u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 \u0431\u044b\u0441\u0442\u0440\u043e \u043f\u0435\u0440\u0435\u0441\u0442\u0430\u0451\u0442 \u0445\u0432\u0430\u0442\u0430\u0442\u044c. \u0412 \u044d\u0442\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0435 \u0440\u0435\u0447\u044c \u043f\u043e\u0439\u0434\u0435\u0442 \u043e \u0442\u043e\u043c, \u043a\u0430\u043a \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0432\u0430\u0448\u0438 Helm-\u0448\u0430\u0431\u043b\u043e\u043d\u044b \u0433\u043e\u0440\u0430\u0437\u0434\u043e \u0431\u043e\u043b\u0435\u0435 \u0433\u0438\u0431\u043a\u0438\u043c\u0438 \u0438 \u0434\u0438\u043d\u0430\u043c\u0438\u0447\u043d\u044b\u043c\u0438, \u0440\u0435\u0430\u043b\u0438\u0437\u0443\u044f \u0441\u0432\u043e\u0438 \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u0435 \u00ab\u0444\u0443\u043d\u043a\u0446\u0438\u0438\u00bb \u0432 Helm, \u0430 \u0442\u0430\u043a\u0436\u0435 \u044d\u043a\u0441\u043f\u043b\u0443\u0430\u0442\u0438\u0440\u0443\u044f <code>tpl<\/code>.<\/p>\n<p>  <i><b>NB<\/b>. \u0412\u0441\u0451 \u043e\u043f\u0438\u0441\u0430\u043d\u043d\u043e\u0435 \u0431\u044b\u043b\u043e \u043f\u0440\u043e\u0432\u0435\u0440\u0435\u043d\u043e \u0441 <a href=\"https:\/\/ru.werf.io\/\">werf<\/a>, \u043d\u043e \u0442\u0430\u043a \u043a\u0430\u043a \u0448\u0430\u0431\u043b\u043e\u043d\u044b \u0432 \u044d\u0442\u043e\u0439 \u0443\u0442\u0438\u043b\u0438\u0442\u0435 \u043f\u0440\u0430\u043a\u0442\u0438\u0447\u0435\u0441\u043a\u0438 \u0438\u0434\u0435\u043d\u0442\u0438\u0447\u043d\u044b Helm-\u0448\u0430\u0431\u043b\u043e\u043d\u0430\u043c, \u0442\u043e \u0438 \u0432\u0441\u0451 \u043d\u0438\u0436\u0435\u043f\u0440\u0438\u0432\u0435\u0434\u0435\u043d\u043d\u043e\u0435 \u0431\u0443\u0434\u0435\u0442 \u043f\u043e\u043b\u043d\u043e\u0441\u0442\u044c\u044e \u0438\u043b\u0438 \u043f\u043e\u0447\u0442\u0438 \u043f\u043e\u043b\u043d\u043e\u0441\u0442\u044c\u044e \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u0438\u043c\u043e \u0441 \u043e\u0431\u044b\u0447\u043d\u044b\u043c Helm \u043e\u0431\u0435\u0438\u0445 \u0432\u0435\u0440\u0441\u0438\u0439 (v2 \u0438 v3).<\/i><\/p>\n<p>  \u0410 \u0442\u0435\u043f\u0435\u0440\u044c \u0440\u0430\u0437\u0431\u0435\u0440\u0435\u043c, \u043a\u0430\u043a \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u043e\u0442 Helm-\u0448\u0430\u0431\u043b\u043e\u043d\u043e\u0432 \u0432\u0441\u0451, \u0447\u0442\u043e \u043c\u043e\u0436\u043d\u043e\u2026 \u0438 \u0434\u0430\u0436\u0435 \u0432\u0441\u0451, \u0447\u0442\u043e \u043d\u0435\u043b\u044c\u0437\u044f!<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-314193","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/314193","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=314193"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/314193\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=314193"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=314193"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=314193"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}