EZ Template Directory Structure
All EZ templates and the software packages included in them and installed on the host are located in the so-called template area the path to which is set as the value of the TEMPLATE variable in the /etc/vz/vz.conf file. By default, the /vz/template directory is used. The template area includes two main subdirectories:
In its turn, the < arch > directory contains the following subdirectories and areas:
As has been mentioned above, the configuration directory (i.e. /< template_area >/< template_directory >/config ) contains a number of subdirectories storing 'EZ templates'-related configuration files. The contents of these subdirectories can vary depending on whether it is a base OS EZ template or a non-base one and on the EZ template type (OS or application template). The most important configuration files are listed below:
- Data files:
packages : contains a list of software packages names included in the corresponding EZ template.package_manager : specifies the packaging system used to handle the EZ template.repositories : a list of repositories where the packages comprising the EZ template are stored.mirrorlist : one or several URLs to the file containing a list of repositories from where the packages comprising the EZ template are to be downloaded.distribution : the name of the Linux distribution for which the EZ template is created. This file should be absent for application EZ templates.summary : brief information on the EZ template.description : detailed information on the EZ template. As distinct from the summary file, it can contain additional data relevant for the EZ template.environment : a list of environment variables set in the form of key = value .
- Scripts:
pre-cache : this script is executed before installing the packages included in the EZ template on the host.post-cache : this script is executed after installing the packages included in the EZ template on the host.pre-install : this script is executed before adding the EZ template to or installing the package inside the Container.post-install : this script is executed after adding the EZ template to or installing the package inside the Container.pre-upgrade : this script is executed before updating the packages inside the Container.post-upgrade : this script is executed updating the packages inside the Container.pre-remove : this script is executed before removing the application EZ template/package from the Container.post-remove : this script is executed after removing the application EZ template/package from the Container.
- Document files: one or several files with arbitrary names containing the information on the EZ template (e.g.
README ).
Note: Detailed information on the files contained in the OS template configuration directory is provided in the Virtuozzo 6 Command Line Reference Guide.
While working with EZ template configuration files, keep in mind the following:
- The
packages file should be specified for all EZ templates. - The
packages , package_manager , and repositories/mirrorlist files should be specified for all base OS EZ templates. - The
package_manager and distribution files should be specified for all base OS EZ templates and absent for non-base OS EZ templates and all application EZ templates.
The information from the repositories/mirrorlist files created for non-base OS and all application EZ templates is added to that in the repositories/mirrorlist files for the base OS EZ template.
|