cors added, config tests fixed

This commit is contained in:
C
2023-02-01 14:48:10 +05:00
parent 622556911c
commit 4dd9ce1902
2 changed files with 10 additions and 8 deletions
+7 -7
View File
@@ -1,3 +1,10 @@
const {test_config} = require('./tests/config')
if (!test_config()) {
process.exit(1)
}
console.log('all initial tests successfully passed')
const {port} = require('./config')
const app = require('express')()
const helmet = require('helmet')
@@ -8,13 +15,6 @@ const {request_logger, error_logger} = require('./src/middlewares/logger')
const {options, cors} = require('./src/middlewares/cors')
const {error_handler} = require('./src/middlewares/error_handler')
//const limiter = require('./src/middlewares/limiter')
const {test_config} = require('./tests/config')
if (!test_config()) {
process.exit(1)
}
console.log('all initial tests successfully passed')
app.options(options)
+3 -1
View File
@@ -10,7 +10,9 @@ module.exports = {
"http://localhost:3000",
"https://stream.graff.tech/",
"http://212.220.216.185:3005",
"https://stream.graff.tech"
"https://stream.graff.tech",
"http://test.stream.graff.tech",
"https://test.stream.graff.tech"
],
limiter: {
window_minutes: 10,