{"title":"Upsun configuration file","$schema":"http://json-schema.org/draft-07/schema#","type":"object","properties":{"applications":{"description":"For more information, see https://docs.upsun.com/anchors/app/reference/root-keys/","additionalProperties":{"type":"object","properties":{"type":{"type":"string","anyOf":[{"$ref":"https://meta.upsun.com/schema/runtime-versions"},{"pattern":"^(composable|docker):"}],"title":"The base runtime (language) and version to use for this application","description":"The base image to use with a specific app language.  \nFormat: runtime:version. \nMore information: \nhttps://docs.upsun.com/anchors/app/reference/type/"},"stack":{"$ref":"#/definitions/stack"},"source":{"type":"object","properties":{"root":{"type":["string","null"],"title":"The root of the application relative to the repository root","description":" \nDefaults to the root project directory.  \nUseful for multi-app setups: \nhttps://docs.upsun.com/anchors/app/multiple/"},"operations":{"type":"object","additionalProperties":{"type":"object","properties":{"command":{"type":["string","null"],"title":"Operations that can be applied to the source code","description":"More information: \nhttps://docs.upsun.com/anchors/app/source-operations/"}},"required":["command"],"additionalProperties":false,"patternProperties":{"^\\.":{}}},"title":"Operations that can be applied to the source code","default":{}}},"additionalProperties":false,"patternProperties":{"^\\.":{}},"title":"Information on the app’s source code and operations that can be run on it","description":"More information: \nhttps://docs.upsun.com/anchors/app/reference/source/operations/"},"resources":{"anyOf":[{"$ref":"#/definitions/deprecated/resources"},{"type":"null"}]},"relationships":{"$ref":"#/definitions/relationships"},"mounts":{"$ref":"#/definitions/mounts"},"web":{"type":"object","title":"How the web application is served","description":"More information: \nhttps://docs.upsun.com/anchors/app/reference/web/","properties":{"variables":{"type":["object","null"],"additionalProperties":{"type":"object","additionalProperties":{}},"title":"Variables provide environment-sensitive information to control how your application behaves","description":"Overrides the application's value for this container."},"timezone":{"type":["string","null"],"title":"The timezone of the application","description":"Overrides the application's value for this container."},"mounts":{"description":"Overrides the application's value for this container.","anyOf":[{"$ref":"#/definitions/mounts"},{"type":"null"}]},"relationships":{"description":"Overrides the application's value for this container.","anyOf":[{"$ref":"#/definitions/relationships"},{"type":"null"}]},"access":{"type":["object","null"],"additionalProperties":{"type":"string"},"title":"Access information, a mapping between access type and roles","description":"Overrides the application's value for this container."},"size":{"description":"Overrides the application's value for this container.","anyOf":[{"$ref":"#/definitions/deprecated/size"},{"type":"null"}]},"resources":{"description":"Overrides the application's value for this container.","anyOf":[{"$ref":"#/definitions/deprecated/resources"},{"type":"null"}]},"locations":{"type":"object","additionalProperties":{"type":"object","properties":{"root":{"type":["string","null"],"title":"The folder from which to serve static assets for this location relative to the application root","description":"The directory to serve static assets for this location relative to the app’s root directory. Must be an actual directory inside the root directory. \nMore information: \nhttps://docs.upsun.com/anchors/app/reference/source/root/","default":"public"},"expires":{"type":["integer","string"],"title":"Amount of time to cache static assets","description":"How long static assets are cached. The default means no caching. Setting it to a value enables the `Cache-Control` and `Expires` headers. Times can be suffixed with `ms` = milliseconds, `s` = seconds, `m` = minutes, `h` = hours, `d` = days, `w` = weeks, `M` = months/30d, or `y` = years/365d. If a `Cache-Control` appears on the `headers` configuration, `expires`, if set, will be ignored. Thus, make sure to set the `Cache-Control`’s `max-age` value when specifying a the header.","default":-1},"passthru":{"type":["string","boolean","null"],"title":"Whether to forward disallowed and missing resources from this location to the app","description":"Whether to forward disallowed and missing resources from this location to the application. On PHP, set to the PHP front controller script, as a URL fragment. Otherwise set to `true`/`false`.","default":false},"scripts":{"type":["boolean","null"],"title":"Whether to allow scripts to run","description":"Doesn't apply to paths specified in `passthru`. Meaningful only on PHP containers.","default":true},"index":{"type":["array","null"],"items":{"type":"string"},"title":"Files to look for to serve directories","description":"Files to consider when serving a request for a directory. When set, requires access to the files through the `allow` or `rules` keys."},"allow":{"type":"boolean","title":"Whether to allow serving files which don’t match a rule","default":true},"headers":{"type":"object","additionalProperties":{"type":"string"},"title":"A set of header fields set to the HTTP response","description":"Any additional headers to apply to static assets, mapping header names to values. Responses from the app aren’t affected. \nSee how to set custom headers on static content: \nhttps://docs.upsun.com/anchors/app/web/custom-headers/","default":{}},"rules":{"type":"object","additionalProperties":{"type":"object","properties":{"expires":{"type":["integer","string","null"],"title":"Amount of time to cache static assets","description":"How long static assets are cached. The default means no caching. Setting it to a value enables the `Cache-Control` and `Expires` headers. Times can be suffixed with `ms` = milliseconds, `s` = seconds, `m` = minutes, `h` = hours, `d` = days, `w` = weeks, `M` = months/30d, or `y` = years/365d. If a `Cache-Control` appears on the `headers` configuration, `expires`, if set, will be ignored. Thus, make sure to set the `Cache-Control`’s `max-age` value when specifying a the header.","default":-1},"passthru":{"type":["string","boolean","null"],"title":"Whether to forward disallowed and missing resources from this location to the app","description":"On PHP, set to the PHP front controller script, as a URL fragment. Otherwise set to `true`/`false`.","default":true},"scripts":{"type":["boolean","null"],"title":"Whether to allow scripts to run","description":"Doesn't apply to paths specified in `passthru`. Meaningful only on PHP containers.","default":true},"allow":{"type":["boolean","null"],"title":"Whether to allow serving files which don’t match a rule","default":true},"headers":{"type":"object","additionalProperties":{"type":"string"},"title":"A set of header fields set to the HTTP response","description":"Any additional headers to apply to static assets, mapping header names to values. Responses from the app aren’t affected. \nSee how to set custom headers on static content: \nhttps://docs.upsun.com/anchors/app/web/custom-headers/"},"dynamic_compression":{"type":["boolean","null"],"title":"Whether to compress dynamic responses","description":"Compresses dynamic responses (gzip/brotli) at the container web server. Disabled by default; only enable when the application framework mitigates BREACH (e.g. CSRF-token masking)."}},"additionalProperties":false,"patternProperties":{"^\\.":{}}},"title":"Specific overrides for specific locations","description":"Contains a rules dictionary. \nMore information: \nhttps://docs.upsun.com/anchors/app/reference/web/locations/rules/","default":{}},"request_buffering":{"type":"object","properties":{"enabled":{"type":"boolean","title":"Enable request buffering","default":true},"max_request_size":{"type":["string","integer","null"],"title":"The maximum size request that can be buffered","description":"A size in bytes, or with a K, M or G suffix. \nMore information: \nhttps://docs.upsun.com/anchors/app/reference/web/commands/request-buffering/","default":"250m"}},"additionalProperties":false,"patternProperties":{"^\\.":{}},"title":"Configuration for supporting request buffering.","description":"More information: \nhttps://docs.upsun.com/anchors/app/reference/web/commands/request-buffering/"},"dynamic_compression":{"type":["boolean","null"],"title":"Whether to compress dynamic responses","description":"Compresses dynamic responses (gzip/brotli) at the container web server. Disabled by default; only enable when the application framework mitigates BREACH (e.g. CSRF-token masking)."}},"additionalProperties":false,"patternProperties":{"^\\.":{}}},"title":"The specification of the web locations served by this application","description":"More information: \nhttps://docs.upsun.com/anchors/app/reference/web/","default":{}},"commands":{"type":"object","properties":{"pre_start":{"type":["string","null"],"title":"Command run just prior to `start`","description":"Which can be useful when you need to run per-instance actions."},"start":{"type":["string","null"],"title":"The command used to start the application","description":"It will be restarted if it terminates. Do not use on PHP unless using a custom persistent process like React PHP or FrankenPHP. \nSee note: \nhttps://docs.upsun.com/anchors/app/reference/web/commands/start/"},"post_start":{"type":["string","null"],"title":"A command executed after the application is started","description":"More information: \nhttps://docs.upsun.com/anchors/app/reference/web/commands/"}},"additionalProperties":false,"patternProperties":{"^\\.":{}},"title":"The command to launch your app","description":"More information: \nhttps://docs.upsun.com/anchors/app/reference/web/commands/"},"upstream":{"type":"object","properties":{"socket_family":{"type":"string","title":"Whether your app listens on a Unix or TCP socket","description":"If `tcp`, check the PORT environment variable on application startup. If `unix`, check SOCKET. \nMore Information: \nhttps://docs.upsun.com/anchors/app/reference/web/upstream/","default":"tcp"},"protocol":{"type":["string","null"],"title":"Protocol"}},"additionalProperties":false,"patternProperties":{"^\\.":{}},"title":"Configuration on how the web server communicates with the application","description":"More information: \nhttps://docs.upsun.com/anchors/app/reference/web/upstream/"},"document_root":{"type":"string","title":"The document root of this application, relative to its root","deprecationMessage":"Deprecated"},"passthru":{"type":"string","title":"The URL to use as a passthru if a file doesn't match the whitelist","deprecationMessage":"Deprecated"},"index_files":{"type":"array","items":{"type":"string"},"title":"Files to look for to serve directories","deprecationMessage":"Deprecated"},"whitelist":{"type":"array","items":{"type":"string"},"title":"Whitelisted entries","deprecationMessage":"Deprecated"},"blacklist":{"type":"array","items":{"type":"string"},"title":"Blacklisted entries","deprecationMessage":"Deprecated"},"expires":{"type":["integer","string"],"title":"Amount of time to cache static assets","deprecationMessage":"Deprecated"},"move_to_root":{"type":"boolean","title":"Whether to move the whole root of the app to the document root","default":false,"deprecationMessage":"Deprecated"},"authorizations":{"description":"Overrides the application's value for this container.","anyOf":[{"$ref":"#/definitions/authorizations"},{"type":"null"}]},"egress":{"description":"Overrides the application's value for this container.","anyOf":[{"$ref":"#/definitions/container_egress"},{"type":"null"}]},"container_profile":{"description":"Overrides the application's value for this container.","allOf":[{"$ref":"#/definitions/container_profile"}]},"additional_hosts":{"description":"Overrides the application's value for this container.","anyOf":[{"$ref":"#/definitions/additional_hosts"},{"type":"null"}]},"operations":{"description":"Overrides the application's value for this container.","anyOf":[{"$ref":"#/definitions/operations"},{"type":"null"}]}},"additionalProperties":false,"patternProperties":{"^\\.":{}},"default":{"locations":{}}},"workers":{"type":"object","additionalProperties":{"type":"object","properties":{"variables":{"type":["object","null"],"additionalProperties":{"type":"object","additionalProperties":{}},"title":"Variables to control the environment","description":"Overrides the application's value for this container."},"timezone":{"type":["string","null"],"title":"The timezone of the application","description":"Overrides the application's value for this container."},"mounts":{"type":["object","null"],"additionalProperties":{"type":"object","properties":{"source":{"type":"string","title":"The type of mount that will provide the data","description":"- By design, `storage` mounts can be shared between instances of the same app \n- `instance` (or `local`) mounts are local mounts \n- `tmp` (or `temporary`) mounts are local ephemeral mounts \n- `service` mounts can be useful if you want to explicitly define and use a Network Storage service","enum":["instance","local","service","storage","temporary","tmp"]},"source_path":{"type":"string","title":"The path to be mounted","description":"Path relative to the root directory of the volume that's being mounted from.  \nWARNING: Changing the name of your mount affects the source_path when it’s undefined. See how to ensure continuity and maintain access to your files \nhttps://docs.upsun.com/anchors/app/reference/mounts/change-name/"},"service":{"type":["string","null"],"title":"The name of the service that the volume will be mounted from","description":"Must be a service in `services.yaml` of type `network-storage`."}},"required":["source"],"additionalProperties":false,"patternProperties":{"^\\.":{}}},"title":"Filesystem mounts of this application","description":"Overrides the application's value for this container."},"relationships":{"description":"Overrides the application's value for this container.","anyOf":[{"$ref":"#/definitions/relationships"},{"type":"null"}]},"access":{"type":["object","null"],"additionalProperties":{"type":"string"},"title":"Access control for roles accessing app environments","description":"Overrides the application's value for this container."},"size":{"description":"Overrides the application's value for this container.","anyOf":[{"$ref":"#/definitions/deprecated/size"},{"type":"null"}]},"resources":{"description":"Overrides the application's value for this container.","anyOf":[{"$ref":"#/definitions/deprecated/resources"},{"type":"null"}]},"container_profile":{"description":"Overrides the application's value for this container.","allOf":[{"$ref":"#/definitions/container_profile"}]},"commands":{"type":"object","properties":{"pre_start":{"type":["string","null"],"title":"The command used to run before starting the application","description":"More information: \nhttps://docs.upsun.com/anchors/app/reference/workers/"},"start":{"type":"string","title":"The command used to start the application","description":"It will be restarted if it terminates. Do not use on PHP unless using a custom persistent process like React PHP. \nMore information: \nhttps://docs.upsun.com/anchors/app/reference/workers/"},"post_start":{"type":["string","null"],"title":"A command executed after the application is started","description":"More information: \nhttps://docs.upsun.com/anchors/app/reference/workers/"}},"required":["start"],"additionalProperties":false,"patternProperties":{"^\\.":{}},"title":"The commands to manage the worker","description":"More information: \nhttps://docs.upsun.com/anchors/app/reference/workers/"},"authorizations":{"description":"Overrides the application's value for this container.","anyOf":[{"$ref":"#/definitions/authorizations"},{"type":"null"}]},"egress":{"description":"Overrides the application's value for this container.","anyOf":[{"$ref":"#/definitions/container_egress"},{"type":"null"}]},"additional_hosts":{"description":"Overrides the application's value for this container.","anyOf":[{"$ref":"#/definitions/additional_hosts"},{"type":"null"}]},"operations":{"description":"Overrides the application's value for this container.","anyOf":[{"$ref":"#/definitions/operations"},{"type":"null"}]}},"required":["commands"],"additionalProperties":false,"patternProperties":{"^\\.":{}}},"title":"Alternate copies of the application to run as background processes","description":"More information: \nhttps://docs.upsun.com/anchors/app/reference/workers/","default":{}},"access":{"type":"object","additionalProperties":{"type":"string"},"title":"Access control for roles accessing app environments","description":"More information: \nhttps://docs.upsun.com/anchors/app/reference/access/","default":{"ssh":"contributor"}},"variables":{"type":"object","additionalProperties":{"type":"object","additionalProperties":{}},"title":"Variables to control the environment","description":"Variables provide environment-sensitive information to control how your application behaves. To set a Unix environment variable, specify a key of `env:`, and then each sub-item of that is a key/value pair that will be injected into the environment. \nMore information: \nhttps://docs.upsun.com/anchors/app/reference/variables/","default":{}},"build":{"type":"object","properties":{"flavor":{"type":["string","null"],"description":"The pre-set build tasks to use for this application"}},"additionalProperties":false,"patternProperties":{"^\\.":{}},"title":"The build configuration of the application","description":"It contains a build dictionary.  \nMore information: \nhttps://docs.upsun.com/anchors/app/reference/build/"},"dependencies":{"type":"object","additionalProperties":{"type":"object"},"title":"External global dependencies of this application","description":"What global dependencies to install before the build `hook` is run. They will be downloaded by the language's package manager.  \nMore information: \nhttps://docs.upsun.com/anchors/app/reference/dependencies/","default":{}},"hooks":{"type":"object","properties":{"build":{"type":["string","null"],"title":"Hook executed after the build process","description":"More information: \nhttps://docs.upsun.com/anchors/app/reference/hooks/"},"deploy":{"type":["string","null"],"title":"Hook executed after the deployment of new code","description":"More information: \nhttps://docs.upsun.com/anchors/app/reference/hooks/"},"post_deploy":{"type":["string","null"],"title":"Hook executed after an environment is fully deployed","description":"More information: \nhttps://docs.upsun.com/anchors/app/reference/hooks/"}},"additionalProperties":false,"patternProperties":{"^\\.":{}},"title":"What commands run at different stages in the `build`, `deploy` and `post_deploy` process","description":"More information: \nhttps://docs.upsun.com/anchors/app/reference/hooks/","default":{}},"crons":{"type":"object","additionalProperties":{"type":"object","properties":{"spec":{"type":"string","title":"The cron schedule specification","description":"The cron specification. To prevent competition for resources that might hurt performance, use `H` in definitions to indicate an unspecified but invariant time. For example, instead of using `0 * * * *` to indicate the cron job runs at the start of every hour, you can use `H * * * *` to indicate it runs every hour, but not necessarily at the start. This prevents multiple cron jobs from trying to start at the same time. \nMore information: \nhttps://en.wikipedia.org/wiki/Cron#Cron_expression"},"commands":{"type":"object","properties":{"start":{"type":"string","title":"The command used to start the cron job","description":"By default, the command is run in Dash (till you specify something else): \nhttps://en.wikipedia.org/wiki/Almquist_shell"},"stop":{"type":["string","null"],"title":"The command used to stop the cron job","description":"The command that’s issued to give the cron command a chance to shutdown gracefully, such as to finish an active item in a list of tasks. Issued when a cron task is interrupted by a user through the CLI or Console. If not specified, a `SIGTERM` signal is sent to the process."}},"required":["start"],"additionalProperties":false,"patternProperties":{"^\\.":{}},"title":"A definition of what commands to run when starting and stopping the cron job","description":"More information: \nhttps://docs.upsun.com/anchors/app/reference/crons/commands/"},"shutdown_timeout":{"type":["integer","null"],"title":"The timeout in seconds after which the cron job will be forcefully killed","description":"When a cron is canceled, this represents the number of seconds after which a `SIGKILL` signal is sent to the process to force terminate it. The default is `10` seconds.","default":10},"timeout":{"type":"integer","title":"The cron timeout","description":"The maximum amount of time a cron can run before it’s terminated. Defaults to the maximum allowed value of `86400` seconds (24 hours).","minimum":1,"maximum":86400},"cmd":{"type":"string","title":"The command to execute","deprecationMessage":"Deprecated, please use `commands.start` instead."}},"required":["spec"],"additionalProperties":false,"patternProperties":{"^\\.":{}}},"title":"Scheduled cron tasks executed by this application","description":"More information: \nhttps://docs.upsun.com/anchors/app/reference/crons/","default":{}},"runtime":{"type":"object","title":"Runtime-specific configuration","description":"Customizations to your PHP or Lisp runtime. \nContains a runtime dictionary: \nhttps://docs.upsun.com/anchors/app/reference/runtime/","properties":{"extensions":{"type":["array","null"],"title":"PHP extensions to enable","description":"More information: \nhttps://docs.upsun.com/anchors/app/reference/extensions/","default":[]},"disabled_extensions":{"type":["array","null"],"title":"PHP extensions to disable","description":"More information: \nhttps://docs.upsun.com/anchors/app/reference/extensions/","default":[]},"request_terminate_timeout":{"type":["integer","null"],"title":"PHP timeout to terminate requests","description":"The timeout in seconds for serving a single request after which the PHP-FPM worker process is killed."},"sizing_hints":{"type":["object","null"],"title":"A sizing hints definition","description":"The assumptions for setting the number of workers in your PHP-FPM runtime. \nMore information: \nhttps://docs.upsun.com/anchors/app/reference/runtime/sizing-hints/","properties":{"request_memory":{"type":["integer","null"],"title":"The average memory consumed per request in MB","description":"Minimum to 10","default":45,"minimum":10},"reserved_memory":{"type":["integer","null"],"title":"The amount of memory reserved in MB","description":"Minimum to 70","default":70,"minimum":70}},"additionalProperties":false,"patternProperties":{"^\\.":{}}},"xdebug":{"type":["object","null"],"title":"An Xdebug definition","description":"The setting to turn on Xdebug. \nMore information: \nhttps://docs.upsun.com/anchors/languages/php/xdebug/","properties":{"idekey":{"type":["string","null"],"title":"Your Xdebug key"}}},"quicklisp":{"type":["object","null"],"title":"Distributions for QuickLisp to use","description":"More information: \nhttps://docs.upsun.com/anchors/languages/lisp/","deprecationMessage":"Lisp image no longer exists, please see \nhttps://devcenter.upsun.com/posts/deploying-with-lisp/ \n for more information"}}},"container_profile":{"$ref":"#/definitions/container_profile"},"additional_hosts":{"$ref":"#/definitions/additional_hosts"},"timezone":{"type":["string","null"],"title":"The timezone of the application","description":"This primarily affects the timezone in which cron tasks will run. It will not affect the application itself. Defaults to UTC if not specified. \nSee also: \nhttps://docs.upsun.com/anchors/app/timezone/"},"preflight":{"type":"object","properties":{"enabled":{"type":"boolean","title":"Whether the preflight security blocks are enabled","description":"Must be a boolean"},"ignored_rules":{"type":"array","items":{"type":"string"},"title":"Specific rules to ignore during preflight security checks","default":[]}},"required":["enabled"],"additionalProperties":false,"patternProperties":{"^\\.":{}},"description":"Configuration for pre-flight checks","default":{"enabled":true,"ignored_rules":[]}},"operations":{"$ref":"#/definitions/operations"},"authorizations":{"$ref":"#/definitions/authorizations"},"egress":{"anyOf":[{"$ref":"#/definitions/egress"},{"type":"null"}]},"image":{"$ref":"#/definitions/image"}},"anyOf":[{"required":["type"]},{"required":["type","stack"]}],"additionalProperties":false,"patternProperties":{"^\\.":{}},"x-order":["type","stack","source","resources","relationships","mounts","web","workers","access","variables","build","dependencies","hooks","crons","runtime","container_profile","additional_hosts","timezone","preflight","operations"]},"patternProperties":{"^\\.":{}}},"routes":{"title":"The routes of the project","description":"Each route describes how an incoming URL is going to be processed by Upsun. \nMore information:  \nhttps://docs.upsun.com/anchors/routes/","type":["object","null"],"additionalProperties":{"oneOf":[{"type":"object","title":"Route identifier","description":"More information: \nhttps://docs.upsun.com/anchors/routes/identifiers/","properties":{"primary":{"anyOf":[{"$ref":"#/definitions/routes/primary"},{"type":"null"}]},"id":{"anyOf":[{"$ref":"#/definitions/routes/id"},{"type":"null"}]},"attributes":{"$ref":"#/definitions/routes/attributes"},"type":{"$ref":"#/definitions/routes/route_type"},"redirects":{"$ref":"#/definitions/routes/redirects"},"tls":{"$ref":"#/definitions/routes/tls"},"to":{"$ref":"#/definitions/routes/to"}},"required":["type","to"],"additionalProperties":false,"patternProperties":{"^\\.":{}}},{"type":"object","properties":{"primary":{"anyOf":[{"$ref":"#/definitions/routes/primary"},{"type":"null"}]},"id":{"anyOf":[{"$ref":"#/definitions/routes/id"},{"type":"null"}]},"attributes":{"$ref":"#/definitions/routes/attributes"},"type":{"$ref":"#/definitions/routes/route_type"},"redirects":{"$ref":"#/definitions/routes/redirects"},"tls":{"$ref":"#/definitions/routes/tls"},"cache":{"$ref":"#/definitions/routes/cache"},"ssi":{"$ref":"#/definitions/routes/ssi"},"upstream":{"$ref":"#/definitions/routes/upstream"}},"required":["type","upstream"],"additionalProperties":false,"patternProperties":{"^\\.":{}}}]},"patternProperties":{"^\\.":{}}},"services":{"title":"The services of the project","description":"Each service listed will be deployed to power your Upsun project.  \nMore information:  \nhttps://docs.upsun.com/anchors/services/ \nFull list of available services:  \nhttps://docs.upsun.com/anchors/services/available/","type":["object","null"],"additionalProperties":{"type":"object","properties":{"type":{"type":"string","allOf":[{"$ref":"https://meta.upsun.com/schema/service-versions"}],"title":"The service type","description":"One of the available services in the format `type:version`. \nMore information:  \nhttps://docs.upsun.com/anchors/services/available/"},"size":{"$ref":"#/definitions/deprecated/size"},"access":{"type":"object","title":"The configuration of the service","default":{},"deprecationMessage":"Deprecated"},"configuration":{"type":"object","title":"The configuration of the service","description":"Some services have additional specific configuration options that can be defined here, such as specific endpoints. \nSee the given service page for more details:  \nhttps://docs.upsun.com/anchors/services/available/.","default":{}},"relationships":{"$ref":"#/definitions/relationships"},"resources":{"anyOf":[{"$ref":"#/definitions/deprecated/resources"},{"type":"null"}]},"container_profile":{"$ref":"#/definitions/container_profile"}},"required":["type"],"additionalProperties":false,"patternProperties":{"^\\.":{}}},"patternProperties":{"^\\.":{}}},"tasks":{"title":"The tasks of the project","description":"On-demand, run-to-completion workloads.\nMore information:\nhttps://developer.upsun.com/docs/configure-apps/tasks","type":["object","null"],"additionalProperties":{"type":"object","properties":{"additional_hosts":{"type":"object","additionalProperties":{"type":"string"},"title":"Maps of hostnames to IP addresses","description":"More information: \nhttps://docs.upsun.com/anchors/app/reference/additional-hosts/"},"authorizations":{"$ref":"#/definitions/authorizations"},"base":{"type":"string","title":"A built-in task definition to use","description":"When set, no other property is allowed."},"container_profile":{"$ref":"#/definitions/container_profile"},"dependencies":{"type":"object","additionalProperties":{"type":"object"},"title":"External global dependencies of this application","description":"What global dependencies to install before the build `hook` is run. They will be downloaded by the language's package manager.  \nMore information: \nhttps://docs.upsun.com/anchors/app/reference/dependencies/","default":{}},"egress":{"anyOf":[{"$ref":"#/definitions/egress"},{"type":"null"}]},"hooks":{"type":"object","properties":{"build":{"type":["string","null"],"description":"Run during the environment build, producing a slug reused across runs."},"deploy":{"type":["string","null"],"description":"Run before the task's run command."}},"additionalProperties":false,"patternProperties":{"^\\.":{}}},"image":{"$ref":"#/definitions/image"},"mounts":{"$ref":"#/definitions/mounts"},"relationships":{"$ref":"#/definitions/relationships"},"resources":{"anyOf":[{"$ref":"#/definitions/deprecated/resources"},{"type":"null"}]},"run":{"type":"object","properties":{"command":{"type":"string","minLength":1,"description":"The command to execute. It runs to completion, not as a daemon."},"timeout":{"type":"integer","minimum":1,"maximum":86400,"description":"The maximum duration in seconds. Defaults to 3600."}},"required":["command"],"additionalProperties":false,"patternProperties":{"^\\.":{}}},"runtime":{"type":"object","title":"Runtime-specific configuration","description":"Customizations to your PHP or Lisp runtime. \nContains a runtime dictionary: \nhttps://docs.upsun.com/anchors/app/reference/runtime/","properties":{"extensions":{"type":["array","null"],"title":"PHP extensions to enable","description":"More information: \nhttps://docs.upsun.com/anchors/app/reference/extensions/","default":[]},"disabled_extensions":{"type":["array","null"],"title":"PHP extensions to disable","description":"More information: \nhttps://docs.upsun.com/anchors/app/reference/extensions/","default":[]},"request_terminate_timeout":{"type":["integer","null"],"title":"PHP timeout to terminate requests","description":"The timeout in seconds for serving a single request after which the PHP-FPM worker process is killed."},"sizing_hints":{"type":["object","null"],"title":"A sizing hints definition","description":"The assumptions for setting the number of workers in your PHP-FPM runtime. \nMore information: \nhttps://docs.upsun.com/anchors/app/reference/runtime/sizing-hints/","properties":{"request_memory":{"type":["integer","null"],"title":"The average memory consumed per request in MB","description":"Minimum to 10","default":45,"minimum":10},"reserved_memory":{"type":["integer","null"],"title":"The amount of memory reserved in MB","description":"Minimum to 70","default":70,"minimum":70}},"additionalProperties":false,"patternProperties":{"^\\.":{}}},"xdebug":{"type":["object","null"],"title":"An Xdebug definition","description":"The setting to turn on Xdebug. \nMore information: \nhttps://docs.upsun.com/anchors/languages/php/xdebug/","properties":{"idekey":{"type":["string","null"],"title":"Your Xdebug key"}}},"quicklisp":{"type":["object","null"],"title":"Distributions for QuickLisp to use","description":"More information: \nhttps://docs.upsun.com/anchors/languages/lisp/","deprecationMessage":"Lisp image no longer exists, please see \nhttps://devcenter.upsun.com/posts/deploying-with-lisp/ \n for more information"}}},"source":{"type":"object","properties":{"root":{"type":"string","description":"The subdirectory containing the task's code. Defaults to `/`."}},"additionalProperties":false,"patternProperties":{"^\\.":{}}},"stack":{"$ref":"#/definitions/stack"},"timezone":{"type":["string","null"],"title":"The timezone of the application","description":"This primarily affects the timezone in which cron tasks will run. It will not affect the application itself. Defaults to UTC if not specified. \nSee also: \nhttps://docs.upsun.com/anchors/app/timezone/"},"type":{"type":"string","anyOf":[{"$ref":"https://meta.upsun.com/schema/runtime-versions"},{"pattern":"^(composable|docker):"}],"title":"The runtime image and version to use for this task","description":"The base image to use with a specific app language.  \nFormat: runtime:version. \nMore information: \nhttps://docs.upsun.com/anchors/app/reference/type/"},"variables":{"type":"object","additionalProperties":{"type":"object","additionalProperties":{}},"title":"Variables to control the environment","description":"Variables provide environment-sensitive information to control how your application behaves. To set a Unix environment variable, specify a key of `env:`, and then each sub-item of that is a key/value pair that will be injected into the environment. \nMore information: \nhttps://docs.upsun.com/anchors/app/reference/variables/","default":{}}},"additionalProperties":false,"patternProperties":{"^\\.":{}}}}},"additionalProperties":false,"definitions":{"container_profile":{"type":["string","null"],"title":"The container profile for this application/service in production","description":"A profile defined in the project. Leave blank to allow it to be set dynamically. \nMore information: \nhttps://docs.upsun.com/anchors/resources/manage/configuration/profiles/adjust/","examples":["BALANCED","HIGH_CPU","HIGH_MEMORY","HIGHER_MEMORY"]},"routes":{"primary":{"type":"boolean","title":"Whether the route is the primary route for the project","description":"If true, this route is the primary route of the environment","default":true},"id":{"type":"string","title":"Route Identifier","description":"A unique identifier for the route. See route identifiers: \nhttps://docs.upsun.com/anchors/routes/identifiers/"},"attributes":{"type":"object","title":"Attributes of the route","additionalProperties":{"type":"string"},"description":"Arbitrary attributes attached to this resource: \nhttps://docs.upsun.com/anchors/routes/attributes/","default":{}},"route_type":{"type":["string","null"],"title":"Route type","description":"More information: \nhttps://docs.upsun.com/anchors/routes/configuration/","enum":["proxy","redirect","upstream"],"default":"upstream"},"redirects":{"type":"object","title":"The configuration of the redirects","description":"Defines redirects for partial routes. For definition and options, see the redirect rules: \nhttps://docs.upsun.com/anchors/routes/redirects/","properties":{"expires":{"type":["integer","string"],"title":"The duration the redirect is cached","description":"Examples of valid values include 3600s, 1d, 2w, 3m. \nTo disable caching for all your redirects, set expires to 0. You can also disable caching on a specific redirect:  \nhttps://docs.upsun.com/anchors/routes/redirects/caching/disable/","default":-1},"paths":{"type":"object","title":"The paths to redirect","description":"More information: \nhttps://docs.upsun.com/anchors/routes/redirects/partial/","additionalProperties":{"type":"object","properties":{"regexp":{"type":"boolean","title":"Whether the path is a regular expression","description":"Specifies whether the path key should be interpreted as a PCRE regular expression. \nMore information: \nhttps://docs.upsun.com/anchors/routes/redirects/partial/","default":false},"to":{"type":"string","title":"The URL to redirect to","description":"A relative URL - '/destination',  \nor absolute URL - 'https://example.com/'. \nMore information: \nhttps://docs.upsun.com/anchors/routes/redirects/partial/"},"prefix":{"type":["boolean","null"],"title":"Prefix of the redirect path","description":"Specifies whether both the path and all its children or just the path itself should be redirected.  \nMore information: \nhttps://docs.upsun.com/anchors/routes/redirects/affix/"},"append_suffix":{"type":["boolean","null"],"title":"Suffix of the redirect path","description":"Determines if the suffix is carried over with the redirect. More information. \nhttps://docs.upsun.com/anchors/routes/redirects/affix/"},"code":{"type":"integer","title":"The redirect HTTP status code to use","description":"Valid status codes are 301, 302, 307, and 308.  \nDefaults to 302 for Partial redirects: \nhttps://docs.upsun.com/anchors/routes/redirects/affix/ \nand 301 for Whole-route redirects: \nhttps://docs.upsun.com/anchors/routes/redirects/whole/ \nMore information:  \nhttps://docs.upsun.com/anchors/routes/redirects/partial/http-status-code/","default":302},"expires":{"type":["integer","string","null"],"title":"The amount of time, in seconds, to cache the redirects","description":"The duration the redirect is cached for.  \nMore information: \nhttps://docs.upsun.com/anchors/routes/redirects/caching/manage/"}},"required":["to"],"additionalProperties":false,"patternProperties":{"^\\.":{}}}}},"required":["paths"],"additionalProperties":false,"patternProperties":{"^\\.":{}}},"tls":{"type":"object","title":"TLS settings for the route","description":"The absolute URL or other route to which the given route should be redirected with an HTTP 301 status code. \nhttps://docs.upsun.com/anchors/routes/https/tls/","properties":{"strict_transport_security":{"type":"object","title":"Strict-Transport-Security options","description":"https://docs.upsun.com/anchors/routes/https/tls/","properties":{"enabled":{"type":["boolean","null"],"title":"Whether strict transport security is enabled or not","description":"If set to true, HSTS is enabled for 1 year.  \nIf set to false, other properties are ignored."},"include_subdomains":{"type":["boolean","null"],"title":"Whether the strict transport security policy should include all subdomains","description":"More information: \nhttps://docs.upsun.com/anchors/routes/https/tls/hsts/","default":false},"preload":{"type":["boolean","null"],"title":"Whether the strict transport security policy should be preloaded in browsers","description":"To add your website to the HSTS preload list: \nhttps://hstspreload.org/. \nThanks to this list, most browsers are informed that your site requires HSTS before an HSTS header response is even issued.\n","default":false}},"additionalProperties":false,"patternProperties":{"^\\.":{}}},"min_version":{"type":["string","null"],"enum":["TLSv1.0","TLSv1.1","TLSv1.2","TLSv1.3",null],"title":"The minimum TLS version to support.","description":"Note that TLS versions older than 1.2 are deprecated and are rejected by default.","default":null},"client_authentication":{"type":["string","null"],"enum":["request","require",null],"description":"The type of client authentication to request.","default":null},"client_certificate_authorities":{"type":"array","items":{"type":"string"},"title":"Certificate authorities to validate the client certificate against","description":"If not specified, a default set of trusted CAs will be used. \nMore Information: \nhttps://docs.upsun.com/anchors/routes/https/tls/mtls/","default":[]}},"additionalProperties":false,"patternProperties":{"^\\.":{}}},"to":{"type":"string","title":"Redirect destination","description":"The absolute URL or other route to which the given route should be redirected with an HTTP 301 status code. \nA relative URL - '/destination', or absolute URL - 'https://example.com/' \nMore information: \nhttps://docs.upsun.com/anchors/routes/redirects/partial/"},"cache":{"type":"object","properties":{"enabled":{"type":"boolean","title":"Whether the cache is enabled"},"default_ttl":{"type":"integer","title":"The TTL to apply when the response doesn't specify one. Only applies to static files","default":0},"cookies":{"type":"array","items":{"type":"string"},"title":"The cookies to take into account for the cache key","default":["*"]},"headers":{"type":"array","items":{"type":"string"},"title":"The headers to take into account for the cache key","default":["Accept","Accept-Language"]}},"required":["enabled"],"additionalProperties":false,"patternProperties":{"^\\.":{}},"title":"Cache configuration","default":{"default_ttl":0,"cookies":["*"],"enabled":true,"headers":["Accept","Accept-Language"]}},"ssi":{"type":"object","properties":{"enabled":{"type":"boolean","title":"Whether SSI include is enabled","description":"More information: \nhttps://docs.upsun.com/anchors/routes/server-side-includes/"}},"required":["enabled"],"additionalProperties":false,"patternProperties":{"^\\.":{}},"title":"Server-Side Include configuration.","description":"More information: \nhttps://docs.upsun.com/anchors/routes/configuration/","default":{"enabled":false}},"upstream":{"type":"string","title":"The upstream to use for this route","description":"The name of the app to be served (as defined in your app configuration) followed by :http. Example: app:http \nMore information: \nhttps://docs.upsun.com/anchors/routes/configuration/"}},"relationships":{"type":"object","additionalProperties":{"oneOf":[{"type":"string"},{"type":"null"},{"type":"object","properties":{"service":{"type":"string"},"endpoint":{"type":["string","null"]}}}]},"title":"The relationships of the application/service to other services","description":"Contains a dictionary of relationships: \nhttps://docs.upsun.com/anchors/app/reference/relationships/"},"mounts":{"type":"object","additionalProperties":{"type":"object","properties":{"source":{"type":"string","title":"The type of mount that will provide the data","description":"- By design, `storage` mounts can be shared between instances of the same app \n- `instance` (or `local`) mounts are local mounts \n- `tmp` (or `temporary`) mounts are local ephemeral mounts \n- `service` mounts can be useful if you want to explicitly define and use a Network Storage service","enum":["instance","local","service","storage","temporary","tmp"]},"source_path":{"type":"string","title":"The path to be mounted, relative to the root directory of the volume that's being mounted from","description":"WARNING: Changing the name of your mount affects the source_path when it’s undefined. See how to ensure continuity and maintain access to your files \nhttps://docs.upsun.com/anchors/app/reference/mounts/change-name/"},"service":{"type":["string","null"],"title":"The name of the service that the volume will be mounted from","description":" Must be a service in `services.yaml` of type `network-storage`. \nMore information: \nhttps://docs.upsun.com/anchors/app/reference/mounts/"}},"required":["source"],"additionalProperties":false,"patternProperties":{"^\\.":{}}},"title":"Filesystem mounts of this application","description":"Directories that are writable even after the app is built. Allocated disk for mounts is defined with a separate resource configuration call using `upsun resources:set`. \nContains a dictionary of mounts: \nhttps://docs.upsun.com/anchors/app/reference/mounts/"},"deprecated":{"size":{"type":"string","title":"The container size for this application in production","description":"Leave blank to allow it to be set dynamically.","deprecationMessage":"Deprecated"},"resources":{"type":"object","properties":{"base_memory":{"type":"integer","title":"The base memory for the container","default":64,"deprecationMessage":"Deprecated"},"memory_ratio":{"type":"integer","title":"The amount of memory to allocate per units of CPU","default":128,"deprecationMessage":"Deprecated"}},"additionalProperties":false,"patternProperties":{"^\\.":{}},"title":"Resources","deprecationMessage":"Deprecated"}},"authorizations":{"type":"array","title":"Workload authorizations","description":"Grants the container short-lived, narrowly-scoped access to the Upsun API at runtime.\nMore information:\nhttps://developer.upsun.com/docs/configure-apps/image-properties/authorizations","items":{"type":"object","properties":{"type":{"type":"string","enum":["env","task"],"description":"The type of resource to access: `task` (a task defined in the project) or `env` (the environment API)."},"action":{"type":"string","enum":["operate","view"],"description":"`operate` allows triggering and managing a task; `view` grants read-only access to the environment API."},"resource":{"type":"string","description":"The name of the task. Required when `type` is `task`."}},"required":["type","action"],"additionalProperties":false,"patternProperties":{"^\\.":{}}}},"egress":{"type":"object","title":"Egress proxy allowlists","description":"Routes outbound traffic through the egress proxy, allowing only the listed domains, per phase (`build` or `runtime`).","properties":{"build":{"anyOf":[{"$ref":"#/definitions/egress_phase"},{"type":"null"}]},"runtime":{"anyOf":[{"$ref":"#/definitions/egress_phase"},{"type":"null"}]}},"additionalProperties":false,"patternProperties":{"^\\.":{}}},"image":{"type":"object","title":"OCI image configuration","description":"For a `docker:` type: either `name` (an image reference) or `buildfile`.","properties":{"name":{"type":"string"},"buildfile":{"type":["string","null"]}},"additionalProperties":false,"patternProperties":{"^\\.":{}}},"stack":{"type":["object","array","null"],"title":"Composable image definition","description":"The runtimes and packages that make up the composable image. Each is a name, a mapping, or a list of them. A list is only accepted when empty.","properties":{"runtimes":{"anyOf":[{"type":"string"},{"type":"object","minProperties":1,"maxProperties":1},{"type":"array","items":{"anyOf":[{"type":"string"},{"type":"object","minProperties":1,"maxProperties":1}]}}]},"packages":{"anyOf":[{"type":"string"},{"type":"object","required":["package"]},{"type":"array","items":{"anyOf":[{"type":"string"},{"type":"object","required":["package"]}]}}]}},"additionalProperties":false,"maxItems":0},"additional_hosts":{"type":"object","additionalProperties":{"type":"string"},"title":"Maps of hostnames to IP addresses","description":"More information: \nhttps://docs.upsun.com/anchors/app/reference/additional-hosts/"},"operations":{"type":"object","additionalProperties":{"type":"object","properties":{"commands":{"type":"object","properties":{"start":{"type":"string","title":"The command used to start the application","description":"It will be restarted if it terminates. Do not use on PHP unless using a custom persistent process like React PHP."},"stop":{"type":["string","null"],"description":"The command used to stop the operation."}},"required":["start"]},"role":{"type":"string","title":"which users can trigger it according to their user role","description":"More information: \nhttps://docs.upsun.com/anchors/app/runtime-operations/define/","enum":["viewer","contributor","admin"]},"timeout":{"type":["integer","null"],"minimum":1,"maximum":86400,"description":"The maximum duration in seconds."}},"required":["commands"],"additionalProperties":false,"patternProperties":{"^\\.":{}}},"title":"Runtime operations that can be executed in the application container","description":"More information: \nhttps://docs.upsun.com/anchors/app/runtime-operations/"},"egress_phase":{"type":"object","properties":{"allowed_domains":{"type":"array","description":"The domains that outbound traffic may reach.","items":{"type":"object","properties":{"host":{"type":"string","minLength":1},"port":{"type":["integer","null"],"minimum":1,"maximum":65535}},"required":["host"],"additionalProperties":false,"patternProperties":{"^\\.":{}}}}},"additionalProperties":false,"patternProperties":{"^\\.":{}}},"container_egress":{"type":"object","title":"Egress proxy allowlists","description":"Routes outbound traffic through the egress proxy at runtime, allowing only the listed domains. Build-phase egress is set on the application.","properties":{"runtime":{"anyOf":[{"$ref":"#/definitions/egress_phase"},{"type":"null"}]}},"additionalProperties":false,"patternProperties":{"^\\.":{}}}},"patternProperties":{"^\\.":{}}}