diff options
author | OpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com> | 2021-02-01 12:45:11 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-02-01 12:45:11 -0500 |
commit | 182e8414d406d3058e985104af98f30a9e8f56fa (patch) | |
tree | 7ce06e9fab81e63476b43bcefa746520abdf7b91 /pkg/systemd/generate/containers.go | |
parent | 20183349fd2c6a9a569c6c79234af48bb5d92ff7 (diff) | |
parent | 5352df226bc3f345836e78b73063de91d34b4e85 (diff) | |
download | podman-182e8414d406d3058e985104af98f30a9e8f56fa.tar.gz podman-182e8414d406d3058e985104af98f30a9e8f56fa.tar.bz2 podman-182e8414d406d3058e985104af98f30a9e8f56fa.zip |
Merge pull request #9178 from Luap99/fix-9176
Fix podman generate systemd --new special char handling
Diffstat (limited to 'pkg/systemd/generate/containers.go')
-rw-r--r-- | pkg/systemd/generate/containers.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/pkg/systemd/generate/containers.go b/pkg/systemd/generate/containers.go index 5f52b0a77..abe159812 100644 --- a/pkg/systemd/generate/containers.go +++ b/pkg/systemd/generate/containers.go @@ -204,7 +204,7 @@ func executeContainerTemplate(info *containerInfo, options entities.GenerateSyst startCommand := []string{info.Executable} if index > 2 { // include root flags - info.RootFlags = strings.Join(quoteArguments(info.CreateCommand[1:index-1]), " ") + info.RootFlags = strings.Join(escapeSystemdArguments(info.CreateCommand[1:index-1]), " ") startCommand = append(startCommand, info.CreateCommand[1:index-1]...) } startCommand = append(startCommand, @@ -279,7 +279,7 @@ func executeContainerTemplate(info *containerInfo, options entities.GenerateSyst } } startCommand = append(startCommand, remainingCmd...) - startCommand = quoteArguments(startCommand) + startCommand = escapeSystemdArguments(startCommand) info.ExecStartPre = "/bin/rm -f {{{{.PIDFile}}}} {{{{.ContainerIDFile}}}}" info.ExecStart = strings.Join(startCommand, " ") |