set repository and service in config, and begin db