On 27/01/14 08:13, Tim Penhey wrote:
> On 26/01/14 19:28, Andrew Wilkins wrote:
>> On Sat, Jan 25, 2014 at 11:17 PM, Curtis Hovey-Canonical
>> <cur...@canonical.com <mailto:cur...@canonical.com>> wrote:
>>     CI sees this on when is uses 1.17.1 juju to boostrap:
>>
>>     juju --debug bootstrap -e local --constraints mem=2G 2>&1 | tee
>>     bootstrap.log
>>     2014-01-25 14:51:09 DEBUG juju.environs.configstore disk.go:77 Making
>>     /var/lib/jenkins/juju-ci/environments
>>     2014-01-25 14:51:09 DEBUG juju.environs.configstore disk.go:67 Making
>>     /var/lib/jenkins/juju-ci/environments/local.jenv owned by 1000:1000
>>     2014-01-25 14:51:09 ERROR juju.cmd supercommand.go:294 cannot create
>>     new info for environment "local": chown
>>     /var/lib/jenkins/juju-ci/environments/local.jenv: operation not
>>     permitted
>>
>>
>> This looks like it's still running under sudo. Is that the case? (I see
>> it's not in the command line, but is this a script that is run under sudo?)
>> The "Making ... owned by 1000:1000" line shouldn't be there.
> 
> Looking at the code a little more, and poking the command line, if the
> script uses sudo to run something as another user, we would see
> something like this, as the SUDO_UID and SUDO_GID are set but we are not
> running as root, so if the current user would not be able to chown to a
> different user.
> 
> As mentioned before, this really isn't needed any more with the changes
> that landed last week.


 https://codereview.appspot.com/51150044/

I tested this locally as I have two different users on my laptop.

Going:
  sudo su thumper

I was then running as thumper but SUDO_GID was set.

I was able to bootstrap a local environment as thumper.

Tim

-- 
Juju-dev mailing list
Juju-dev@lists.ubuntu.com
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/juju-dev

Reply via email to