Skip to content

405 (cors error) on specific location #2409

@rap2hpoutre

Description

@rap2hpoutre

I created a nginx-proxy instance in a docker compose file:

  nginx-proxy:
    restart: always
    image: nginxproxy/nginx-proxy
    ports:
      - "80:80"
    volumes:
      - /var/run/docker.sock:/tmp/docker.sock:ro
      - ./.server/vhost:/etc/nginx/vhost.d

My vhost is like this:

client_max_body_size 50m;

location /encrypt {
  client_max_body_size 350m;
}

The goal is to allow 350m on a specific route, 50m otherwise.

It seems there is a problem because now, my route /encrypt returns cors error.
In other cases, there is no cors error. Cors are configured via nodejs for the whole application.

I don't reproduce this error without the nginx proxy.
How can I fix it?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions