/NPG

NPG is a small tool written in bash that help you generate and manage web projects that use NGINX.

Primary LanguageShellMIT LicenseMIT

NPG

NPG is a small tool written in bash that help you easily generate and manage web projects that use NGINX.

screenshot-2017-02-12_18-15-36

Installation

Download npg.sh anywhere you want

wget https://raw.githubusercontent.com/nicolasbeauvais/npg/master/npg.sh

Modify the script accordingly:

# You nginx vhost directory
NGINX_VHOSTS_DIR="/etc/nginx/sites-available"

# You working directory
WORKING_DIR="/your/work/directory"

# The command to restart nginxa
RESTART_NGINX="service nginx restart"

# Username to use when creating directories
USERNAME="yourusername"

# PHP version
PHP_VERSION="7.1"

# Default TLD to use
TLD="localhost"

Create a symlink:

ln -s npg.sh /usr/bin/npg

Usage

npg --help # list all available commands