Login/Register
Installatron Server
API Documentation

Improved "FTP" Performance for Installatron Server

Installatron Server uses the path value (defined as part of the user's websites, or provided to Installatron Server On Demand) to communicate with the destination web server. Due to the nature of the FTP protocol, all FTP-based protocols (FTP, FTPS and SFTP) limit the speed at which file operations can be completed.

To improve performance when using an FTP-based protocol, a SSH connection can be activated on demand which enables Installatron Server to execute commands efficiently on the destination web server.

Implementing SSH On Demand

To use this solution, implement these PHP methods:

public function enableSecondaryPathByWebsite($websiteInfo)
public function disableSecondaryPathByWebsite($websiteInfo)

-in this file:

/usr/local/installatron/etc/panel.php

Sample Code

Here is an example implementation of these methods in panel.php, to get you started:


<?php
class i_custom extends i_panel
{
    /**
     * Return the path URI for the provided website.
     *
     * @param   array   An array of website information as defined in the Installatron Server API Request Header.
     * @return  string  The URI for the website path, as it would have been defined for the Installatron Server Request Header.
     */
    public function enableSecondaryPathByWebsite($websiteInfo)
    {
        return "ssh://".urlencode("user").":".urlencode("pass")."@11.42.62.82/domains";
    }

    /**
     * Disable the path, if necessary, when Installatron Server no longer requires access.
     * This method is called immediately after the connection is no longer needed by Installatron Server.
     *
     * @param   array   An array of website information as defined in the Installatron Server API Request Header.
     * @return  bool    true if successful; false otherwise
     */
    public function disableSecondaryPathByWebsite($websiteInfo)
    {
        return true;
    }
}

With those methods performing their required tasks your user's FTP-protocol paths will be much more efficient.

Don't hesitate to contact Installatron Support if you have questions.



© 2004 - 2025 Installatron LLC. All rights reserved. Privacy Policy.