protected function outputModulesConfiguration(ParameterBag $post)
    {
        $modulesClasses = array();
        $modulesNames = array();

        foreach ($this->modules as $key => $value) {
            if ($post->has($key)) {
                $modulesClasses[] = $value;
                $modulesNames[] = $key;
            }
        }

        $config = array(
            self::CONFIG_PLUGIN_KEY => array(
                self::CONFIG_MODULES_KEY => $modulesClasses
            )
        );

        $yaml = \Symfony\Component\Yaml\Yaml::dump($config, 2, 4);

        // Adds output to the template variables
        $this->picoAuth->addOutput("installer_modules_config", $yaml);
        $this->picoAuth->addOutput("installer_modules_names", $modulesNames);
    }