Feature/internal repo

This is quickly turning into a mega PR request, and the work on the web panel is basically halted until this is merged, so I'm hoping this can get reviewed and merged ASAP.