helm cli๋ ์ค์น ๋๋ ์ ๊ทธ๋ ์ด๋๋ฅผ ์ํด ์ค์ ๋ ํ๋๊ทธ์ ์ผํ๊ฐ ํฌํจ ๋ ๊ฐ์ ์ง์ํ์ง ์๋ ๊ฒ ๊ฐ์ต๋๋ค.
$ helm install --set greeting='hello, world' .
Error: failed parsing --set data: key " world" has no value
ํ์๊ฐ ๊ฐ์์ ์ผํ๋ฅผ ์ฐพ์ผ๋ฉด ์ถ๊ฐ ํค๋ฅผ ์ฐพ์ผ๋ ค๊ณ ํ๋ ๊ฒ ๊ฐ์ต๋๋ค. ๋ช ๊ฐ์ง ์ธ์ฉ ๋๋ ์ด์ค์ผ์ดํ ์ ๋ต์ ์๋ํ์ง๋ง ๋ชจ๋ ๋์ผํ ๋ฌธ์ ๊ฐ์๋ ๊ฒ ๊ฐ์ต๋๋ค.
$ helm install --set greeting="hello, world" .
Error: failed parsing --set data: key " world" has no value
$ helm install --set "greeting=hello, world" .
Error: failed parsing --set data: key " world" has no value
$ helm install --set greeting=hello,\ world .
Error: failed parsing --set data: key " world" has no value
ํด๊ฒฐ ๋ฐฉ๋ฒ์ set ํ๋๊ทธ ๋์ ๊ฐ ํ์ผ์ ์ฌ์ฉํ๋ ๊ฒ์ด์ง๋ง ๊ตฌ์ฑ ํ์ผ์ configmap์ผ๋ก ์ ๋ฌํ๋ ์ฌ์ฉ ์ฌ๋ก์ ๊ฒฝ์ฐ ๊ตฌ์ฑ ํ์ผ์ ๊ฐ๋ณ์ ์ผ๋ก ๊ด๋ฆฌํ๊ณ ์ด๋ฅผ ์ ์ฅํ๋ ๊ฒ๋ณด๋ค ์ธํธ ํ๋๊ทธ๋ก ๋ถ๋ฅํ๋ ๊ฒ์ด ๋ ์ฝ๊ณ ๊น๋ํฉ๋๋ค. yaml ๋ํผ ๋๋ ์ฆ์ ํด๋น ๋ํผ๋ฅผ ๊ตฌ์ฑํฉ๋๋ค.
\,
์ ์๋ํฉ๋๋ค.
><> helm template chart/draftd/ --set image.tag="hello\, world" | grep hello
image: "microsoft/draft:hello, world"
์ด๊ฒ์ https://docs.helm.sh/using_helm/#the -format-and-limitations-of-set์ ์ค๋ช ์์ ๋์ ์์ผ๋ฏ๋ก ํด๊ฒฐ ๋๋๋ก ๋ซ๊ฒ ์ต๋๋ค. ํด๋น ์์ ์ฌํญ์ด ์๋ํ์ง ์์ผ๋ฉด ๋ค์์ฌ์ญ์์ค. ๊ฐ์ฌ!
ํ , ์ผํ๋ฅผ ์ด์ค์ผ์ดํ ํด๋ณด๊ฒ ๋ค๊ณ ๋งน์ธ ํ ์ ์์์ง๋ง ๋ฒ์ 2.4.0์ผ๋ก ๋ค์ ํ์ธํ๊ณ ๋ชจ๋์์ ์๋ํ์ต๋๋ค. ๋๋ ๋ถ๋ช ํ ์ฐฉ๊ฐํ๋ค.
๋ด๊ฐ ํ ๊ฒ์ฒ๋ผ Google์ ํตํด ๋ค๋ฅธ ์ฌ๋์ด์ด ๋ฌธ์ ๋ฅผ ๋ฐ๊ฒฌํ๋ฉด Helm 2์ --set
๋ฌธ์์ ๋ํ ์
๋ฐ์ดํธ ๋ ๋งํฌ๋ ๋ค์๊ณผ ๊ฐ์ต๋๋ค. https://v2.helm.sh/docs/using_helm/#the -format-and -์ค์ ์ ํ๊ณ
๊ฐ์ฅ ์ ์ฉํ ๋๊ธ
\,
์ ์๋ํฉ๋๋ค.