title: Kubernetes Kustomize: replace variable in patch file
body: <p>Given the following kustomize patch:</p>
  
  <pre><code>apiVersion: apps/v1
  kind: Deployment
  metadata:
    name: flux
  spec:
    template:
      spec:
        containers:
          - name: some-name
            args:
              - --some-key=some-value
              ...
              - --git-url=https://user:${PASSWORD}@domain.de
  </code></pre>
  
  <p>I want to use <code>kubectl apply -k</code> and somehow pass a value for <code>${PASSWORD}</code> which I can set from my build script. </p>
  
  <p>The only solution I got to work so far was replacing the <code>${PASSWORD}</code> with <code>sed</code>, but I would prefer a kustomize solution.</p>