However, some services allow you to define multiple databases, cores, and/or permissions. In these cases, you can’t rely on default endpoints. Instead, you can explicitly define multiple endpoints when setting up your relationships.
App containers don’t have a default endpoint like services.
To connect your app to another app in your project,
you need to explicitly define the
For more information, see how to define relationships between your apps.
http endpoint as the endpoint to connect both apps.For more information, see how to define relationships between your apps.
Availability
New syntax (default and explicit endpoints) described below is supported by most, but not all, image types (Relationship 'SERVICE_NAME' of application 'app' ... targets a service without a valid default endpoint configuration.).
This syntax is currently being rolled out for all images.
If you encounter this error, use the “legacy” Upsun configuration noted at the bottom of this section.- Using default endpoints
- Using explicit endpoints
Use the following configuration:The
SERVICE_NAME is the name of the service as defined in its configuration.
It is used as the relationship name, and associated with a null value.
This instructs Upsun to use the service’s default endpoint to connect your app to the service.For example, if you define the following configuration:Upsun looks for a service named mariadb in your .upsun/config.yaml file,
and connects your app to it through the service’s default endpoint.For reference, the equivalent configuration using explicit endpoints would be the following:You can define any number of relationships in this way: