diff --git a/Dockerfile b/Dockerfile index 45e0512..54d6a94 100644 --- a/Dockerfile +++ b/Dockerfile @@ -4,4 +4,4 @@ WORKDIR /app COPY . . RUN npm ci -CMD npx serve --cors /mnt/media/files +CMD ["npx", "serve", "/mnt/media/files", "-c", "/app/serve.json"] diff --git a/serve.json b/serve.json new file mode 100644 index 0000000..40205cf --- /dev/null +++ b/serve.json @@ -0,0 +1,11 @@ +{ + "cors": { + "origin": ["https://evilspins.com", "http://localhost:3000"], + "methods": ["GET", "HEAD", "PUT", "PATCH", "POST", "DELETE"], + "allowedHeaders": ["Content-Type", "Authorization"], + "exposedHeaders": ["Content-Range", "X-Content-Range"], + "credentials": true + }, + "etag": true, + "cacheControl": true +}