Closed CraftyDevon closed 9 years ago
Hi @CraftyDevon :)
It seems you lacks mysqldump on your local environment
mysqldump: command not found
What is the output of which mysqldump
in your terminal? Usually mysqldump is shipped with mysql, so sounds a bit weird the lack of it...
Mh...is it possible you're using Vagrant, w/ mysqldump in it, but invoking wordmove within your bare machine? Wordmove expects to be invoked from inside the Vagrant box. If it's not your case ignore this comment, please.
Cheers
I'm using Vagrant in combo with the VVV site wizard script by aliso. So my vagrant box sits in a folder on my desktop, and each site I have is in a subfolder within that. Currently my movefile is inside the htdocs file.
I'm currently not sshing into the box.
Please, could you answer to my previous questions, please?
Morevoer: «my movefile is inside the htdocs file» I can't understand where or what is your "htdocs file", I'm sorry. Could you explain a bit deeper?
Cheers
Currently which mysql returns mysqldump not found.
I am running wordmove inside of vagrant. File wise, Desktop/mybox/vvv/www/sitename/htdocs.
Thanks!
Mmmhhh...if I understand you're doing something like:
cd Desktop/mybox/vvv/www/sitename/htdocs
htdocs
on your bare machinehtdocs
dirvagrant ssh
You actually said «I'm running wordmove inside of vagrant», but what's your procedure? Your problem isn't really wordmove-releated, so we need as much info as possible about your environment, or we can't help as much as we'd like.
Thank you
You guys are always great with lending a hand.
Your assumptions are correct. So once I cd into that htdocs folder, I run my Wordmove command. It works for everything other than the database.
I wonder if the upgrade to yosemite caused an issue, I did successfully push a database in the past.
When I attempt to ssh into that htdocs folder and run wordmove, it tells me the command isn't found. Should I install worldmove inside vagrant?
Imho, yes! In most of the cases, when using Vagrant, the way to go is to use wordmove inside the Vagrant box, because it has all the tools you need. Moreover there are plenty of different setups and the troubleshooting is always a bit painful. E.g.: where your mysql DB is? Inside the box? Outside the box?
We in weLaika do not use Vagrant, so, in the end, we have not all the know how at our fingertips ^^''
I'd anyway try to install wordmove inside the box. Than you can call from the outside, using for example vagrant ssh -- wordmove --config=/path/to/your/Movefile
or something similar.
Please drop here some good news when you'll have someone :+1:
Attempting to install wordmove inside vagrant leaves me with this..
agrant@vvv:~$ sudo gem install wordmove Building native extensions. This could take a while... ERROR: Error installing wordmove: ERROR: Failed to build gem native extension.
/usr/bin/ruby1.9.1 extconf.rb
/usr/lib/ruby/1.9.1/rubygems/custom_require.rb:36:in require': cannot load such file -- mkmf (LoadError) from /usr/lib/ruby/1.9.1/rubygems/custom_require.rb:36:in
require'
from extconf.rb:1:in `
Gem files will remain installed in /var/lib/gems/1.9.1/gems/json-1.8.1 for inspection. Results logged to /var/lib/gems/1.9.1/gems/json-1.8.1/ext/json/ext/generator/gem_make.out
Ouch. We're going too far from our territory... here we are into the wild...I don't know even what's the OS of your box :( I think installing a gem should be resolved somewhere else...
Just one question: how do you manage and how do you connect to your database? What's the configuration inside wp-config.php? Have you got sequelPro / phpMyAdmin / hellSQLsomethingElse installed? How does it connect to your db?
https://github.com/joeguilmette/auto-site-setup/blob/master/provision/provision-pre.sh
Dump that into your provision folder and run vagrant reload ---provision
. It has done other stuff you might want to comment out.
Or you can manually run
apt-get install -y ruby-dev
gem install rubygems-update
update_rubygems
gem install wordmove
Have fun! On Tue, Nov 18, 2014 at 11:07 PM Alessandro Fazzi notifications@github.com wrote:
Ouch. We're going too far from our territory... here we are into the wild...I don't know even what's the OS of your box :( I think installing a gem should be resolved somewhere else...
Just one question: how do you manage and how do you connect to your database? What's the configuration inside wp-config.php? Have you got sequelPro / phpMyAdmin / hellSQLsomethingElse installed? How does it connect to your db?
— Reply to this email directly or view it on GitHub https://github.com/welaika/wordmove/issues/110#issuecomment-63494885.
Hey @joeguilmette I was secretly hoping that you were reading this issue :p
Guys...probably could be a good idea to write something on the wiki about wordmove and vagrant and VVV and all the stuff used by a lot of us :)
@CraftyDevon drop here some feedback if you can.
Bye
Thanks again guys, sadly i'm still struggling with that. Attempting to install anything inside my vvv box yields in failure. @joeguilmette Is there a specific directory I should run that command in, or should the box root be fine?
I've made some progress in general, mainly through blind luck sadly. If I can get past this error I do believe I'll be golden. I've insured my db password doesn't have any special characters.
/Library/Ruby/Gems/2.0.0/gems/net-ssh-2.8.0/lib/net/ssh/buffer.rb:284:in `block in write': incompatible character encodings: ASCII-8BIT and UTF-8 (Encoding::CompatibilityError)
from /Library/Ruby/Gems/2.0.0/gems/net-ssh-2.8.0/lib/net/ssh/buffer.rb:284:in `each'
from /Library/Ruby/Gems/2.0.0/gems/net-ssh-2.8.0/lib/net/ssh/buffer.rb:284:in `write'
from /Library/Ruby/Gems/2.0.0/gems/net-ssh-2.8.0/lib/net/ssh/buffer.rb:322:in `block in write_string'
from /Library/Ruby/Gems/2.0.0/gems/net-ssh-2.8.0/lib/net/ssh/buffer.rb:319:in `each'
Hah! Well, @pioneerskies, I watch a couple repos, and as it's my most favorite in the whole world, I pay special attention to Wordmove.
In any case- @CraftyDevon I'm not sure what the problem is, but the good news is Vagrant is Vagrant so you can just vagrant destroy
and start over.
So let's do this:
vagrant destroy
provision
folder in your VVV root folder. Create a file called provision-pre.sh
and fill it with:# Rubygems update
if [ $(gem -v|grep '^2.') ]; then
echo "gem installed"
else
apt-get install -y ruby-dev
echo "ruby-dev installed"
echo "gem not installed"
gem install rubygems-update
update_rubygems
fi
# wordmove install
wordmove_install="$(gem list wordmove -i)"
if [ "$wordmove_install" = true ]; then
echo "wordmove installed"
else
echo "wordmove not installed"
gem install wordmove
wordmove_path="$(gem which wordmove | sed -s 's/.rb/\/deployer\/base.rb/')"
if [ "$(grep yaml $wordmove_path)" ]; then
echo "can require yaml"
else
echo "can't require yaml"
echo "set require yaml"
sed -i "7i require\ \'yaml\'" $wordmove_path
echo "can require yaml"
fi
fi
vagrant up
vagrant ssh
. Now, navigate to your site folder cd /srv/www/myproject
and run your Wordmove magic. Pay special attention: all of the paths in your Movefile must be the absolute path in Vagrant, because that's where you're running Wordmove from. so ~/CraftyDevonsMacBook/Desktop/VVV
isn't going to work. In the future you won't have to worry if you simply run wordmove init
from Vagrant. I actually got rid of Wordmove on my laptop for this exact reason.Since this is a VVV issue rather than a Wordmove issue, you can contact me directly in the future if you run in to any more problems!
Ohoho!
@joeguilmette I'll dream of a wiki section copy-pasted from you last comment <3
@CraftyDevon speaking about encoding problems, please take a look at the pull requests. We're trying our best to review and accept/implement those in order to ship another tagged release of Wordmove; in the meantime lurk inside pull requests and older issues.
Please, give us feedback in order to let us follow the troubleshooting.
@joeguilmette you're a star! Ping me whenever you're in London so I can buy you a pint :beers:
Aww shucks, thanks guys...
@joeguilmette could you please write down a wiki page about this? Thank you very much for your work!
Done! And funny enough, I saw your request here after I just went ahead and did it.
Hi! Thank you very much!
I found this method does not work anymore. The easiest way to install wordmove in a VVV machine now is to: 1) SSH into the machine: vagrant ssh 2) Change to root account: sudo su - 3) Run: gem install wordmove
Now your database and files should push & pull / sync seamlessly.
Hey there, I'm currently encountering the following issue when I try and push my database. I know the paramaters in my movefile are correct, as they match wp-config and the site installer ran fine with them. Any thoughts? Thanks! I'm running this with wordmove push -d -e staging