Skip to content

Commit

Permalink
Feature: allow custom services
Browse files Browse the repository at this point in the history
With this PR you can add services to your environemt, by adding them to
the services section in deploy.yml. Necessary templates have to be added
at project level in directory config/custom-services-templates.
  • Loading branch information
uwej711 committed Feb 23, 2023
1 parent dc45e7f commit 3c6101b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
2 changes: 2 additions & 0 deletions bin/command/install/bootstrap.sh
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ function Command::bootstrap() {
local defaultProjectYaml=$([ -f "./deploy.local.yml" ] && echo -n "./deploy.local.yml" || echo -n "./deploy.yml")
local projectYaml=${1:-${defaultProjectYaml}}
local projectDeployTemplatesDirectory="./config/deploy-templates/"
local customServicesTemplatesDirectory="./config/custom-services-templates/"

if [ -n "${SKIP_BOOTSTRAP_IF_DONE}" ] && [ -f "${DESTINATION_DIR}/project.yml" ]; then
if cmp -s "${DESTINATION_DIR}/project.yml" "${projectYaml}"; then
Expand All @@ -67,6 +68,7 @@ function Command::bootstrap() {
rm -rf "${tmpDeploymentDir}"
fi
mkdir "${tmpDeploymentDir}"
mkdir "${tmpDeploymentDir}/project-deploy-templates"

tmpDeploymentDir="$(cd "${tmpDeploymentDir}" >/dev/null 2>&1 && pwd)"

Expand Down
1 change: 1 addition & 0 deletions generator/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
$loaders = new ChainLoader([
new FilesystemLoader(APPLICATION_SOURCE_DIR . DS . 'templates'),
new FilesystemLoader($deploymentDir),
new FilesystemLoader($deploymentDir . DS . 'project-deploy-templates'),
]);
$twig = new Environment($loaders);
$nginxVarEncoder = new class() {
Expand Down

0 comments on commit 3c6101b

Please sign in to comment.