How should I generate the view position for a light at infinity when creating depth maps?
Instead of using a perspective projection you would use a orthographic projection.

Then the trick is to position the bounding box to in front of the normal camera.

An additional option is to add a skew/shear operation so it maps the light direction to the vertical and keeps the horizontal ground plane horizontal.

This avoids leaving a large dead zone underground near the light source.