
In 2007, SWSoft, now
Parallels , published a new standard of tools for deploying web applications on hosting -
APS - Application Packaging Standard :
apsstandard.org .
The APS format is designed to simplify the implementation of the Software-as-a-Service (SaaS) business model for cloud service providers and software developers. APS package — A web application packaged in accordance with the APS standard.The article presents a brief overview of the APS standard and a description of the process of preparing and publishing an APS package in a publicly accessible directory using the example of the APS package CMS
Livestreet , the output of which aroused some interest in Habré: (
The LiveStreet Blog CMS ).
I hope the article will interest web application developers, service providers and users of their services.
Introduction to APS
Currently, the APS standard is supported by Parallels hosting panels: Plesk, Small Business Panel, POA (
parallels.com ) and SysCP (
syscp.org is an open source project). According to the available information, ISPSystem (
ispsystem.com ), the developer of the ISPManager panel, is considering the possibility of supporting the APS standard.
In total, more than 200 CMS titles and various web applications (both commercial and open source) are published in the APS catalog:
apsstandard.org/appIn short, the procedure for preparing and using the APS package is as follows:
- The CMS developer (or other “packer”) “packs” an APS web application;
- The received APS package is certified and placed in a publicly accessible directory;
- The hosting provider downloads the package and provides it to its Customers;
- The user gets the opportunity to install a one-click web application in the hosting control panel.
Many people know the “kit”
fantastico and similar means of auto installation, why was it necessary to invent something new? But there are differences:
- Any developer can add his product to the APS catalog, it’s enough to deal with the standard and get certified with the package. It also ensures timely updates;
- fantastico includes 50 web applications - in the APS-catalog there are already more than 200 titles (there are also Russian-speaking);
- The APS standard allows you not only to install a web application from the hosting control panel, but also to change the template, install the plugin, reset the password, perform an update, etc .;
- The APS standard can also be used in Parallels Virtuozzo Containers, including not only a web application, but also server software.
The advantages of using the APS-standard:
- For the developer of services and web applications - the popularization of their product;
- For a hosting provider - expanding the range of services;
- For the user - to simplify installation: no need to download the distribution kit, deal with the installation procedure - even to know what FTP is, it gets a working site or web service;
- For Parallels and other developers, hosting panels are an expanding market.
')
Developer - Prepare APS package
The first thing to do is to study the documentation of the APS standard. Documentation published at:
apsstandard.org/isv/documentationNote: There are differences in the use of standards, for example, the APS 1.0 standard is supported in Parallels Plesk 9.x, APS1.1 - in the POA (Parallels Operation Automation).
Plesk 10 is scheduled for release this year, and after a couple of weeks, POA 5.0 will be released with support for APS 1.2.The architectural feature of the APS standard is a declarative model for describing an application and minimizing the amount of “adapter” code connecting the application to the hosting system. This approach was chosen as more secure - the less “alien” code is executed on the provider's servers, the better.
Briefly consider the structure of the APS package.
APP-META.xml
- package description file. Describes the version, requirements, changelog, etc.
It also generates an interface for entering the data required to install the application. When installing an APS package, both standard options - login and password and database name, username and password to the web application admin panel can be offered, as well as advanced options, for example, choosing the type of DBMS, display template, registration data, etc. . The advanced use of the APS package on the example of installing the Django python framework is shown in the article:
Django Automatic InstallationThe package also contains directories:
htdocs
- web application files;
images
- screenshots of the installed web application, displayed when viewing information about the package;
scripts
- application installation and configuration scripts, the directory also contains a database dump and SQL queries for changing the login / password from the control panel.
The general procedure for preparing an APS packet is as follows:
- From the distribution package of the web application, the files are copied to the htdocs folder;
- The database dump is also copied in the tables in which the user credentials are stored, the administrator's login / password / e-mail are replaced with variables - when installing the application, the entered credentials will be recorded directly in the database;
- APP-META.xml is being prepared.
There is no need to make changes to the code of the application itself.
When preparing an APS package, it is desirable to have access to a panel that supports the APS standard.
Developer - Certification and publication on apsstandard.org
Let us describe the sequence of certification and publication in the public directory of the APS web application package using the example of
CMS Livestreet .
You can access the testing tools by contacting:
apsstandard.org/feedbackThe main testing, certification and deployment tool - Packager administration panel:
apscatalog.com/packager/adminThe control panel is written in
Django , has a fairly simple interface, focused on a large number of packages.

Clicking the link “Upload new package”, go to the form to add a package. Select the desired package and click “Upload” to download the package. Please note that when adding a new version of the package, you must change the version number and add a changelog. In the example, the full name of the package is Livestreet 0.4.1-1, where the version number of the package follows the hyphen (1).
After adding a package, it is automatically tested. You can monitor the current status of the tests by periodically pressing the “Update test report” button. The process can take a long time. This is how the test results look like:

The “Test report” section of the report displays test results for installing and configuring applications. In the subsection “Test steps” the passed test steps are displayed, log files and screenshots of tests are also available there.

In case of unsuccessful passing of the test, an error message is displayed in the “Details” column. The error may be in the package itself, in the application or on the server side.
You can contact apsstandard.org technical support through the form on the website:
apsstandard.org/feedback . You can write in Russian or English, respond fairly quickly and friendly. In case of unsuccessful tests, the reason for the error is explained. If errors occur on the server side, they will restart the tests.
After successful completion of all tests, the application will be published in the APS-catalog. Used in the Livestreet example, published with Gold application status, APS 1.0 standard at:
http://www.apsstandard.org/app/#pkg_name=LiveStreet&pkg_vendor=livestreet.ru&pkg_ver=0.4.1&pkg_rel=1or in the section of the Web directory - Blogs:
http://www.apsstandard.org/app/#category=Web%2FBlogSince the publication of the LiveStreet APS package, 125 downloads from the APS catalog have been made in three days.Hosting Provider - Download APS Package
As soon as the application is published in the APS-catalog, it becomes available to all service providers. Let us demonstrate how a provider can download CMS Livestreet, and how the user can use it later - using the example of Parallels Plesk.

Go to the section "Application Storage" - "APS Directory". We find the application in the appropriate category or search by name, choose to add it and make it available for installation to all users. Then it’s enough to press the “Add to storage” button and wait for the upload to the server.
A list of hosting providers that have passed APS certification is published on apsstandard.org/hsp .User - Install APS web application package
The client of the service provider enters the Control Panel and selects the domain on which you plan to install the CMS Livestreet. In the group of options "Applications and Services", select the item "Web Applications" and click "Install Web Application." Then in the list of available web applications, select the required APS package and click "Install".
During installation, the end user selects the target directory, enters passwords for access to the database and the administrative part of the site. Special knowledge does not require auto installation.
Applications are located in the catalog by sections: Content Management, Blog, Gallery, E-commerce, E-learning, Forum, Schedules, Project Management, etc.

By clicking the “Install” button, you will receive in a few seconds a ready-made installed CMS Livestreet application or any other from the catalog.

We looked at the entire path of the APS package — from its creation to installation by the user. Of course, the article does not cover all the technical aspects. This is only a brief overview of the use of the APS standard, and not a detailed instruction on how to create and use packages.
Ready to add an article on issues of interest Habr.
I hope the article interested web application developers and colleagues - hosting providers.