Aws hosting on windows server cors issue

Hi i hosted the strapi backend on aws server. On the server it works. I did try redirecting the admin URL to a build location but that does the same thing.

I think i am getting this cross domain issue. I tried to resolve it my adding cors. I am actually new to nodejs deployment. I need help in understanding how to setup production env and build. I also have a react client app and it also not able to open cors domain request.

    name: 'strapi::cors',
    config: {
      enabled: true,
      header: '*',
      origin: ['http://localhost:1337','https://localhost:1337' ]

System Information
  • Strapi Version: 4.5.2
  • Operating System: windows server 2019
  • Database: mysql
  • Node Version: v16.13.1
  • NPM Version: 8.19.2
  • Yarn Version: 1.22.17