docs: unify path setting docs for all custom files

This commit is contained in:
Jose Diaz-Gonzalez
2024-08-11 03:52:48 -04:00
parent fe9a890243
commit bbd5c039b5
7 changed files with 59 additions and 22 deletions

View File

@@ -42,14 +42,19 @@ The `lambda` builder plugin delegates all build logic to [lambda-builder](https:
### Changing the `lambda.yml` location
When deploying a monorepo, it may be desirable to specify the specific path of the `lambda.yml` file to use for a given app. This can be done via the `builder-lambda:set` command. If a value is specified and that file does not exist in the app's build directory, then the build will fail.
The `lambda.yml` is expected to be found in a specific directory, depending on the deploy approach:
For deploys via the `git:from-image` and `git:load-image` commands, the `lambda.yml` is extracted from the configured `WORKDIR` property of the image. For all other deploys - git push, `git:from-archive`, `git:sync` - will have the `lambda.yml` extracted directly from the source code. Both cases will respect the configured `lambdayml-path` property value.
- The `WORKDIR` of the Docker image for deploys resulting from `git:from-image` and `git:load-image` commands.
- The root of the source code tree for all other deploys (git push, `git:from-archive`, `git:sync`).
Sometimes it may be desirable to set a different path for a given app, e.g. when deploying from a monorepo. This can be done via the `lambdayml-path` property:
```shell
dokku builder-lambda:set node-js-app lambdayml-path .dokku/lambda.yml
```
The value is the path to the desired file *relative* to the base search directory, and will never be treated as absolute paths in any context. If that file does not exist within the repository, the build will fail.
The default value may be set by passing an empty value for the option:
```shell