ResolutionPlease follow these instructions if you are going to customize the mail system within Parallels H-Sphere environment or apply some extra patches.
Note: It is highly recommended not to use the box with the working mail system. In order to build a custom mail system, you should use a separate box. Otherwise, the cluster structure may be broken.
1. Download the latest Parallels H-Sphere packages from the following source:
<VERSION> - mail system version;
<BUILD> - mail system build.
Please note that this article is targeted at the fifth mail system version and lower. Apart from this, please pay attention to the <BUILD> number you choose. We recommend using the latest builds as they have more bug-fixes/features included.
2. Create an empty folder, copy the downloaded archive to this directory and unpack it with the following command:
# tar zxf hsphere-mail-filter-<VERSION>-<BUILD>.tgz
3. In this directory:
./version.sh is the file that includes all products versions on which the mail system is based and all the patches applied. You should edit it in case the mail system is to be built on a new product version (e.g., new ClamAV, Spamassasin, Vpopmail, ...);
./build.sh is a mail build script. It should be used for new configure/compile options.
src/ - the directory where all products sources and patches are located
hsphere-mail-service/ is the directory where the mail service startup files, configs and other data needed for a package creation are stored;
4. To patch products used by the service (e.g. qmail, clamav, etc.), please follow these steps:
- Enter the ./src directory
- Unpack the necessary product sources from the archive located in the directory.
- Enter the product sources directory and make the necessary changes, apply
- Pack the sources. Give the archive the same name and version. In case you want to change the product archive version, please make the corresponding changes in the version.sh file.
Please note that the new product archive should be located in the 'src' directory.
5. To change any config templates or startup scripts, please enter hsphere-mail-service directory and bring in the necessary changes.
6. In case you are going to include a new version of the product, please follow these steps:
- Download the product sources and place the archive at src directory. Please note that the product archive should be packed with the same software and have the same extension (.tgz, .tbz, .tar.gz, etc). Please look at the product version provided and use the corresponding software and the same extension for packing.
- Edit the new product version field in ./version.sh.
7. In case you would like to build a full Parallels H-Sphere mail system package, (not just get new binaries installed), you should install EPM package creation software on the box.
Please refer to the following KB article for that purpose:
Also we recommend you to change the mail system package build number, 'version.sh', and 'BUILD' variable.
- If you do not install EPM, the script will build and install new software to the same directories as on the working cluster. You should copy all of them to the box with the working mail system.
8. To build a package or build and install mail service with your changes, just run the following command as the 'root' user:
# sh ./build.sh