Donate. I desperately need donations to survive due to my health

Get paid by answering surveys Click here

Click here to donate

Remote/Work from Home jobs

/usr/bin/env: ruby2.1: No such file or directory - WHY?

When I run 'docker-compose up -d abc', I get the following error:

/usr/bin/env: ruby2.1: No such file or directory

Except that NO WHERE is it requesting ruby2.1.

ruby -v returns ruby 1.9.3p547 (2014-05-14 revision 45962) [x86_64-darwin17.6.0] (both in and out of docker-compose). which ruby returns /usr/bin/ruby inside docker-compose.

docker-compose run abc /usr/bin/env returns:

HOSTNAME=29741a2c3c2a
HOME=/root
TERM=xterm
PATH=/local/www/app/current/vendor/bin:/usr/local/sbin:
     /usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
RAILS_ENV=development
INSTALL_PATH=/local/www/app/current
PWD=/local/www/app/current

Nothing about Ruby, and especially nothing looking for version 2.1. Nothing in docker-compose.yml, nothing other in Dockerfile, except where apt-get installs ruby1.9.1 and ruby1.9.1-dev. I've grepped the entire codebase, and nothing wants ruby 2.1. I've checked all the other directories in $PATH, and there are no other ruby versions hiding in there.

I'm so confused right now.

ETA:

If I do docker-compose run abc bash, followed by bundle exec rails server (the command in docker-compose.yaml), I don't get an error, but my application won't load in the browser.

EATA:

I ended up running docker system prune --volumes and deleting my checked-out repository and starting from scratch, and everything is fine again.

Comments