make realm configurable in config