Documentation
¶
Overview ¶
Package flagfolder parses a folder on the disk as if each file in it had the contents of a command line flag.
This is mainly intended to be used with environments like Kubernetes where you have your secrets mounted as a filesystem.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Parse ¶
func Parse()
Parse parses all files in every folder under /run/secrets as if they were command-line flags.
This is most useful when you are using environments like Kubernetes where the path of least resistance is to mount your secrets as a filesystem. Mount all your secrets into the pod and then let it figure itself out!
To use this effectively, ensure that your Pods and Deployments mount secrets as volumes like this:
volumes: - name: secret-volume secret: secretName: shell containers: - name: shell image: ubuntu:latest volumeMounts: - name: secret-volume readOnly: true mountPath: "/run/secrets/shell"
By default this will attempt to correct for several styles of naming for files:
* kebab-case (the default) * SHOUTING-KEBAB-CASE * snake_case * SHOUTING_SNAKE_CASE * camelCase * HammerCase
Types ¶
This section is empty.