def render_sendmail(self):
        if not self.dj.dock_json_has_plugin_conf('exit_plugins', 'sendmail'):
            return

        if self.spec.pdc_url.value and self.spec.smtp_uri.value:
            self.dj.dock_json_set_arg('exit_plugins', 'sendmail', 'url',
                                      self.spec.builder_openshift_url.value)
            self.dj.dock_json_set_arg('exit_plugins', 'sendmail', 'pdc_url',
                                      self.spec.pdc_url.value)
            self.dj.dock_json_set_arg('exit_plugins', 'sendmail', 'smtp_uri',
                                      self.spec.smtp_uri.value)
            self.dj.dock_json_set_arg('exit_plugins', 'sendmail', 'submitter',
                                      self.spec.user.value)
            # make sure we'll be able to authenticate to PDC
            if 'pdc_secret_path' not in \
                    self.dj.dock_json_get_plugin_conf('exit_plugins',
                                                      'sendmail')['args']:
                raise OsbsValidationException('sendmail plugin configured, '
                                              'but no pdc_secret_path')
        else:
            logger.info("removing sendmail from request, "
                        "requires pdc_url and smtp_uri")
            self.dj.remove_plugin('exit_plugins', 'sendmail')
if we have pdc_url and smtp_uri, configure sendmail plugin,
dataset/ETHPy150Open projectatomic/osbs-client/osbs/build/build_request.py/ProductionBuild.render_sendmail