def initialize_plugins
      @plugin_chain = []

      os_plugin, os_plugin_info = PluginManager.instance.initialize_plugin(:os, @appliance_config.os.name.to_sym)
      initialize_plugin(os_plugin, os_plugin_info)

      if platform_selected?
        platform_plugin, platform_plugin_info = PluginManager.instance.initialize_plugin(:platform, @config.platform)
        initialize_plugin(platform_plugin, platform_plugin_info)
      end

      if delivery_selected?
        delivery_plugin, delivery_plugin_info = PluginManager.instance.initialize_plugin(:delivery, @config.delivery)
        # Here we need to specify additionally the type of the plugin, as some delivery plugins
        # can have multiple types of delivery implemented. See s3-plugin.rb for example.
        initialize_plugin(delivery_plugin, delivery_plugin_info, :type => @config.delivery)
      end
    end
def initialize_plugins
      @plugin_chain = []

      os_plugin, os_plugin_info = PluginManager.instance.initialize_plugin(:os, @appliance_config.os.name.to_sym)
      initialize_plugin(os_plugin, os_plugin_info)

      if platform_selected?
        platform_plugin, platform_plugin_info = PluginManager.instance.initialize_plugin(:platform, @config.platform)
        initialize_plugin(platform_plugin, platform_plugin_info)
      end

      if delivery_selected?
        delivery_plugin, delivery_plugin_info = PluginManager.instance.initialize_plugin(:delivery, @config.delivery)
        # Here we need to specify additionally the type of the plugin, as some delivery plugins
        # can have multiple types of delivery implemented. See s3-plugin.rb for example.
        initialize_plugin(delivery_plugin, delivery_plugin_info, :type => @config.delivery)
      end
    end
Here we initialize all required plugins and create a plugin chain.
 Initialization involves also plugin configuration validation for specified plugin type.