docs/v3/source/includes/resources/manifests/_object.md.erb
A manifest is a method for applying bulk configurations to apps and their underlying processes.
Manifests are in the YAML format. However, anchors and aliases are not supported.
### The manifest schema
```
Example Manifest
```
```yaml
---
version: 1
applications:
- name: app1
buildpacks:
- ruby_buildpack
- java_buildpack
env:
VAR1: value1
VAR2: value2
routes:
- route: route.example.com
- route: another-route.example.com
protocol: http2
services:
- my-service1
- my-service2
- name: my-service-with-arbitrary-params
binding_name: my-binding
parameters:
key1: value1
key2: value2
stack: cflinuxfs4
metadata:
annotations:
contact: "bob@example.com jane@example.com"
labels:
sensitive: true
processes:
- type: web
command: start-web.sh
disk_quota: 512M
health-check-http-endpoint: /healthcheck
health-check-type: http
health-check-invocation-timeout: 10
instances: 3
memory: 500M
log-rate-limit-per-second: 1KB
timeout: 10
- type: worker
command: start-worker.sh
disk_quota: 1G
health-check-type: process
instances: 2
memory: 256M
log-rate-limit-per-second: 1KB
timeout: 15
- name: app2
env:
VAR1: value1
processes:
- type: web
instances: 1
memory: 256M
log-rate-limit-per-second: 1KB
sidecars:
- name: authenticator
process_types: [ 'web', 'worker' ]
command: bundle exec run-authenticator
memory: 800M
- name: upcaser
process_types: [ 'worker' ]
command: ./tr-server
memory: 2G
```
#### Space-level configuration
Name | Type | Description
----- | ---- | -----------
**applications** | _array of [app configurations](#space-manifest-app-level-configuration)_ | Configurations for apps in the space
**version** | _integer_ | The manifest schema version; currently the only valid version is `1`, defaults to `1` if not provided
#### <a name="space-manifest-app-level-configuration"></a>App-level configuration
This configuration is specified per application and applies to all of the application's processes.
Name | Type | Description
----- | ---- | -----------
**name** | _string_ | Name of the app
**buildpacks** | _list of strings_ | a) An empty array, which will automatically select the appropriate default buildpack according to the coding language <br>b) An array of one or more URLs pointing to buildpacks <br>c) An array of one or more installed buildpack names <br>Replaces the legacy `buildpack` field
**docker** | _object_ | If present, the created app will have Docker lifecycle type; the value of this key is ignored by the API but may be used by clients to source the registry address of the image and credentials, if needed; the [generate manifest endpoint](#generate-a-manifest-for-an-app) will return the registry address of the image and username provided with this key
**env** | _object_ | A key-value mapping of environment variables to be used for the app when running
**no-route** | _boolean_ | When set to `true`, any routes specified with the `routes` attribute will be ignored and any existing routes will be removed
**processes** | _array of [process configurations](#space-manifest-process-level-configuration)_ | List of configurations for individual process types
**random-route** | _boolean_ | Creates a random route for the app if `true`; if `routes` is specified, if the app already has routes, or if `no-route` is specified, this field is ignored regardless of its value
**default-route** | _boolean_ | If true, a route for the app will be created using the app name as the hostname and the containing organization's default domain as the domain; if `routes` is specified, if the app already has routes, or if `no-route` is specified, this field is ignored regardless of its value
**routes** | _array of [route configurations](#space-manifest-route-level-configuration)_ | List declaring HTTP and TCP routes to be mapped to the app.
**services** | _array of [service configurations](#space-manifest-service-level-configuration)_ | A list of service-instances to bind to the app
**sidecars** | _array of [sidecar configurations](#space-manifest-sidecar-level-configuration)_ | A list of configurations for individual sidecars
**stack** | _string_ | The root filesystem to use with the buildpack, for example `cflinuxfs4`
**metadata.labels** | _[label object](#labels)_ | Labels applied to the app
**metadata.annotations** | _[annotation object](#annotations)_ | Annotations applied to the app
**buildpack** | _string_ | **DEPRECATED in favor of the `buildpacks` field above**
#### <a name="space-manifest-process-level-configuration"></a> Process-level configuration
This configuration is for the individual process. Each process is created if it does not already exist.
For backwards compatibility, the `web` process configuration may be placed at the top level of the application configuration, rather than listed under `processes`. However, if there is a process with `type: web` listed under `processes`, this configuration will override any at the top level.
Name | Type | Description
---- | ---- | -----------
**type** | _string_ | **(Required)** The identifier for the processes to be configured
**command** | _string_ | The command used to start the process; this overrides start commands from [Procfiles](#procfiles) and buildpacks
**disk_quota** | _string_ | The disk limit for all instances of the web process; <br>this attribute requires a unit of measurement: `B`, `K`, `KB`, `M`, `MB`, `G`, `GB`, `T`, or `TB` in upper case or lower case
**health-check-http-endpoint** | _string_ | Endpoint called to determine if the app is healthy
**health-check-invocation-timeout** | _integer_ | The timeout in seconds for individual health check requests for http and port health checks
**health-check-type** | _string_ | Type of health check to perform; `none` is deprecated and an alias to `process`
**instances** | _integer_ | The number of instances to run
**memory** | _string_ | The memory limit for all instances of the web process; <br>this attribute requires a unit of measurement: `B`, `K`, `KB`, `M`, `MB`, `G`, `GB`, `T`, or `TB` in upper case or lower case
**log-rate-limit-per-second** | _string_ | The log rate limit for all the instances of the process; <br>this attribute requires a unit of measurement: `B`, `K`, `KB`, `M`, `MB`, `G`, `GB`, `T`, or `TB` in upper case or lower case, or -1 or 0
**timeout** | _integer_ | Time in seconds at which the health-check will report failure
#### <a name="space-manifest-route-level-configuration"></a> Route-level configuration
This configuration is for _creating_ mappings between the app and a route. Each route is created if it does not already exist. The protocol
will be updated for any existing route mapping.
Name | Type | Description
---- | ---- | -----------
**route** | _string_ | **(Required)** The route URI. Example: `host.domain.com`
**protocol** | _string_ | Protocol to use for this route. Valid protocols are `http1`, `http2`, and `tcp`.
#### <a name="space-manifest-service-level-configuration"></a> Service-level configuration
This configuration is _creating_ new service bindings between the app and a service instance. The `services` field can
take either an array of service instance name strings or an array of the following service-level fields.
Name | Type | Description
---- | ---- | -----------
**name** | _string_ | **(Required)** The name of the service instance to be bound to
**binding_name** | _string_ | The name of the service binding to be created
**parameters** | _object_ | A map of arbitrary key/value pairs to send to the service broker during binding
#### <a name="space-manifest-sidecar-level-configuration"></a> Sidecar-level configuration
This configuration is for the individual sidecar. Each sidecar is created if it does not already exist.
Name | Type | Description
---- | ---- | -----------
**name** | _string_ | **(Required)** The identifier for the sidecars to be configured
**command** | _string_ | The command used to start the sidecar
**process_types** | _list of strings_ | List of processes to associate sidecar with
**memory** | _integer_ | Memory in MB that the sidecar will be allocated