User:Mainframe98/Vagrant on Windows

This guide attempts to list all the required steps to install MediaWiki-Vagrant on a windows machine.

Pre installation steps

 * 1) Check if you meet the requirements:
 * 2) * Installed version of Windows is 64 bit
 * 3) * Hyper-V is disabled - Required to use VirtualBox, Hyper-V support might be unstable
 * 4) * Hardware Virtualization Technology (VT-x or AMD-V) in the BIOS is enabled and the computer supports Hardware Virtualization
 * 5) Download the software required
 * 6) * Git - Not required if you download mediawiki-vagrant from Gerrit/github directly, in which case, use one of the links below
 * 7) ** tar.gz from GitHub
 * 8) ** zip from GitHub
 * 9) ** tar.gz from Gerrit
 * 10) * VirtualBox - Not required if you want to use Hyper-V
 * 11) * Vagrant
 * 12) * PuTTY - Not required if you install Git with optional Unix tools or have a different ssh client

Installation

 * 1) Install Vagrant and if downloaded Git and VirtualBox
 * 2) * If you want to use ssh from the windows command line, install Git using the  installation option when installing Git. This is not required, as you may use another ssh client like PuTTY instead. Please do note that not using this installation option causes Vagrant to display an error about a missing ssh client. This message may be ignored.
 * 3) Clone https://gerrit.wikimedia.org/r/mediawiki/vagrant by using   in your home directory/(My) Documents
 * 4) * SSH:
 * 5) * Instead of using, you can also just extract the zip file.
 * 6) Run   which is located in the newly cloned folder
 * 7) Run , to specify the version (MediaWiki ), omit statement entirely to use the master branch
 * 8) Run

Connecting through ssh
This example uses PuTTY. Host default HostName 127.0.0.1 User vagrant Port 2222 UserKnownHostsFile /dev/null StrictHostKeyChecking no PasswordAuthentication no IdentityFile C:/HashiCorp/Vagrant/mediawiki-vagrant/.vagrant/machines/default/virtualbox/private_key IdentitiesOnly yes LogLevel FATAL ForwardX11 yes
 * Write down the ssh information about the vagrant virtual machine retrieved from running
 * Example output:
 * Generate a private key file that can be read by PuTTY using PuTTY gen (Found on the same page as the PuTTY download)
 * Open PuTTY gen and load the private key file (IdentityFile, in the example above)
 * Export it by choosing "Save private key", and store it somewhere save.
 * Add the private key file by navigating in PuTTY to Connection, SSH, Auth. Click "Browse..." to load the generated file.

Errors
Relevant information from running, Cloning mediawiki/core fails, and other packages that use mediawiki as dependency fail as a result too. ==> default: Notice: /Stage[main]/Mediawiki/Git::Clone[mediawiki/core]/Exec[git_clone_mediawiki/core]/returns: Cloning into '/vagrant/mediawiki'... ==> default: Notice: /Stage[main]/Mediawiki/Git::Clone[mediawiki/core]/Exec[git_clone_mediawiki/core]/returns: error: RPC failed; result=56, HTTP code = 200 ==> default: Notice: /Stage[main]/Mediawiki/Git::Clone[mediawiki/core]/Exec[git_clone_mediawiki/core]/returns: fatal: The remote end hung up unexpectedly ==> default: Notice: /Stage[main]/Mediawiki/Git::Clone[mediawiki/core]/Exec[git_clone_mediawiki/core]/returns: fatal: early EOF ==> default: Notice: /Stage[main]/Mediawiki/Git::Clone[mediawiki/core]/Exec[git_clone_mediawiki/core]/returns: fatal: index-pack failed ==> default: Error: /usr/bin/git clone --recurse-submodules --branch 'REL1_27' https://gerrit.wikimedia.org/r/p/mediawiki/core.git /vagrant/mediawiki returned 128 instead of one of [0] ==> default: Error: /Stage[main]/Mediawiki/Git::Clone[mediawiki/core]/Exec[git_clone_mediawiki/core]/returns: change from notrun to 0 failed: /usr/bin/git clone --recurse-submodules --branch 'REL1_27' https://gerrit.wikimedia.org/r/p/mediawiki/core.git /vagrant/mediawiki returned 128 instead of one of [0] ==> default: Notice: /Stage[main]/Mediawiki/Php::Composer::Install[/vagrant/mediawiki]/Exec[composer-install--vagrant-mediawiki]: Dependency Exec[git_clone_mediawiki/core] has failures: true