generate-configuration: handle options, rewrite rules