Skip to content
This repository has been archived by the owner on Apr 14, 2021. It is now read-only.

Bundlers shows root warning on Windows #2984

Closed
luislavena opened this issue Apr 16, 2014 · 6 comments
Closed

Bundlers shows root warning on Windows #2984

luislavena opened this issue Apr 16, 2014 · 6 comments

Comments

@luislavena
Copy link
Member

Environment information:

  • ruby 2.0.0p451 (2014-02-24) [x64-mingw32]
  • Bundler version 1.6.2

It shows the following warning when using on Windows:

Don't run Bundler as root. Bundler can ask for sudo if it is needed, and
installing your bundle as root will break this application for all non-root
users on this machine.

Bundler uses Process.uid to determine if current process is run by root, but the problem is Ruby on Windows Process.uid always return 0:

C:\Users\Luis>ruby -ve "p Process.gid"
ruby 2.0.0p451 (2014-02-24) [x64-mingw32]
0

Independently of the current user.

I believe an extra check about the platform will be enough to avoid this warning.

@indirect
Copy link
Member

oh no :( thanks for letting us know!

On Tue, Apr 15, 2014 at 5:39 PM, Luis Lavena [email protected]
wrote:

Environment information:

  • ruby 2.0.0p451 (2014-02-24) [x64-mingw32]
  • Bundler version 1.6.2
    It shows the following warning when using on Windows:
Don't run Bundler as root. Bundler can ask for sudo if it is needed, and
installing your bundle as root will break this application for all non-root
users on this machine.

Bundler uses Process.uid to determine if current process is run by root, but the problem is Ruby on Windows Process.uid always return 0:

C:\Users\Luis>ruby -ve "p Process.gid"
ruby 2.0.0p451 (2014-02-24) [x64-mingw32]
0

Independently of the current user.

I believe an extra check about the platform will be enough to avoid this warning.

Reply to this email directly or view it on GitHub:
#2984

indirect added a commit that referenced this issue Apr 16, 2014
@luislavena
Copy link
Member Author

@indirect thank you! ❤️ ❤️ ❤️

@andregriffin
Copy link

Why does 1.6.3 not show up anywhere? gem install still uses 1.6.2 on windows.

@luislavena
Copy link
Member Author

@andregriffin there is no 1.6.3 tag or release or yanked gem.

@indirect
Copy link
Member

We haven’t actually released it yet. 😳 I’ll try to do it tonight!

On May 20, 2014, at 10:29 PM, Luis Lavena [email protected] wrote:

@andregriffin there is no 1.6.3 tag or release or yanked gem.


Reply to this email directly or view it on GitHub.

@andregriffin
Copy link

Ah, no worries. I must have forgotten that I manually added this commit this in my last env, and saw the changelog this time and thought I was missing something. Thanks!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants