We use Platform.sh in a mulitapp architecture. This means that we have several Drupal sites in one project, they are not multisites.
In order to achieve this there is a main repositories that uses git submodules to point to the actual Drupal repositories. Because of this there are a few steps that required for us that may not be required for more standard installs.
${PROJECT_ID} is the id of the project you can see it in the url when you are on the platform dashboard looking at the project.
${BRANCH} is the branch/environment you want to pull the database from usually main or master.
${APP} is the name of the app defined in .platform.app.yaml
${DATABASE} is the name of the database relationship in .platform.app.yaml
${CUSTOMER_ID} can be found in the default urls that platform provides each project.
I also assume mariadb in the string depends on the service you use for your database, but I only have mariadb on platform.
We do not need the typical mysql update command that is there by default.
We use Platform.sh in a mulitapp architecture. This means that we have several Drupal sites in one project, they are not multisites. In order to achieve this there is a main repositories that uses git submodules to point to the actual Drupal repositories. Because of this there are a few steps that required for us that may not be required for more standard installs.
In the tugboat repository settings we need an environment variable for the platform cli it must be named
PLATFORMSH_CLI_TOKEN
Instructions for generating the token: https://docs.platform.sh/development/cli/api-tokens.htmlIn the php service init command we install the platform.sh cli:
In the php service update command we grab the database.
${PROJECT_ID} is the id of the project you can see it in the url when you are on the platform dashboard looking at the project. ${BRANCH} is the branch/environment you want to pull the database from usually main or master. ${APP} is the name of the app defined in .platform.app.yaml ${DATABASE} is the name of the database relationship in .platform.app.yaml ${CUSTOMER_ID} can be found in the default urls that platform provides each project.
I also assume mariadb in the string depends on the service you use for your database, but I only have mariadb on platform.
We do not need the typical mysql update command that is there by default.