In this document:
The base environment type provides an ability to deploy APS applications with certain requirements to their environment. Any type that implements the application type may require an environment type as a dependency through a strong relation.
Responsibility of the environment is:
Provide the required environment for the application, for example, standard PHP package and database system.
Deploy application files from an APS package (see Install Application Instance for more details).
Configure an APS endpoint for the application, so that the APS controller is able to connect to the application directly. The environment also upgrades files of already provisioned applications (see Upgrade for details).
It is also possible for one environment to “know” how to work with different types of applications (for example, there may be a “PHP+Python” environment that can deploy both “PHP” and “Python” types of applications, etc.).
Each environment is used to install application instances and it follows the Install Application Instance workflow for this.
The environment type
definition:
{
"apsVersion": "2.0",
"name": "Environment",
"id": "http://aps-standard.org/types/infrastructure/environment/1.0",
"properties": {
"entryPoint": {
"type": "string",
"description": "Application access point"
},
"engines": {
"type": "array",
"items": {
"type": "string",
"description": "List of supported engines",
"pattern": "php|python|perl|java|.net|exec|.+"
}
},
"hardware": {
"type": "Hardware"
},
"platform": {
"type": "Platform"
}
},
"structures": {
"OS": {
"type": "object",
"properties": {
"type": {
"type": "string",
"description": "Operating system name",
"pattern": "Windows|Linux|MacOS|.+"
},
"name": {
"type": "string",
"description": "Operation system distribution",
"pattern": "redhat|centos|debian|ubuntu|cloudlinux|.+"
},
"edition": {
"type": "string",
"description": "Operation system edition",
"pattern": "datacenter|server|desktop|.*"
},
"version": {
"type": "number",
"description": "Operation system Version in format <major>.<minor>"
}
}
},
"CPU": {
"type": "object",
"properties": {
"number": {
"type": "integer",
"description": "Number of CPUcores"
},
"power": {
"type": "number",
"description": "CPU Power in MHz"
}
}
},
"Platform": {
"type": "object",
"properties": {
"arch": {
"type": "string",
"description": "System architecture",
"pattern": "x86|x86_64|ia64|arm|.+"
},
"os": {
"type": "OS",
"description": "System operating system"
}
}
},
"Hardware": {
"type": "object",
"properties": {
"bandwidth": {
"type": "integer",
"description": "Bandwidth in Mbps",
"unit": "mbps"
},
"cpu": {
"type": "CPU"
},
"diskspace": {
"type": "integer",
"description": "Disk space in Mbytes",
"unit": "mb"
},
"memory": {
"type": "integer",
"description": "Memory size in Mbytes",
"unit": "mb"
}
}
}
},
"relations": {
"application": {
"type": "http://aps-standard.org/types/core/application/1.0"
}
}
}
Derivatives of this type define more specific environments: