Added the shortener, cdn & action socket to the app.ts
This commit is contained in:
parent
896b2a1aab
commit
f2aa6ad49f
6
app.ts
6
app.ts
@ -1,5 +1,8 @@
|
||||
import mongoose, {CallbackError} from 'mongoose';
|
||||
import * as api from './server/api';
|
||||
import * as shortener from './server/shortener';
|
||||
import * as contentDelivery from './server/contentDelivery';
|
||||
import * as actionSocket from './server/actionSocket';
|
||||
|
||||
// Load & check environment
|
||||
require('dotenv').config();
|
||||
@ -15,4 +18,7 @@ mongoose.connect(process.env.MONGOOSE_STRING || '', (e: CallbackError) => {
|
||||
// Start all servers
|
||||
const start = () => {
|
||||
api.startServer(parseInt(process.env.API_PORT || ''));
|
||||
shortener.startServer(parseInt(process.env.SHORTENER_PORT || ''));
|
||||
contentDelivery.startServer(parseInt(process.env.CDN_PORT || ''));
|
||||
actionSocket.startServer(parseInt(process.env.AS_PORT || ''));
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user