Topic on Extension talk:Maps

Jump to navigation Jump to search

How to install without shell access on shared hosting server for running composer

1
Summary by Felix Englisch

Get a fresh local install of MediaWiki, install composer locally, run composer require mediawiki/maps on your compute (in the root directory of your local mediawiki install) and upload all the directories, which where automatically installed to your local wiki, to your remote server via FTP (e.g. using Filezilla).

Felix Englisch (talkcontribs)

Don't worry, if you don't have access to the command line/terminal of your remote server. The good news is that you can nevertheless install maps on your wiki using the File Transfer Protocol (FTP/Filezilla). The bad news is that you do have to install composer on your local wiki installation.

  • OS: Windows 10
  • MW version: 1.34.1
  • PHP: 7.3.8
  • Maps extenstion: 7.20.0

The purpose of composer is that it installs all dependencies of this extension by running only one command, but if don't have access to the command line of your remote server (shell access, SSH), you cannot run it - but you can install all dependencies by hand.

To get the required directories, though, you need to get a fresh install of MediaWiki on your localhost and install composer (guide). Installing composer locally might not be the easiest task for some, but it is doable.

If the local dummy wiki is setup and composer is working, open the command line of your computer and navigate to the root directory of your local MediaWiki install (if on Windows using XAMPP, enter e.g. cd C:/xampp/htdocs/testwiki). Then, enter the following prompt: composer require mediawiki/maps

57 or so directories should be downloaded and installed automatically. Now, we only have to find these folders and upload them to right location on our remote server via FTP (e.g. using Filezilla). The directories we are looking for are in the extensions/ and the vendor/ directory of our local mediawiki install. Upload them to the exact same location (i.e. the extensions/ and vendor/ directory respectively) on our remote server. From the extensions/ folder, these are merely the folders "Maps" and "Validator". From the vendor/ directory, upload all the following folders:

bin, cache, composer (this one probably already exists in your wiki, but things changed due to the Maps installation; I've overwritten it and it worked), data-values, dnoegel, doctrine, giorgiosironi, hamcrest, jakub-onderka, jeroen, jmikola, johnkary, justinrainbow, mediawiki, monolog, myclabs, nikic, nmred, param-processor, phar-io, phpdocumentator, phpspec, phpunit, psy, sebastian, seld, squizlabs, symfony, theseer, webmozart, wildurand, wmde

Finally, add wfLoadExtension( 'Maps' ); and optionally configuration details to your your LocalSettings.php and that's it.

Reply to "How to install without shell access on shared hosting server for running composer"