It’s usually better to configure a proxy with nginx to make a better security layer on top of your streamlit app.
In that case your domain name is pointing to your rpi router (check dns like cloudflare), then is blocked by nginx (you can also add an auth step) and then redirect to your streamlit app.
I’m not a security expert or network expert, but I read a lot of times that exposing app ports directly to internet was not really recommended.