r/ruby • u/Fletcher_Gilstrap • Jun 28 '26
Question Ruby on Rails in Manjaro
Hello Reddit. I am new to Manjaro, and was hoping to set up a development environment in RoR. I was following the directions on the Arch wiki, and I noticed my gems are being installed to usr/lib/ruby/gems. When running a bundle install, it now seems to want to write to usr/bin, and fails because it doesnt have permissions. Should I go ahead and grant permissions, or is this not advisable?
2
Upvotes
12
u/BeneficiallyPickle Jun 28 '26
I'd suggest in using some kind of version manager. I personally use rbenv, but I've heard good things about mise. Your gems and Bundler executables will then live under your home directory, so bundle install won't need root permissions.
4
u/Interesting_Ad6562 Jun 28 '26
Use docker or the new-ish devcontainers. Rails even comes with a generator for a devcontainers setup.
Works flawlessly and I haven't had any issues with it. VS Code only though, which is a shame.
7
u/__vivek Jun 28 '26
That's your system ruby. Install ruby via mise.
3
u/snarfmason Jun 28 '26 edited Jun 28 '26
You can - and this case should IMO - tell bundler to use a local path.
I think it's like:
bundle install --path vendor/bundle
Or maybe you need explicit:
bundle config --local path vendor/bundle
Then plain bundle install
1
u/armahillo Jun 28 '26
look up “ruby version manager”
i used “asdf” but there are many different ones