Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wiki-js
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
1
Issues
1
List
Board
Labels
Milestones
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Jacklull
wiki-js
Commits
8e3af9ac
Unverified
Commit
8e3af9ac
authored
Feb 11, 2022
by
Nicolas Giard
Committed by
GitHub
Feb 11, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: use config value for json body parser limit
parent
91ce977a
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
10 additions
and
1 deletion
+10
-1
config.sample.yml
config.sample.yml
+8
-0
data.yml
server/app/data.yml
+1
-0
master.js
server/master.js
+1
-1
No files found.
config.sample.yml
View file @
8e3af9ac
...
@@ -130,3 +130,11 @@ ha: false
...
@@ -130,3 +130,11 @@ ha: false
# ---------------------------------------------------------------------
# ---------------------------------------------------------------------
# Writeable data path used for cache and temporary user uploads.
# Writeable data path used for cache and temporary user uploads.
dataPath
:
./data
dataPath
:
./data
# ---------------------------------------------------------------------
# Body Parser Limit
# ---------------------------------------------------------------------
# Maximum size of API requests body that can be parsed. Does not affect
# file uploads.
bodyParserLimit
:
5mb
server/app/data.yml
View file @
8e3af9ac
...
@@ -26,6 +26,7 @@ defaults:
...
@@ -26,6 +26,7 @@ defaults:
logLevel
:
info
logLevel
:
info
offline
:
false
offline
:
false
ha
:
false
ha
:
false
bodyParserLimit
:
5mb
# DB defaults
# DB defaults
api
:
api
:
isEnabled
:
false
isEnabled
:
false
...
...
server/master.js
View file @
8e3af9ac
...
@@ -91,7 +91,7 @@ module.exports = async () => {
...
@@ -91,7 +91,7 @@ module.exports = async () => {
// GraphQL Server
// GraphQL Server
// ----------------------------------------
// ----------------------------------------
app
.
use
(
bodyParser
.
json
({
limit
:
'1mb'
}))
app
.
use
(
bodyParser
.
json
({
limit
:
WIKI
.
config
.
bodyParserLimit
}))
await
WIKI
.
servers
.
startGraphQL
()
await
WIKI
.
servers
.
startGraphQL
()
// ----------------------------------------
// ----------------------------------------
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment