Skip to content

Add support for subPathExpr for VolumeMounts in a container #2210

Open
@s-annamalai-fetch

Description

@s-annamalai-fetch

Description

subPathExpr is pretty handy if you want to use values from downwardAPI and use them to mount a specific volume from the host.

Potential Terraform Configuration

resource "kubernetes_deployment" "deployment" {
  ...
          volume_mount {
            name             = "data"
            mount_path       = "/data"
            //sub_path_expr  = "$(POD_NAME)"
          }
  ...
}

References

https://kubernetes.io/docs/concepts/storage/volumes/#using-subpath-expanded-environment

Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    acknowledgedIssue has undergone initial review and is in our work queue.enhancement

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions