Documentation

The Servd YAML File

Often when updating a project, you may need to change certain aspects of it (e.g. PHP version, node build command, etc) so that you can test it in staging. However, if changes to your production environment are still being made by your team, then there's risk that those changes become impacted by the update work being done on staging.

To avoid these kind of situations, Servd looks out for a servd.yaml file in the root of your repository. If one exists, it overrides the corresponding settings defined in the Servd dashboard. This allows you to define your desired settings in the branch in which updates are being made in, and avoid any potential conflicts with any other changes being made to the project.

Note: overrides are currently only available for your project's Build settings.

Examples #

Here's an example Servd YAML file that outlines all the settings that support overrides:

build:
  php_version: 8.3
  craft_location: /
  composer_version: 2
  node_build_step:
    command: npm run build
    version: 22
    build_context_path: /
    keep_node_modules: false
    composer_before_node: false

Alternatively, if you're only interested in changing one or two things, you can just include a subset of the settings:

build:
  php_version: 8.3