Newbie question here, apologies in advance.
By using a static content server (nginx as reverse proxy), how does
one deal with user uploads? I mean, I can understand if I client
request our websiteâ€™s /images/logo.png file, because we manually store
it on the static content server, but what about the photo that our
user just uploaded to his photo album?
My confusion is: if a request is to a .php file, Iâ€™ll pass through the
back-end server. So If a user wants to upload a file, itâ€™ll be upload
to /user-uploads/file.jpg on the back-end server. How can we make
the static server serve the image? Iâ€™m imagining there has to be some
sort of synchronization, but then again there the problem that the
image might take longer to be replicated to the static content server
and when the user requestâ€™s it, heâ€™ll get a 404â€¦ not acceptable for
Can anyone with more experience tell me what am I missing?