mirror of
https://github.com/kemko/nomad.git
synced 2026-01-06 10:25:42 +03:00
api: handle newlines in JobSubmission vars correctly (#23560)
Fixes a bug where variable values in job submissions that contained newlines weren't encoded correctly, and thus jobs that contained them couldn't be resumed once stopped via the UI. Internal ref: https://hashicorp.atlassian.net/browse/NET-9966
This commit is contained in:
committed by
GitHub
parent
75722ef93e
commit
fa8ffedd74
@@ -908,6 +908,8 @@ func apiJobSubmissionToStructs(submission *api.JobSubmission) *structs.JobSubmis
|
||||
if submission == nil {
|
||||
return nil
|
||||
}
|
||||
|
||||
submission.Canonicalize()
|
||||
return &structs.JobSubmission{
|
||||
Source: submission.Source,
|
||||
Format: submission.Format,
|
||||
|
||||
Reference in New Issue
Block a user