Skip to content

Commit

Permalink
fix upstart env_vars handling
Browse files Browse the repository at this point in the history
upstart's use of exec means we have to export the variables loaded from the defaults file. Since we're using the same default file for multiple init styles, it seems cleaner to make this exporting explicit on upstart's side.

refs voxpupuli#150
  • Loading branch information
costela committed Jan 31, 2018
1 parent 65e2f08 commit b72fc0d
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions templates/daemon.upstart.erb
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,9 @@ end script

script
# read settings like GOMAXPROCS from "/etc/default/<%= @name %>", if available.
set -o allexport
[ -e $DEFAULTS ] && . $DEFAULTS
set +o allexport

export GOMAXPROCS=${GOMAXPROCS:-2}
<%- require 'shellwords' -%>
Expand Down

0 comments on commit b72fc0d

Please sign in to comment.