Toggle navigation
Toggle navigation
This project
Loading...
Sign in
송용우
/
oss-Jaksimsamil
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Snippets
Network
Create a new issue
Builds
Commits
Issue Boards
Authored by
송용우
2020-06-12 23:20:27 +0900
1
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
02ae327992a392d0889c7170b213fce339923803
02ae3279
1 parent
664acc3e
Fixed index.js for Readability
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
2 deletions
jaksimsamil-server/index.js
jaksimsamil-server/index.js
View file @
02ae327
...
...
@@ -3,12 +3,16 @@ const Router = require("koa-router");
const
bodyParser
=
require
(
"koa-bodyparser"
);
const
mongoose
=
require
(
"mongoose"
);
const
jwtMiddleware
=
require
(
"./src/lib/jwtMiddleware"
);
const
api
=
require
(
"./src/api"
);
require
(
"dotenv"
).
config
();
const
app
=
new
Koa
();
const
router
=
new
Router
();
require
(
"dotenv"
).
config
();
app
.
use
(
bodyParser
());
app
.
use
(
jwtMiddleware
);
const
api
=
require
(
"./src/api"
);
const
{
SERVER_PORT
,
MONGO_URL
}
=
process
.
env
;
router
.
use
(
"/api"
,
api
.
routes
());
...
...
@@ -26,6 +30,7 @@ mongoose
.
catch
((
e
)
=>
{
console
.
log
(
e
);
});
app
.
listen
(
SERVER_PORT
,
()
=>
{
console
.
log
(
"Server is running on port"
,
process
.
env
.
SERVER_PORT
);
});
...
...
송용우
@2019102188
2020-06-12 14:21:29 UTC
Mentioned in commit
5e375807
Please
register
or
login
to post a comment