The common solution posted is to run
sudo dpkg-reconfigure x11-common which gives a graphical prompt, however, I'm wanting to use this non-interactively.
Scenario is that I'm SSH'd into a machine as root (during Vagrant provisioning) and need to run
startx once as a regular user to generate some config files before proceeding to subsequent steps.
I believe the reason I cannot simply
su otheruser startx is due to Xauthority/me being connected via SSH as another user...