📜 ⬆️ ⬇️

Introduction to Nitrode - dedicated HTTP server

I am glad to present you a description of Nitrode .


Node.Js does not include the FastCGI module or similar modules for integrating applications, unlike other HTTP servers, for example, nginx.


Nitrode aims to eliminate this gap by providing a fast and versatile HTTP server built on the basis of Node.JS. It is designed to support most of the basic features of nginx, but it has an added advantage, since Nitrode is written in JavaScript and provides an API for existing applications that allows them to exercise full control over the server without leaving the current process.
Sumptuously! How can I use it?

You can find the repository here: github.com/ollym/nitrode

I included an example example.js, which will use all the current features of Nitrode, including:
  1. Basic HTTP authentication;
  2. ETag and If-Modified-Since support;
  3. Support for public directories and maintenance of static files;
  4. SSL support;
  5. Ability to customize from A to Z;
  6. Support for virtual hosts;
  7. support url rewrite;
  8. And much more…

Unlike Connect , Nitrode aims to be a strictly HTTP server, and focuses entirely on this direction.

To run an example:
  1. Clone the source repository;
  2. Go to the repository directory;
  3. Run the following command: “sudo node example.js”;
  4. Open a browser and enter: "localhost: 80";
  5. Verify authentication using username: “admin”, password: “admin”;
  6. Now you should see a page titled: “Welcome to Nitrode!”.

Also make sure that example.js is easy to read!

What's next?

Nitrode is very young, I started developing it just last week or so. There are a number of things that I still have to do:
  1. Split index.js into smaller libraries;
  2. Add support for digest authentication;
  3. Add SSL certificate authentication support;
  4. Write unit tests;
  5. Improve performance sys.pump;
  6. Write performance tests;
  7. Write documentation;

If someone is interested to help me with these tasks, then please join!


PS: from translator: Node.JS 0.2.0 just left , and the author promises that API will not change in this thread.
PPS: the author for the time from the announcement of Nitrode has already released several new versions to this day, a lot has already been done.

Source: https://habr.com/ru/post/102258/

All Articles