Vagrant installation librarian-chef command error No such file or directory @ rb_sysopen

237 Views Asked by At

I am trying to install vagrant. When I am trying to run a command librarian-chef install I am facing an Error. I am pasting the error below.

/home/saiteja/.rvm/gems/ruby-2.2.3/gems/librarian-0.1.2/lib/librarian/dsl/receiver.rb:29:in `read': No such file or directory @ rb_sysopen - /home/saiteja/Cheffile (Errno::ENOENT)
from /home/saiteja/.rvm/gems/ruby-2.2.3/gems/librarian-0.1.2/lib/librarian/dsl/receiver.rb:29:in `run'
from /home/saiteja/.rvm/gems/ruby-2.2.3/gems/librarian-0.1.2/lib/librarian/dsl.rb:79:in `block in run'
from /home/saiteja/.rvm/gems/ruby-2.2.3/gems/librarian-0.1.2/lib/librarian/dsl.rb:73:in `tap'
from /home/saiteja/.rvm/gems/ruby-2.2.3/gems/librarian-0.1.2/lib/librarian/dsl.rb:73:in `run'
from /home/saiteja/.rvm/gems/ruby-2.2.3/gems/librarian-0.1.2/lib/librarian/dsl.rb:17:in `run'
from /home/saiteja/.rvm/gems/ruby-2.2.3/gems/librarian-0.1.2/lib/librarian/environment.rb:148:in `dsl'
from /home/saiteja/.rvm/gems/ruby-2.2.3/gems/librarian-0.1.2/lib/librarian/specfile.rb:15:in `read'
from /home/saiteja/.rvm/gems/ruby-2.2.3/gems/librarian-0.1.2/lib/librarian/action/resolve.rb:13:in `run'
from /home/saiteja/.rvm/gems/ruby-2.2.3/gems/librarian-0.1.2/lib/librarian/cli.rb:169:in `resolve!'
from /home/saiteja/.rvm/gems/ruby-2.2.3/gems/librarian-chef-0.0.4/lib/librarian/chef/cli.rb:41:in `install'
from /home/saiteja/.rvm/gems/ruby-2.2.3/gems/thor-0.19.1/lib/thor/command.rb:27:in `run'
from /home/saiteja/.rvm/gems/ruby-2.2.3/gems/thor-0.19.1/lib/thor/invocation.rb:126:in `invoke_command'
from /home/saiteja/.rvm/gems/ruby-2.2.3/gems/thor-0.19.1/lib/thor.rb:359:in `dispatch'
from /home/saiteja/.rvm/gems/ruby-2.2.3/gems/thor-0.19.1/lib/thor/base.rb:440:in `start'
from /home/saiteja/.rvm/gems/ruby-2.2.3/gems/librarian-0.1.2/lib/librarian/cli.rb:26:in `block (2 levels) in bin!'
from /home/saiteja/.rvm/gems/ruby-2.2.3/gems/librarian-0.1.2/lib/librarian/cli.rb:31:in `returning_status'
from /home/saiteja/.rvm/gems/ruby-2.2.3/gems/librarian-0.1.2/lib/librarian/cli.rb:26:in `block in bin!'
from /home/saiteja/.rvm/gems/ruby-2.2.3/gems/librarian-0.1.2/lib/librarian/cli.rb:47:in `with_environment'
from /home/saiteja/.rvm/gems/ruby-2.2.3/gems/librarian-0.1.2/lib/librarian/cli.rb:26:in `bin!'
from /home/saiteja/.rvm/gems/ruby-2.2.3/gems/librarian-chef-0.0.4/bin/librarian-chef:7:in `<top (required)>'
from /home/saiteja/.rvm/gems/ruby-2.2.3/bin/librarian-chef:23:in `load'
from /home/saiteja/.rvm/gems/ruby-2.2.3/bin/librarian-chef:23:in `<main>'
from /home/saiteja/.rvm/gems/ruby-2.2.3/bin/ruby_executable_hooks:15:in `eval'
from /home/saiteja/.rvm/gems/ruby-2.2.3/bin/ruby_executable_hooks:15:in `<main>'

I googled it. I understood that it is some kind of path error. But I checked the path .rvm/* that is shown in error. Any help is appreciated. Thank you.

1

There are 1 best solutions below

0
On

The problem is that , we first need to install vagrant. Then we need to clone the project we need to work on git clone http://-----.There we need to perform vagrant up and vagrant ssh.

Now we are in the vagrant environment. Here we need to install our rails and ruby in order to work with the project independent of our local system (Here persons working on the same project must install same versions of them in order to work).

Perform the installation of ruby through rvm (or) rbenv and install rails. Then we need to use the command librarian-chef install, then it installs all the required gems to the directory you are working without any problem.