-
Notifications
You must be signed in to change notification settings - Fork 82
Expand file tree
/
Copy pathconfig.ts
More file actions
20 lines (18 loc) · 692 Bytes
/
config.ts
File metadata and controls
20 lines (18 loc) · 692 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
/* eslint-disable prettier/prettier */
const environments:any = {};
environments.development = {
port: 3000,
database:`${process.env.DEV_MONGODB}`,
envName: "Development enviroment",
site: "http://localhost:3000",
};
environments.production = {
port: 8080,
database: `${process.env.PROD_MONGODB}`,
envName: "Production enviroment",
site: "https://hackathon-slhbx5lcqq-uc.a.run.app"
};
const currentEnvironment = process.env.NODE_ENV ? process.env.NODE_ENV : "";
const environmentToExport = typeof environments[currentEnvironment] === "object" ? environments[currentEnvironment] : environments.production;
// Export Module
export default environmentToExport;