Make juju run on machines use the ubuntu user #6873

Merged
merged 4 commits into from Jan 26, 2017

Conversation

Projects
None yet
3 participants
Owner

howbazaar commented Jan 26, 2017

With the 2.0 change to how 'juju run' was processed to use the actions infrastructure rather than ssh from the controllers, the machine execution changed from running using the ubuntu user to being executed as root without some login environment variables processed.

QA steps

$ juju run --machine 0 env
$ juju run --machine 0 juju-goroutines

Bug reference

Fixes lp:1655124

mjs approved these changes Jan 26, 2017

worker/machineactions/handleactions.go
@@ -40,6 +43,7 @@ func HandleAction(name string, params map[string]interface{}) (results map[strin
func handleJujuRunAction(params map[string]interface{}) (results map[string]interface{}, err error) {
// The spec checks that the parameters are available so we don't need to check again here
command, _ := params["command"].(string)
+ logger.Debugf("juju run %q", command)
@mjs

mjs Jan 26, 2017

Contributor

Maybe trace?

And what about potentially sensitive things on the command line?

@howbazaar

howbazaar Jan 26, 2017

Owner

OK, I can live with trace. Standard practice is to not put sensitive things on the command line :) As that stuff goes into history files.

Owner

howbazaar commented Jan 26, 2017

$$merge$$

Contributor

jujubot commented Jan 26, 2017

Status: merge request accepted. Url: http://juju-ci.vapour.ws:8080/job/github-merge-juju

Contributor

jujubot commented Jan 26, 2017

Build failed: Tests failed
build url: http://juju-ci.vapour.ws:8080/job/github-merge-juju/10116

Owner

howbazaar commented Jan 26, 2017

$$windows-mongo-suckage$$

Contributor

jujubot commented Jan 26, 2017

Status: merge request accepted. Url: http://juju-ci.vapour.ws:8080/job/github-merge-juju

@jujubot jujubot merged commit 07102c0 into juju:2.1 Jan 26, 2017

1 check failed

github-check-merge-juju Built PR, ran unit tests, and tested LXD deploy. Use !!.*!! to request another build. IE, !!build!!, !!retry!!
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment