def sign_cart_for_env_maybe(self, cart, env=None):
        """
        Sign the items to upload, if the env requires a signature.

        `cart` - Cart to sign
        `envs` - The cart is signed if env has the property:
        requires_signature = True

        Will attempt to load the rpm_sign_plugin defined in
        ~/.config/juicer/config, which must be a plugin inheriting from
        juicer.common.RpmSignPlugin. If available, we'll call
        cart.sign_items() with a reference to the
        rpm_sign_plugin.sign_rpms method.
        """
        if self.connectors[env].requires_signature:
            cart.sync_remotes(force=True)
            juicer.utils.Log.log_notice("%s requires RPM signatures", env)
            juicer.utils.Log.log_notice("Checking for rpm_sign_plugin definition ...")
            module_name = self._defaults['rpm_sign_plugin']
            if self._defaults['rpm_sign_plugin']:
                juicer.utils.Log.log_notice("Found rpm_sign_plugin definition: %s",
                                            self._defaults['rpm_sign_plugin'])
                juicer.utils.Log.log_notice("Attempting to load ...")

                try:
                    rpm_sign_plugin = __import__(module_name, fromlist=[module_name])
                    juicer.utils.Log.log_notice("Successfully loaded %s ...", module_name)
                    plugin_object = getattr(rpm_sign_plugin, module_name.split('.')[-1])
                    signer = plugin_object()
                    cart.sign_items(signer.sign_rpms)
                except ImportError as e:
                    juicer.utils.Log.log_notice("there was a problem using %s ... error: %s",
                                                module_name, e)
                    raise JuicerRpmSignPluginError("could not load rpm_sign_plugin: %s; additional information: %s" % \
                                                       (module_name,
                                                        e))

                if not juicer.utils.rpms_signed_p([item.path for item in cart.items()]):
                    raise JuicerNotSignedError('RPMs have not been signed.')

            else:
                raise JuicerConfigError("Did not find an rpm_sign_plugin in config file but the %s environment requires signed RPMs." % env)
            return True
        else:
            return None
Sign the items to upload, if the env requires a signature.

        `cart` - Cart to sign
        `envs` - The cart is signed if env has the property:
        requires_signature = True

        Will attempt to load the rpm_sign_plugin defined in
        ~/.config/juicer/config, which must be a plugin inheriting from
        juicer.common.RpmSignPlugin. If available, we'll call
        cart.sign_items() with a reference to the
        rpm_sign_plugin.sign_rpms method.