Managing Web-scripts (APS)

From ISPWiki
Jump to: navigation, search

Web-scrips (APS) is a convenient way for managing popular web-oriented software. ISPmanager supports APS 1.0, 1.1, 1.2.

Working with APS repositories

The control panel uses the official APS repository that can be accessed at http://apscatalog.com/all.atom

Server administrators can add a custom APS repository. Add the following parameter into the configuration file to specify the path to the repository xml file:

ApsExtRepository

Example:

ApsExtRepository http://my.web.aps/repo.xml

When updating the list of Web-scripts, the control panel will upload and analyse the repository files, and save information about available packages into the database.

In ISPmanager Business all the information related to script packages is kept in the master-panel database.

When a specific APS package is installed for the first time, the Web-script is downloaded into the server, and installed into the web-domain's directory selected by the user. If another user is trying to install the script for the second time, a local copy of APS will be applied.

In ISPmanager Business scripts are downloaded into the server running the master-panel. When a user installs s package, it is copied into a required cluster node, if needed.

List of web-script packages available to users

The Web-scripts modules delivers different function for Users and Administrators. Administrators can view the list in the "Web-script directory" module.

Users can use only those APS packages that they are allowed to use in the "Web-script packages" module (click the List button in the "Web-script directories" module). Administrator can activate a certain APS package for his users, and select a default package (in case of "Quick install", see description below).

On the User level packages are grouped by names into aa signlelist, each group having the Install button. When clicking this button a user will be asked to choose a package version ("Default" version is already selected and is shown in green color), and follow the steps of the Setup Wizard.

In the Web-domains module click the Scripts button to view the list of user Web-scripts. The table is displayed for the selected web-domain, so it also contains the information about web-scripts installed, and enables to delete any of the web-script. Deleting the web-script won't delete user information. Clicking the "Quick install" button will install a desired web-script with default version and configuration.

Web-script updates

When updating the list of Web-scripts, all the information about APS packages available will be updated as well. Thus, some packages can be added into the list, and some of them can be deleted. To make Web-scripts available for users during the update process, administrator can modify the settings.

Locate the file aps_settings.xml in the directive etc/templates.

File example:

<doc>
  <imagemapping defimg="aps.png">
    <apsimg name="Drupal">drupal.png</apsimg>
    <apsimg name="joomla">joomla.png</apsimg>
    <apsimg name="WordPress">wordpress.png</apsimg>
    <apsimg name="Prestashop">prestashop.png</apsimg>
    <apsimg name="phpBB">phpbb.png</apsimg>
  </imagemapping>
  <updaterules>
    <onupdate name="Drupal" type="latest"/>
    <onupdate name="joomla" type="latest" quantity="1"/>
    <onupdate name="WordPress"/>
    <onupdate name="Prestashop" quantity="2"/>
    <onupdate name="phpBB" force="yes"/>
  </updaterules>
  <defverrules>
    <defver name="Drupal"/>
    <defver name="joomla" type="latest"/>
    <defver name="WordPress"/>
    <defver name="Prestashop"/>
    <defver name="phpBB"/>
  </defverrules>
</doc>

The imagemapping section

This section describes web-scripts' icons (they are displayed for each web-domain in the list). The defimg attribute defines a default icon that will be used if the icon corresponding to the script name, is not found.

Icons should be located in the skins/common/img directory of the control panel and have the format: 32*32 pixels, png.

Every apsimg element contains the name of the icon that can be used for the web-script, which name is specified in the name attribute.

The updaterules section

This section defines update rules for a web-script.

Every onupdate element contains an update rule for the web-script, which name is specified in the name attribute.

Element attributes:

  • name - name of the Web-script this rule will be applied to (e.g. name="joomla")
  • type - automatic selection type. Possible values - latest (use the latest versions available), earliest (use the oldest versions), definite (select a specific version) (e.g. type="latest"). if the definite attribute is used, in the onupdate element you should specify the web-script version (e.g. <onupdate name="Drupal" type="definite">7.31-36</onupdate>). latest is used by default
  • quantity - number of Web-script packages (e.g. quantity="1"). It can be used, if "type" is set to "latest" or "earliest", if the value is more than one, the specified number of packages will be available by default. With the combination of type="latest" and quantity="3", the last three versions of Web-scripts will be available. 1 is used by default
  • force - if this attribute is not specified, rules are applied only when a list of packages of a certain Web-script does not contain packages available to users. If the attribute value is set to "yes" (force="yes"), package versions can be redefined based on the rule, upon every update. Versions that were available to users before this operation was performed, will become inaccessible.

The defverrules section

This section describes how the default package version is selected from the list.

Every defver element contains a rule for automatic selection of the default version for the web-script, which name is specified in the name attribute.

Element attributes:

  • name - name of the Web-script this rule will be applied to (e.g. name="joomla")
  • type - automatic selection type. Possible values - latest (use the latest versions available), earliest (use the oldest versions), definite (select a specific version) (e.g. type="latest"). if the definite attribute is used, in the onupdate element you should specify the web-script version (e.g. <onupdate name="Drupal" type="definite">7.31-36</onupdate>). latest is used by default

According to the rules described in the updaterules section, after the list of Web-scripts has been updated, some Aps packages will become available to users. According to the rules described in the defverrules section, one of the packages will be used as default.

The rules from defverrules are also applied when the administrator wants to hide Web-scripts from users. For example, after you have hidden a web-script, a few web-scripts may still be available to users, so one of them will be used as a default script according to those rules.