add dotenv #1
8
index.js
8
index.js
@@ -1,4 +1,5 @@
|
|||||||
// Import all the things
|
// Import all the things
|
||||||
|
require('dotenv').config();
|
||||||
const axios = require('axios');
|
const axios = require('axios');
|
||||||
const express = require('express');
|
const express = require('express');
|
||||||
const fs = require('node:fs');
|
const fs = require('node:fs');
|
||||||
@@ -28,7 +29,12 @@ const playlistId = 'PLnlTMS4cxfx3-et_L8APzpEgy_eCf18-U';
|
|||||||
/**
|
/**
|
||||||
* Port that nginx proxies to public
|
* Port that nginx proxies to public
|
||||||
*/
|
*/
|
||||||
const port = 48915;
|
const port = process.env.PORT || 48915;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Are we prod or dev
|
||||||
|
*/
|
||||||
|
const dev = process.env.DEV || false;
|
||||||
|
|
||||||
// Helper functions I've made to do things and stuff :P
|
// Helper functions I've made to do things and stuff :P
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user