From b4297121c0499e0dedb70a20d46297e63cd8f3e4 Mon Sep 17 00:00:00 2001 From: ppaulis Date: Thu, 6 Oct 2016 13:29:55 +0200 Subject: [PATCH] working on setup --- build.xml | 6 +++++- continuous.yml | 5 +++++ scripts/migrate.sh | 10 ++++++++++ 3 files changed, 20 insertions(+), 1 deletion(-) create mode 100644 continuous.yml create mode 100755 scripts/migrate.sh diff --git a/build.xml b/build.xml index 5fe6b6f..99156aa 100644 --- a/build.xml +++ b/build.xml @@ -97,10 +97,14 @@ - + + + \ No newline at end of file diff --git a/continuous.yml b/continuous.yml new file mode 100644 index 0000000..9b5d112 --- /dev/null +++ b/continuous.yml @@ -0,0 +1,5 @@ +# continuous.yml +deployment: + hooks: + AfterInstall: + - command: scripts/migrate.sh \ No newline at end of file diff --git a/scripts/migrate.sh b/scripts/migrate.sh new file mode 100755 index 0000000..bd4a7b5 --- /dev/null +++ b/scripts/migrate.sh @@ -0,0 +1,10 @@ +#!/bin/bash +cd /var/www/continuousphp/current + +while [ ! -f /var/lib/continuousphp/credentials.ini ] +do + sleep 2 +done + +vendor/bin/phing -propertyfile /var/lib/continuousphp/credentials.ini init +chown -R www-data:www-data /var/www/continuousphp/current/* \ No newline at end of file