Thursday 15 September 2011

rvm - Vagrant - Rails Not Installed -


I had to destroy and rebuild my horror example recently. Now I can not run any rail order because it says that the rail is not established. I did get the following error

  default: / tmp / vagrant-shell: line when I did  
  ungent  

1: /home/vagrant/.rvm/scripts/rvm: There is no such file or directory

The following SSH command responded with a non-zero exit state. Ugarat believes that it means that the command is unsuccessful!

My Provision.sh file has the following:

  echo "deb http://apt.postgresql.org/pub/ Repos / apt / exact-pgdg main" | Sudo t-a /etc/apt/sources.list.d/pgdg.list sudo wget --quiet -O - https://www.postgresql.org/media/keys/ACCC4CF8.asc | sudo apt-key add - sudo apt-get update sudo apt-get remove PostgreSQL- Client 9.1 PostgreSQL- client-common PostgreSQL- customer PostgreSQL- establishing common -y sudo apt-get PostgreSQL-9.3 PostgreSQL- Client 9.3 libpq- Deva Curl git build -essential libxslt-dev libxml2-dev -y wget -qO- https://toolbelt.heroku.com/install-ubuntu.sh | Sh Curl -Saal https://get.rvm.io | Bash-S Stable -Brube Cat & lt; & Lt; EOF | sudo tee -a /home/vagrant/.bashrc CD / stray EOF echo "#" local "Unix domain socket connections only local all all trust # Aipivi 4 local connections: host all all 127.0.0.1/32 trust # Aipivi 6 local connections: Host everyone: 1/128 Trust '| Sudo tee /etc/postgresql/9.3/main/pg_hba.conf echo 'machine api.heroku.com login ***** password **** machine code.heroku.com login ***** password **** * '| Tee /home/vagrant/.netrc Echo 'ssh-rsa ***** vagreg @ precise32' | T /home/vagrant/.ssh/id_*****.pub chmod 0600 /home/vagrant/.netrc sudo -u postgres psql -c "User ***** Createdb make CreateUser password '***** '; "sudo /etc/init.d/postgresql restart  

I installed rvm while not specific for some answers (Vagrant) suggested that I use as sudo or root Should be done and have seen the need to remove it and then RVM gets it again. I have tried to do this, but I am not sure how this applies to a passionate box and that Mr. As will I get it wrong at the rate that it did not work.

Do I correct / add my provision.sh file or to my Vagrantfile?

After the

Vagrant runs the root file as a root file, then you actually get the form of root until you install rvm you specify otherwise * it was very confusing to me (this will also install things during a novice), I provided and they will "disappear". In fact, they were all set / set as root.

* Or, when you install rvm manually sshed into the machine, which I will touch more below.

you su -c "source /home/vagrant/myapp/vagrant/user-config.sh" vagrant using Switch your user

Do you want to execute any command? In this situation, we are moving a different shell file to user-config.sh which contains all the commands which should not be run as root, such as installing RVM.

I have a misconception of some concepts too. Every time you delete vagreg your entire virtual machine is destroyed, the hard drive and all. The next time you do vagrant up , everything is rebuilt from scratch. If you have installed and installed things, they will no longer be there.

This means that all your installation and config provisioning goes into the file, and you should not install things manually after the fact.

Read once again, I'm hoping that it matters more around this time.


No comments:

Post a Comment