Backport of Add stage_publish_dir field to csi_plugin stanza of a job into release/1.3.x #13965
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Backport
This PR is auto-generated from #13919 to be assessed for backporting due to the inclusion of the label backport/1.3.x.
The below text is copied from the body of the original PR.
Resolves #13263.
This PR adds a new field to the csi_plugin stanza of a job that determines the base (inside a CSI plugin's container) of CSI staging_target_path and target_path directories.
This is my first PR to Nomad. I have attempted to go through the bullets in the checklist below. Some of the bullets are (I think) not applicable. For the docs, I tried to find all locations within /docs where CSI is mentioned and add the field as appropriate.
I updated comments on a couple of fields that I found to be confusing while trying to figure out where and how to get this implemented. I'm obviously open to reverting anything that the maintainers think is not an improvement.
Code
api/
packageapi/
structs usually have Canonicalize and Copy methodsnomad/structs
packagestructs/
structs usually have Copy, Equals, and Validate methodsapi/
packageapi/
andnomad/structs/
incommand/agent/job_endpoint.go
nomad/structs/
toapi/
conversions if necessary and write testsnomad/structs/diff.go
FieldDiff
slices innomad/structs/diff_test.go
scheduler/util.go/tasksUpdated
.Equals
but might not be, check.Docs