The FreePBX Framework module is not like other modules on the system. Its purpose is to provide a mechanism to upgrade the overall Framework of FreePBX as described below.

Simple FreePBX Architecture Description

FreePBX is a modular architecture that can easily be extended with new modules to add functionality to the main system or extend existing functionality. In the absence of any module being loaded, there is still a foundation of code that is required to enable the system. This code base is referred to as the FreePBX Framework. Once the Framework is loaded, the system requires a minimal set of modules to provide any useful functionality. These include Core as well as a handful of other Key modules without which the system will not properly function. When FreePBX is initially installed, these modules are all installed at that time.

Module Administration in Framework

Part of the Framework code is the Module Administration Page. Once you have a Framework loaded, Adding modules is fairly straight forward. Under the covers, FreePBX simply explodes a module's tarball into the modules directory and then executes any included install scripts that the module requires.

Framework as a Module

In order to provide a mechanism that upgrades the Framework code, it was previously necessary to manually download a new version's tarball and then run install_amp which would upgrade you to that new version. Running install_amp is effectively takes files form the tarball and copies them onto the framework code in a similar manner to installing a module. (It does a bit more, but that is out of the scope of this description). The Framework module does effectively the same thing as install_amp. After being loaded by Module Admin it has a directory structure that is very similar to what you would see when untarring a FreePBX tarball. The Module Administration code then executes Framework's install script as if it were just another module. (As far as it know, it is just another Module). The install code proceeds to do almost the same thing that install_amp does resulting in all the Framework files being updated, and any incremental upgrade scripts being run. (It shares the same libraries as install_amp so it is basically the same code running.