Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(431)

Unified Diff: upstart/upstart.go

Issue 8797046: upstart: add support for the limit verb (Closed)
Patch Set: upstart: add support for the limit verb Created 10 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Please Sign in to add in-line comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « [revision details] ('k') | upstart/upstart_test.go » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: upstart/upstart.go
=== modified file 'upstart/upstart.go'
--- upstart/upstart.go 2013-03-14 10:22:37 +0000
+++ upstart/upstart.go 2013-04-27 04:24:55 +0000
@@ -96,6 +96,8 @@
normal exit 0
{{range $k, $v := .Env}}env {{$k}}={{$v|printf "%q"}}
{{end}}
+{{range $k, $v := .Limit}}limit {{$k}} {{$v|printf "%s"}}
+{{end}}
exec {{.Cmd}}{{if .Out}} >> {{.Out}} 2>&1{{end}}
`[1:]))
@@ -107,6 +109,8 @@
Desc string
// Env holds the environment variables that will be set when the command runs.
Env map[string]string
+ // Limit holds the ulimit values that will be set when the command runs.
+ Limit map[string]string
// Cmd is the command (with arguments) that will be run.
// The command will be restarted if it exits with a non-zero exit code.
Cmd string
« no previous file with comments | « [revision details] ('k') | upstart/upstart_test.go » ('j') | no next file with comments »

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b