FileKeySelectorV1
Classsealednet10.0
Selects a key from an environment variable file in a pod's emptyDir volume.
namespace Aspire.Hosting.Kubernetes.Resources;
public sealed class FileKeySelectorV1{ // ...}5 members
Remarks
Section titled Remarks Requires Kubernetes 1.34 or later with the EnvFiles feature enabled. The feature is enabled by default from Kubernetes 1.35. An init container can write the file before the consuming container starts. Changes to the file do not update the environment of a running container.
Constructors1
Section titled ConstructorsProperties4
Section titled PropertiesKeyget; setstring Gets or sets the key whose value is selected from the environment variable file. Keys may contain printable ASCII characters except
=. An invalid key prevents the pod from starting. In Kubernetes 1.34, where EnvFiles is alpha, keys are limited to 128 characters. Optionalget; setbool? Gets or sets whether the file or key may be absent. When true, a missing file or key leaves the environment variable unset. When false or unspecified, a missing file or key prevents the container from starting.
Pathget; setstring Gets or sets the file path relative to the volume root. The path must not contain a parent directory component or start with
... VolumeName get; setstring Gets or sets the name of the emptyDir volume containing the environment variable file.