Allows viewing and managing Nginx configuration files. It simplifies the relationship between sites_available
and sites_enabled
and makes it easy to manage.
npm install -g nginx-cli
You must install it as sudo.
$ sudo ngnx init
$ ngnx list
# Output #
┌───────────┬─────────┐
│ Conf Name │ Status │
├───────────┼─────────┤
│ default │ enabled │
├───────────┼─────────┤
│ test.conf │ │
└───────────┴─────────┘
$ ngnx enable test.conf
# Output #
┌───────────┬─────────┐
│ Conf Name │ Status │
├───────────┼─────────┤
│ default │ enabled │
├───────────┼─────────┤
│ test.conf │ enabled │
└───────────┴─────────┘
$ ngnx disable test.conf
# Output #
┌───────────┬─────────┐
│ Conf Name │ Status │
├───────────┼─────────┤
│ default │ enabled │
├───────────┼─────────┤
│ test.conf │ │
└───────────┴─────────┘