WT-NMP - portable Nginx Mysql Php development stack for Windows
===============================================================
A portable, preconfigured, lightweight, fast and stable server stack for developing php mysql applications on windows, based on the excellent webserver Nginx. A lighter alternative to XAMPP and WAMP.

Copyright (C) 2013-2015 Dragoș Alexandru Ioniță
Copyright (C) 2013-2015 http://wtriple.com
All rights reserved.
http://wtriple.com/wtnmp/
https://sourceforge.net/projects/wtnmp
This software is a fork of nmp-server http://code.google.com/p/nmp-server/


Current Package contains:
-------------------------
- Nginx web server - 1.9.0
- Mysql database server - 5.6.24
- Php scripting language - 5.4.40 & 5.6.8
- HeidiSql database manager
- WinSCP SFTP client
- Php Extensions: opcache, xdebug, xcache.
- MSmtp sendmail smtp client wrapper
- Composer dependency manager for php
- Adminer web based database manager
- Reg.php regular expressions tester
- wt-nmp.exe server manager


Features:
---------
- TRULY PORTABLE, you can zip it and take it with you, or you can move it to a different location on your filesystem. Configuration files are updated automatically after you move WT-NMP to a different machine/folder
- Easy to upgrade! Backups, configuration files, database data, included libraries and projects are persistent during upgrades (not overwritten)
- Lightning-fast web server. Optimized for best performance. Preconfigured servers for fast development
- Command line tools: mysql client, php console, composer, hosts commander
- For easy access, all configuration files are stored in one place: WT-NMP\conf and all log files are stored in one folder: WT-NMP\log
- Multiple PHP Versions and version switcher. Dynamic number of php-cgi processes
- The server manager runs minimized in the system tray and monitors, logs and restarts crashed servers
- Project setup, local virtual servers for projects, Upload, Sync and Browse with WinSCP
- Optional MySQL database daily backups can be enabled with --backup. Up to 7 backup files will be created per database per weekday




Installing & Upgrading:
-----------------------
 - [Download the latest installer](http://wtriple.com/wtnmp/). The installer produces a portable folder.
 - Choose any installation folder you want.
 - The installer also upgrades previous ZIP installations as long as you choose the same destination path.
 - Other PHP versions are available as [extra packages](http://sourceforge.net/projects/wtnmp/files/extras/)



Server Manager command line arguments:
--------------------------------------
example shortcut: `D:/Work/bin/wt-nmp.exe --debug --backup --phpCgiServers=2`

* -d	    --debug			Display debug messages
* -s	    --startServers		Starts all the servers in background and minimizes to systray
* -k	    --killAll			Kills all running servers and exits
* -b        --backup			Enables automatic daily backups
* -l	    --latestPhp			Forces the use of the latest PHP version
* -p=n	    --phpCgiServers=n		Forces the number of PHP-CGI Servers, between 1 and 99
* -j	    --hideProjects		Hides Projects list at startup
* -n	    --noUpdates			Disables weekly Update checks
* -w	    --wwwDir="c:\Dir"		Custom WWW folder path for projects





Portability:
------------
WT-NMP is portable, but it is better if you run the installer once on each new machine:

- The installer registers php, mysql and composer executables to PATH. If you move WT-NMP somewhere else on your file system, or to a new machine, those executables won`t be available globally anymore.
- So, if you need to copy/clone WT-NMP to a new machine, you should run the installer once, then overwrite the folder with the cloned folder




Issues:
------------
- Nginx: One of the reasons Nginx is so fast, it`s because it does not process .htaccess files. Therefore URL Rewriting and User Access must be set in nginx.conf.
- MySql 5.6 has a bug causing it to use too much memory: add table_definition_cache = 400 to mysql.ini
- PHP is configured in a very restrictive way, like on most hosting providers. Comment out `disable_functions`, `disable_classes`, `open_basedir` in conf/php.ini, if you need a more permissive PHP configuration.
- PHP Extensions: most of them are disabled by default, enable them in conf/php.ini (see src/defaults/php.ini for opcache, xdebug, xcache)
- PHP MySql extension is disabled by default and is deprecated as of PHP 5.5.0, and will be removed in the future. Instead, the MySQLi or PDO_MySQL extension should be used. If you really want to enable mysql extension, add or uncomment in conf/php.ini: `extension = php_mysql.dll`
- PHP: Starting only one PHP-CGI server with wt-nmp.exe --phpCgiServers=1 will result in slow ajax requests since Nginx will not be able to process PHP scripts simultaneous.
- XCache PHP Extension: Disabled by default. Due to the limitations of php under windows, (only one process per CGI server, forcing wt-nmp to start more php-cgi servers instead of starting one server with more processes), the XCache PHP Extension will use different shared memory buffers for each php-cgi server. This will use more memory and will make XCache Variable Cache inconsistent between php processes. If you intend relay on it, you should use --phpCgiServers=1. XCache Opcode Cache will not be affected, but it will waste memory.
- OPCache PHP Extension: when enabled, only one php-cgi server can be safely started. Starting more PHP-CGI servers might return "Fatal Error Unable to reattach to base address"




Great Articles:
---------------
* [WordPress in a nutshell: WT-NMP](http://wpkrauts.com/2014/wordpress-in-a-nutshell-wt-nmp/)
* [WT-NMP How-Tos](http://wtriple.com/wtnmp/howtos.php)








