diff --git a/README.md b/README.md index c96172e..ae44ec6 100644 --- a/README.md +++ b/README.md @@ -4,10 +4,11 @@ 1. Requirements: -* Create a bde-list user in sudoers: `useradd -m -s /bin/bash -G sudo bde-list` and connect to it. +* Create a bde-list user in sudoers: `sudo useradd -m -s /bin/bash -G sudo bde-list` and connect to it. * Install nvm: `curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.2/install.sh | bash` * Install node: `nvm install 18.12.1 && nvm use 18.12.1` * Install pm2: `npm install pm2 -g` +* Install nginx: `sudo apt-get install nginx` 2. Installation: diff --git a/index.js b/index.js index 7a38c19..55d57cf 100644 --- a/index.js +++ b/index.js @@ -42,6 +42,10 @@ fastify.register(require('@fastify/static'), { decorateReply: false }) +fastify.get('/', async (request, reply) => { + +}) + fastify.post('/login', async (request, reply) => { let content = request.body; if (content.hasOwnProperty("user") @@ -347,7 +351,7 @@ function makeid(length) { const start = async () => { try { - await fastify.listen({ port: 3000 }) + await fastify.listen({ port: 3000 , host: '0.0.0.0',}) } catch (err) { fastify.log.error(err) LDAP.close(function(err) {