0

When my custom buildpack runs it always fails to install gems manually(gem install foo) because it does not have access to the /var/lib/gems directory.

Error being thrown:
ERROR: While executing gem ... (Errno::EACCES) Permission denied - /var/lib/gems


Is there something I have to setup so my buildpack can install gems like this?

Information:
- Server => Ubuntu 14.04 DigitalOcean Dokku image(Latest)
- Custom Buildpack => Noah-Huppert/buildpack-rack

Noah Huppert
  • 4,028
  • 6
  • 36
  • 58

1 Answers1

2

Try this:

sudo chown -R $USER "/var/lib/gems" or

chmod -R 0777 /var/lib/gems if you're comfortable with giving all users on the box read/write permissions.

Marc Rudkowski
  • 278
  • 1
  • 2
  • 10
  • I can't figure out why this isn't working for me... I'm using the jekyll buildpack: https://github.com/dmathieu/heroku-buildpack-jekyll/ – Spencer Alger Nov 04 '16 at 10:07
  • @SpencerAlger you should file a new question in StackOverflow as you don't quite have the same issue (it's not even the same buildpack). – Jose Diaz-Gonzalez Nov 04 '16 at 15:54