PM_request Plugin
This plugin listens to requests for package management commands from within the buildroot, using unix socket. It can be used by buildsystems, such as Maven, to automatically install missing packages if they're available. It's disabled by default to not affect build reproducibility. A warning is issued at the end of the build if the plugin was used.
Configuration
In your config file insert the following lines:
config_opts['plugin_conf']['pm_request_enable'] = False
It will create socket in /var/run/mock/pm-request inside of chroot and will read from this socket package manager command and executes them. E.g.
builddep foo install bar
Available since mock-1.2.9