App Spec

The application specification, or app spec, is a YAML manifest that declaratively states everything about your App Platform app, including each resource and all of your app’s environment variables and configuration variables.

You can download an app spec (using doctl apps spec get) as a backup of your app’s configuration at that point in time. You can upload an app spec to App Platform to trigger a deployment that either applies the updated configuration to an existing app (using doctl apps update) or creates a new app (using doctl apps create).

You can use doctl apps propose to model the changes proposed in the app spec and see how they would impact the defined resources and cost for running your app, and doctl apps spec validate to check that your app spec is valid.

App Spec Locations

If an app spec is present in the source repo at /.do/app.yaml, the configuration values inside are used. Additionally, app specs can be defined in /.do/deploy.template.yaml if your repo is meant to be cloned, then deployed on App Platform; to help users kick off the process, a “Deploy to DO” button can be placed in the README of the repo. For details, see Add “Deploy to DO” button.

For examples of /.do/app.yaml and /.do/deploy.template.yaml, see the repo for the sample Node.js app for App Platform.

Here is an example of how to specify an app spec using doctl:

doctl apps update --spec spec-example.yaml

The DigitalOcean API can also produce and consume app specs in the same way as doctl, via the Apps namespace.

To view, upload, or download app specs using the App Platform user interface, click the Settings tab for your app, then click the Edit link under the App Spec heading.

For details on how to format app specs and what values to use, see the App Spec Reference.

App Spec Articles

Upgrade or downgrade your app’s stack to take advantage of new features and security updates, or maintain your app’s compatibility.
You can configure functions to forward console and error logs from the function to a third-party logging service. Functions supports Papertrail, Datadog, and Logtail.
Build app components locally using the same build process as App Platform.