mirror of
https://github.com/R0m1k3/Socialflow.git
synced 2026-10-11 17:26:45 +02:00
fix: use localhost for Remotion image URLs instead of Docker service hostname
Remotion's headless Chromium runs inside the same container as the app, so it must use http://localhost:PORT to fetch local media files. The Docker service hostname (socialflow-app) is only reachable from other containers on the Docker network, not from within the container itself. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
1 parent
abaee384bf
commit
a638cfba6a
1 file changed
+3
-2
@@ -93,8 +93,9 @@ remotionRouter.post("/render", upload.fields([{ name: "images", maxCount: 4 }, {
|
||||
const files = fields["images"] ?? [];
|
||||
let imageUrls: string[] = [];
|
||||
|
||||
const host = process.env.INTERNAL_APP_URL
|
||||
|| (req.protocol + "://" + req.get("host"));
|
||||
// Remotion's Chromium runs inside the same container — must use localhost, not the Docker service hostname
|
||||
const port = process.env.PORT || "5555";
|
||||
const host = `http://localhost:${port}`;
|
||||
|
||||
const existing = req.body.existingImageUrls;
|
||||
if (existing) {
|
||||
|
||||
Reference in new issue
Block a user