Move configuration to file.

@njam Please review.
Add return type docu