mekasu0124

Untitled

Oct 17th, 2024
44
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. const http = require('http');
  2. const app = require('./app');
  3.  
  4. require('dotenv').config();
  5.  
  6. const port = process.env.PORT;
  7. const server = http.createServer(app);
  8.  
  9. const appName = process.env.APP_NAME;
  10. const appVersion = process.env.APP_VERSION;
  11. const appDescription = process.env.APP_DESCRIPTION;
  12. const appAuthor = process.env.APP_AUTHOR;
  13. const appLicense = process.env.APP_LICENSE;
  14.  
  15. server.listen(port, () => {
  16.   console.log("~".repeat(80));
  17.   console.log("~ " + appName + " ~");
  18.   console.log("~ Version: " + appVersion);
  19.   console.log("~ Description: " + appDescription);
  20.   console.log("~ Author: " + appAuthor);
  21.   console.log("~ License: " + appLicense);
  22.   console.log("~ Server is running at http://localhost:" + port);
  23.   console.log("~".repeat(80));
  24. });
  25.  
Advertisement
Add Comment
Please, Sign In to add comment