I have several services in a monorepo that use a shared library. I want to be able to install the shared library when running tests and deploying.
Here’s the layout
- .platform
- .platform/routes.yaml
- quote-api
- composer.json
- events
- composer.json
.platform/routes.yaml
"https://quote-api.{default}/":
type: upstream
upstream: "quote-api:http"
quote-api/composer.json
{
"require": {
"paqman/events": "*"
},
"repositories": [
{
"type": "path",
"url": "../events"
}
]
}
But when platform.sh is building each service, it says “Moving the application to the output directory” which I assume moves it to some sort of isolated area so now I get the error message:
Source path "../events" is not found for package paqman/events
Note: I do not want to use a package manager as I want to get the exact shared code with the commit (releasing a new package for a branch etc. would be difficult)