How can i force google to stream my ip camera?

Hello,

my setup is as followed, a pi4 running Home Assistant Os.
im also using duckdns as a external domain.
My config for the camera’s is:

camera:
  - platform: generic
    name: Buiten Camera
    still_image_url: http://192.168.xx.xx/jpg/image.jpg
    stream_source: rtsp://192.168.xx.xx:554/11
    
  - platform: generic
    name: Aanbouw Camera
    still_image_url: http://192.168.xx.xx/jpg/image.jpg
    stream_source: rtsp://192.168.xx.xx:554/11
    
  - platform: generic
    name: Binnen Camera
    still_image_url: http://192.168.xx.xx/jpg/image.jpg
    stream_source: rtsp://192.168.xx.xx:554/11

My script is:

camera_play:
  alias: Play Video on Chromecast
  sequence:
  - service: camera.play_stream
    data_template:
      media_player: >
        {% if is_state("input_select.camera_display", "Bedroom display") %} media_player.bedroom_display
        {% elif is_state("input_select.camera_display", "Living Room display") %} media_player.living_room_display
        {% elif is_state("input_select.camera_display", "Kevin Tv") %} media_player.kevin_s_tv
        {% endif %}
      entity_id: >
        {% if is_state("input_select.camera_select", "Buiten Camera") %} camera.buiten_camera
        {% elif is_state("input_select.camera_select", "Binnen Camera") %} camera.binnen_camera
        {% elif is_state("input_select.camera_select", "Aanbouw Camera") %} camera.aanbouw_camera
        {% endif %}

And i made a file with input select:

camera_select:
  name: 'Select Camera'
  options:
    - 'Buiten Camera'
    - 'Binnen Camera'
    - 'Aanbouw Camera'
  initial: 'Buiten Camera'
  icon: mdi:camera

The camera’s show up correctly in home assistant and i can use them in a glance card for streaming.

The issue is when i try to cast any of the camera’s to either google chrom/hub, it makes the pling sound and a cast icon appears but the stream doesn’t load. I know it has something to do with certificates and google not accepting regular ip’s.

The reason is when i changed my internal ip to use my duckdns domain everything worked.
The only issue is that other things stopped working.
So does anyone know how to make a config or setup so that google will cast via the duckdns (external ip) instead of the internal?

thank you