Created
April 16, 2013 23:31
-
-
Save wndxlori/5400547 to your computer and use it in GitHub Desktop.
Trying out Vagrant with VMWare provider, and I get this ssh oddness in Capistrano cropping up AFTER the machine provisions (supposedly) perfectly. When I run this with my vagrant machine created with VirtualBox provider, it runs fine. What gives? Where is that bogus '\\' coming from?
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ cap deploy:setup | |
* 2013-04-16 17:16:29 executing `deploy:setup' | |
triggering before callbacks for `deploy:setup' | |
* 2013-04-16 17:16:29 executing `deploy:install_bundler' | |
* executing "echo $PATH" | |
servers: ["localhost"] | |
[localhost] executing command | |
** [out :: localhost] /opt/jruby/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games | |
command finished in 150ms | |
* executing "sudo gem install bundler" | |
servers: ["localhost"] | |
[localhost] executing command | |
*** [err :: localhost] sudo | |
*** [err :: localhost] : | |
*** [err :: localhost] gem: command not found | |
*** [err :: localhost] | |
command finished in 55ms | |
failed: "env PATH=/opt/jruby/bin:$PATH JSVC_ARGS_EXTRA=-user\\ vagrant sh -c 'sudo gem install bundler'" on localhost |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'bundler/capistrano' | |
server "localhost", :app, :db, :primary => true | |
ssh_options[:port] = 2222 | |
ssh_options[:keys] = "~/.vagrant.d/insecure_private_key" | |
set :user, "vagrant" | |
set :group, "vagrant" | |
set :use_sudo, false | |
set :deploy_to, "/opt/trinidad" | |
set :application, "rbdc" | |
set :repository, "." | |
set :scm, :none | |
set :deploy_via, :copy | |
set :copy_exclude, [".git","log","tmp","*.box","*.war",".idea",".DS_Store"] | |
set :rake, 'jruby --1.9 -S rake' | |
set :default_environment, { | |
'PATH' => "/opt/jruby/bin:$PATH", | |
'JSVC_ARGS_EXTRA' => "-user vagrant" | |
} | |
set :bundle_dir, "" | |
set :bundle_flags, "--system --quiet" | |
before "deploy:setup", "deploy:install_bundler" | |
after "deploy:create_symlink", "deploy:assets" | |
namespace :deploy do | |
task :install_bundler, :roles => :app do | |
run "echo $PATH" | |
run "sudo gem install bundler" | |
run "sudo ln -s /lib/x86_64-linux-gnu/libncursesw.so.5 /lib/x86_64-linux-gnu/libncursesw.so" | |
run "sudo ln -s /usr/lib/x86_64-linux-gnu/libpanelw.so.5 /usr/lib/x86_64-linux-gnu/libpanel.so" | |
end | |
task :assets, :roles => :app do | |
run("cd #{deploy_to}/current && #{rake} assets:precompile RAILS_ENV=#{rails_env}") | |
end | |
desc "Starting rails" | |
task :start, :roles => :app do | |
run "/etc/init.d/trinidad start" | |
end | |
desc "Stopping rails" | |
task :stop, :roles => :app do | |
run "/etc/init.d/trinidad stop" | |
end | |
task :restart, :roles => :app do | |
run "touch #{current_release}/tmp/restart.txt" | |
end | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ vagrant up --provider=vmware_fusion | |
Bringing machine 'default' up with 'vmware_fusion' provider... | |
[default] Cloning VMware VM: 'precise-ruby'. This can take some time... | |
[default] Verifying vmnet devices are healthy... | |
[default] Preparing network adapters... | |
[default] Starting the VMware VM... | |
[default] Waiting for the VM to finish booting... | |
[default] The machine is booted and ready! | |
[default] Forwarding ports... | |
[default] -- 22 => 2222 | |
[default] -- 80 => 8000 | |
[default] -- 3000 => 8888 | |
[default] Configuring network adapters within the VM... | |
[default] Enabling and configuring shared folders... | |
[default] -- /Users/lori/Projects/precisetm/rails3-bootstrap-devise-cancan: /vagrant | |
[default] -- /Users/lori/Projects/precisetm/rails3-bootstrap-devise-cancan/puppet/manifests: /tmp/vagrant-puppet/manifests | |
[default] -- /Users/lori/Projects/precisetm/rails3-bootstrap-devise-cancan/puppet/modules: /tmp/vagrant-puppet/modules-0 | |
[default] Running provisioner: puppet... | |
Running Puppet with site.pp... | |
stdin: is not a tty | |
Notice: /Stage[main]/Trinidad/File[/opt/trinidad]/ensure: created | |
Notice: /Stage[main]//Exec[apt-update]/returns: executed successfully | |
Notice: /Stage[main]//Package[git]/ensure: ensure changed 'purged' to 'present' | |
Notice: /Stage[main]//Package[openjdk-7-jdk]/ensure: ensure changed 'purged' to 'present' | |
Notice: /Stage[main]/Mysql/Package[mysql-client]/ensure: ensure changed 'purged' to 'present' | |
Notice: /Stage[main]/Mysql/Package[mysql-server]/ensure: ensure changed 'purged' to 'present' | |
Notice: /Stage[main]/Mysql/File[/etc/mysql/my.cnf]/content: content changed '{md5}77f15d6c87f9c136c4efcda072017f71' to '{md5}b3f3cc0f9eba3416fec0523687524796' | |
Notice: /Stage[main]/Mysql/Service[mysql]: Triggered 'refresh' from 1 events | |
Notice: /Stage[main]/Trinidad/Package[jsvc]/ensure: ensure changed 'purged' to 'present' | |
Notice: /Stage[main]/Mysql/Exec[set-mysql-password]/returns: executed successfully | |
Notice: /Stage[main]/Mysql/Exec[set-mysql-password]: Triggered 'refresh' from 2 events | |
Notice: /Stage[main]/Rbdc::Db/Mysql::Db[rbdc_production]/Exec[create-rbdc_production-user]/returns: executed successfully | |
Notice: /Stage[main]/Rbdc::Db/Mysql::Db[rbdc_production]/Exec[create-rbdc_production-db]/returns: executed successfully | |
Notice: /Stage[main]/Rbdc::Db/Mysql::Db[rbdc_production]/Exec[grant-rbdc_production-db]/returns: executed successfully | |
Notice: /Stage[main]//Package[emacs23]/ensure: ensure changed 'purged' to 'present' | |
Notice: /Stage[main]/Jruby/Exec[download_jruby]/returns: executed successfully | |
Notice: /Stage[main]/Jruby/Exec[unpack_jruby]/returns: executed successfully | |
Notice: /Stage[main]/Jruby/File[/opt/jruby]/ensure: created | |
Notice: /Stage[main]/Trinidad/Exec[install_trinidad]/returns: executed successfully | |
Notice: /Stage[main]/Trinidad/Exec[install_trinidad_init_services]/returns: executed successfully | |
Notice: /Stage[main]/Trinidad/File[/opt/trinidad/trinidad_config.yml]/ensure: defined content as '{md5}bdb7177685382d65af0d48a21999c85c' | |
Notice: /Stage[main]/Trinidad/Exec[trinidad_init_service]/returns: executed successfully | |
Notice: /Stage[main]/Trinidad/File[/opt/trinidad/shared]/owner: owner changed 'root' to 'vagrant' | |
Notice: /File[/opt/trinidad/shared/log]/owner: owner changed 'root' to 'vagrant' | |
Notice: /File[/opt/trinidad/shared/pids]/owner: owner changed 'root' to 'vagrant' | |
Notice: /Stage[main]/Trinidad/File[/etc/init.d/trinidad]/owner: owner changed 'root' to 'vagrant' | |
Notice: /Stage[main]/Apache2/Package[apache2]/ensure: ensure changed 'purged' to 'present' | |
Notice: /Stage[main]/Apache2/Exec[a2enmod proxy_ajp]/returns: executed successfully | |
Notice: /Stage[main]/Apache2/Apache2::Apache2::Httpd_conf[/etc/apache2/httpd.conf]/File[/etc/apache2/httpd.conf]/content: content changed '{md5}d41d8cd98f00b204e9800998ecf8427e' to '{md5}ac5e13edd428ff442258acd58c3fcc7b' | |
Notice: /Stage[main]/Apache2/File[/etc/apache2/mods-enabled/proxy.conf]/ensure: defined content as '{md5}9e970b79fad27a67ffbd52e276d5b9ad' | |
Notice: /Stage[main]/Apache2/Service[apache2]: Triggered 'refresh' from 2 events | |
Notice: Finished catalog run in 235.12 seconds |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- mode: ruby -*- | |
# vi: set ft=ruby : | |
Vagrant::Config.run do |config| | |
# All Vagrant configuration is done here. The most common configuration | |
# options are documented and commented below. For a complete reference, | |
# please see the online documentation at vagrantup.com. | |
# Every Vagrant virtual environment requires a box to build off of. | |
config.vm.box = "precise-ruby" | |
# config.vm.box_url = "http://files.vagrantup.com/precise64.box" | |
config.vm.box_url = "http://files.vagrantup.com/precise64_vmware_fusion.box" | |
config.vm.forward_port 80, 8000 | |
config.vm.forward_port 3000, 8888 | |
config.vm.provision :puppet do |puppet| | |
puppet.manifests_path = "puppet/manifests" | |
puppet.module_path = "puppet/modules" | |
puppet.manifest_file = "site.pp" | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment