<p>I'm using the following tech:</p>
<ul>
<li>helm</li>
<li>argocd</li>
<li>k8s</li>
</ul>
<p>I created a secret:</p>
<pre><code>╰ kubectl create secret generic my-secret --from-file=my-secret=/Users/superduper/project/src/main/resources/config-file.json --dry-run=client -o yaml
apiVersion: v1
data:
  my-secret: &lt;content&gt;
kind: Secret
metadata:
  creationTimestamp: null
  name: my-secret
</code></pre>
<p>I then added the secret to my pod via a volume mount:</p>
<pre><code>volumeMounts:
  - mountPath: &quot;/etc/config&quot;
    name: config
    readOnly: true
</code></pre>
<pre><code>volumes:
  - name: config
    secret:
    secretName: my-secret
</code></pre>
<p>but the problem is that when i view the /etc/config diretory, the contents shows <code>my-secret</code> under a timestamp directory:</p>
<pre><code>directory:/etc/config/..2021_07_10_20_14_55.980073047
     file:/etc/config/..2021_07_10_20_14_55.980073047/my-secret
</code></pre>
<p>is this normal? is there anyway i can get rid of that timestamp so I can programmatically grab the config secret?</p>

j will
<p>This is the way Kubernetes mounts Secrets and ConfigMaps by default in order to propagate changes downward to those volume mounts if an upstream change occurs. If you would rather not use a symlink and want to forfeit that ability, use the <code>subPath</code> directive and your mount will appear as you wish.</p>
<pre class="lang-yaml prettyprint-override"><code> volumeMounts:
    - mountPath: /etc/config/my-secret
      name: config
      subPath: my-secret
      readOnly: true
  volumes:
    - name: config
      secret:
        secretName: my-secret
</code></pre>
<pre class="lang-sh prettyprint-override"><code>$ k exec alpine -it -- /bin/ash
/ # ls -lah /etc/config/
total 12K
drwxr-xr-x    2 root     root        4.0K Jul 10 22:58 .
drwxr-xr-x    1 root     root        4.0K Jul 10 22:58 ..
-rw-r--r--    1 root     root           9 Jul 10 22:58 my-secret
/ # cat /etc/config/my-secret
hi there
</code></pre>
