<?xml version="1.0" encoding="UTF-8"?>
<ajxpdriver name="sftp" enabled="false" label="CONF_MESSAGE[FTP over SSH]" description="CONF_MESSAGE[Access a remote server filesystem using FTP via SSH server. Handy for working around permissions problems.]" mixins="credentials_consumer,filesystem_commons,slug_provider,template_provider" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="file:../core.ajaxplorer/ajxp_registry.xsd">
    <client_settings icon="plugins/access.sftp/icon.png" description_template="{SERV}{PATH}" iconClass="icon-sitemap">
        <resources>
            <i18n namespace="sftp_access" path="plugins/access.sftp/i18n"/>
            <js className="FSActions" file="plugins/access.fs/res/build/FSActions.js" depends="PydioComponents"/>
        </resources>
    </client_settings>

	<server_settings>
		<param name="SERV" type="string" label="CONF_MESSAGE[Server URL]" description="CONF_MESSAGE[Path to remote sftp server]" mandatory="true"/>
		<param name="PORT" type="string" label="CONF_MESSAGE[Port number]" description="CONF_MESSAGE[Port to SSH server]" mandatory="true" default="22"/>
		<param name="PATH" type="string" label="CONF_MESSAGE[Path]" description="CONF_MESSAGE[Real path to the folder on the server]" mandatory="true"/>
		<param name="FIX_PERMISSIONS" type="string" label="CONF_MESSAGE[Fix Permissions]" description="CONF_MESSAGE[How to handle remote permissions to be used by PHP as local permissions. See manual.]" mandatory="false" default="detect_remote_user_id"/>
        <param name="CREATE" type="boolean" label="CONF_MESSAGE[Create]" description="CONF_MESSAGE[Create folder if it does not exists]" default="false" mandatory="false"/>
        <global_param group="MIXIN_MESSAGE[Metadata and indexation]" name="DEFAULT_METASOURCES" type="string" label="MIXIN_MESSAGE[Default Metasources]" description="MIXIN_MESSAGE[Comma separated list of metastore and meta plugins, that will be automatically applied to all repositories created with this driver]" mandatory="false" default="metastore.serial,meta.filehasher,index.lucene"/>
    </server_settings>
	<class_definition filename="plugins/access.sftp/SFTPAccessDriver.php" classname="Pydio\Access\Driver\StreamProvider\SFTP\SFTPAccessDriver"/>
	<registry_contributions>
        <external_file filename="plugins/access.fs/fsTemplatePart.xml" include="client_configs/*" exclude=""/>
		<client_configs>
			<template_part ajxpId="search_container" ajxpClass="SearchEngine" ajxpOptions='{"toggleResultsVisibility":"search_results_cont", "openSearchInput":"true", "openSearchStickLeftTo":"topPane", "searchChooserAsResultsHeader":true, "toggleResultsFitTo":"cpane_tabs", "fitMarginBottom":0, "toggleResultsOffsetRight":0, "toggleResultsOffsetTop":0, "detailThumbSize":24}'/>
            <component_config component="FilesList">
				<columns switchGridMode="filelist">
					<column messageId="1" attributeName="ajxp_label" sortType="StringDirFile"/>
					<column messageId="2" attributeName="filesize" sortType="NumberKo"/>
					<column messageId="3" attributeName="mimestring" sortType="String"/>
					<column messageId="4" attributeName="ajxp_modiftime" sortType="MyDate"/>
				</columns>
			</component_config>
			<component_config component="FoldersTree">
				<property name="display" value="d"/>
			</component_config>
		</client_configs>
		<external_file filename="plugins/access.fs/fsActions.xml" include="actions/*" exclude=""/>
		<external_file filename="plugins/access.fs/fsActions.xml" include="client_configs/*" exclude=""/>
        <external_file filename="plugins/access.fs/manifest.xml" include="registry_contributions/hooks/*" exclude=""/>
	</registry_contributions>
	<dependencies>
		<pluginClass pluginName="access.fs"/>
	</dependencies>
    <class_stream_wrapper filename="plugins/access.sftp/SFTPAccessWrapper.php" classname="Pydio\Access\Driver\StreamProvider\SFTP\SFTPAccessWrapper" protocol="ajxp.sftp"/>
</ajxpdriver>
