'Access-Control-Allow-Origin' header in the redirect app

Yunohost laptop@home/dynamic ip
I have installed cusdis in another server at home (docker), it’s up and running.
I have installed a redirect app to the ip:port of the cusdis app (proxypass for all).
The backend is accessible, but the integration is not working.
I get this error in the console of chrome

Access to script at 'https://sub.domain/js/iframe.umd.js' from origin 'null' has been blocked by CORS policy: The 'Access-Control-Allow-Origin' header contains the invalid value 'null//undefined'.

I searched the forum for this error, but it seems that every post is a specific case.
Should I edit /etc/nginx/conf.d/$domain.d/redirect.conf or /etc/nginx/conf.d/$domain.conf ?
Thanks for the help

I’ve finally found a solution

The code must be added to the redirect.conf
It’s working fine for more than two weeks.
Hope this will help the packaging of cusdis to yunohost in