Selling backup space (ftp)

From ISPWiki

Jump to: navigation, search

This article goes you through the steps you need to perfom if you want to seel additional space for backups as an ftp-account. We will use the ISPmanager control panel.

Creat a custom item type named "storage". Select the check box "Require server". In the product configuration form actiate the "dik" add-on.

In the item parameters form create the following:

1.

 Name - Server address
 Internal name - addr
 Parameter type - is specified when the service is processed 
 Can change  - only provider any time 
 Other fields are optional 

2.

 Name - Username
 Internal name  - user
 Parameter type - is specified when the service is processed 
 Can change  - only provider any time 
 Other fields  - leave the default values 

3.

 Name - Password
 Internal name  - passwd
 Parameter type - is specified when the service is processed 
 Can change  - only provider any time 
 Other fields - leave the default values 

You should also add a processing server running ISPmanager. Specify the user access privileges, rather than admin. FTP-accounts will belong to that user. To be able to create protected FTP directories in ISPmanager, select the check box "allow users to create FTP-accounts with private home directory in the polciy settings module (specify the option Option AllowFtpPrivateDir in the configuration file).

Create a standard service package, where the item type is the one created on teh first step. Select the check box "Available for order even if no servers are available". Do not provide the internal name. Assign this package to a server and you may start using it.

Message template

Example of the xslt template storageopen

 <?xml version='1.0'?>                                                          
 <xsl:stylesheet version='1.0' xmlns:xsl='http://www.w3.org/1999/XSL/Transform' xmlns:mgr="http://ispsystem.com/xslplugin">
 <xsl:output method='text' encoding='UTF-8' omit-xml-declaration='yes'/>
 <xsl:template match='doc'>From: <xsl:value-of select="project.notifyemail"/>
 Subject: <xsl:value-of select="mgr:encodesubject(concat(project.name,' : Space for backups is allocated to your account'))"/>
 Content-Type: text/plain; charset=utf-8
 Space for backups was allocated to your account at your request. Access details:
 Address: <xsl:value-of select="item.addr"/>
 User: <xsl:value-of select="item.user"/>
 Password: <xsl:value-of select="item.passwd"/>
 Please note that you can access the backup server only from our servers. 
 Hosting-provider <xsl:value-of select="project.name"/>
 </xsl:template>
 </xsl:stylesheet>
Was this helpful? Yes | No
Views
Personal tools