mirror of
https://github.com/verdaccio/verdaccio.git
synced 2025-02-17 23:45:29 -05:00
adding config param to specify upload limits, fixes #39
This commit is contained in:
parent
e522347667
commit
2add883370
3 changed files with 6 additions and 2 deletions
|
@ -70,3 +70,7 @@ logs:
|
|||
#https_proxy: https://something.local/
|
||||
#no_proxy: localhost,127.0.0.1
|
||||
|
||||
# maximum size of uploaded json document
|
||||
# increase it if you have "request entity too large" errors
|
||||
#max_body_size: 1mb
|
||||
|
||||
|
|
|
@ -81,7 +81,7 @@ module.exports = function(config_hash) {
|
|||
app.use(basic_auth(function(user, pass) {
|
||||
return config.authenticate(user, pass)
|
||||
}))
|
||||
app.use(express.json({strict: false}))
|
||||
app.use(express.json({strict: false, limit: config.max_body_size || '10mb'}))
|
||||
|
||||
// TODO: npm DO NOT support compression :(
|
||||
app.use(express.compress())
|
||||
|
|
|
@ -21,7 +21,7 @@ packages:
|
|||
allow_publish: all
|
||||
proxy_access: server2
|
||||
proxy_publish: server2
|
||||
|
||||
|
||||
'testloop':
|
||||
allow_access: all
|
||||
allow_publish: all
|
||||
|
|
Loading…
Add table
Reference in a new issue