Verdaccio as upstream to another Verdaccio in offline mode causes repeated 200 (0 bytes) → uplink timeouts → 500 errors #5545
Unanswered
ganeshthirumani-05
asked this question in
Q&A
Replies: 2 comments
-
|
I think this should work. Which version of Verdaccio are you using? What's the environment (docker, helm, ...)? A middleware log ( PS: You post is hard to read. Please fix the formatting of the coding blocks. Thx 🙏 |
Beta Was this translation helpful? Give feedback.
0 replies
-
|
Maybe related: #5773 |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hi Verdaccio team 👋,
I’m trying to use Verdaccio as an upstream for another Verdaccio in an offline / air-gapped setup, but I’m running into repeated timeouts and 500 errors even though the upstream Verdaccio already has all required packages cached and works fine standalone in offline mode.
I’d like to understand whether this setup is supported, unsupported by design, or if I’m missing something in configuration.
npm client ↓ Verdaccio A (consumer registry) ↓ Verdaccio B (upstream registry – already cached, offline)Verdaccio B
Fully populated with required packages
Works correctly in offline mode
Clients can install packages directly from it without issues
Verdaccio A
Uses Verdaccio B as an uplink
No direct access to npmjs.org
Intended to rely only on Verdaccio B
`
storage: /verdaccio/storage/data
auth:
htpasswd:
file: /verdaccio/auth/htpasswd
max_users: -1
uplinks:
patch-minor:
url: http://ip:9082
headers:
authorization: "Basic "
timeout: 30s
max_fails: 3
fail_timeout: 5m
patch-major:
url: http://ip:9081
headers:
authorization: "Basic "
timeout: 30s
max_fails: 3
fail_timeout: 5m
packages:
'@/':
proxy: [patch-minor, patch-major]
access: $authenticated
publish: $authenticated
'**':
proxy: [patch-minor, patch-major]
access: $authenticated
publish: $authenticated
server:
keepAliveTimeout: 0
middlewares:
audit:
enabled: false
log:
type: stdout
format: pretty
level: http
`
Observed Behavior
Verdaccio A receives a request for a package tarball
It returns HTTP 200 with bytes: 0/0 (no data)
Verdaccio then retries the same request against the uplink
After retries:
ESOCKETTIMEDOUT
500 internal server error
uplink marked as offline
Example logs:
`http <-- 200, user: null, req: 'GET /@jsonjoy.com/json-pack/-/json-pack-17.65.0.tgz', bytes: 0/0
info --- making request:
GET http://ip:9081/@jsonjoy.com/json-pack/-/json-pack-17.65.0.tgz
error --- unexpected error: ESOCKETTIMEDOUT
http <-- 500, req: 'GET /@jsonjoy.com/json-pack/-/json-pack-17.65.0.tgz',
error: internal server error
warn --- host ip:9081 is now offline
`
This repeats for many packages, especially scoped ones.
✅ What Works
Installing packages directly from Verdaccio B → works
Verdaccio B in offline mode → works
Verdaccio A + npmjs.org uplink → works
Issue happens only when Verdaccio → Verdaccio is used as uplink
❓ Questions
Is Verdaccio → Verdaccio chaining officially supported?
Is this behavior expected due to metadata / tarball streaming assumptions?
Are 200 (0 bytes) responses expected during metadata resolution?
Is there a recommended way to:
use one Verdaccio as a read-only upstream
in offline / air-gapped environments
If unsupported, is this a known limitation by design?
I came across the old issue below, which seems related but unresolved:
https://github.com/verdaccio/verdaccio/issues/1372?utm_
Goal
A stable setup where:
Verdaccio A consumes packages
Verdaccio B acts as a fully cached upstream
No external internet access is required
No repeated retries / uplink offline marking occurs
Beta Was this translation helpful? Give feedback.
All reactions