Changes in WSL2 made my configuration stop working, too. I had to add the following to my ~/.bashrc file to make it work again:
# Get the IP Address of the Windows 10 Host and use it in Environment.
HOST_IP=$(host `hostname` | grep -oP '(\s)\d+(\.\d+){3}' | tail -1 | awk '{ print $NF }' | tr -d '\r')
export LIBGL_ALWAYS_INDIRECT=1
export DISPLAY=$HOST_IP:0.0
export NO_AT_BRIDGE=1
export PULSE_SERVER=tcp:$HOST_IP
After doing that, any BASH prompt should enable sound, regardless of your Host IP address or WSL IP address. You’ll use similar in command lines in shortcuts to Linux GUI programs to get sound to work with various programs, as needed. Below is a screenshot of Linux and Windows programs working together, while watching a video on YouTube, using Google-Chrome on Linux in WSL.