gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[GNUnet-SVN] [taler-deployment] branch master updated: fix paths


From: gnunet
Subject: [GNUnet-SVN] [taler-deployment] branch master updated: fix paths
Date: Tue, 16 Apr 2019 22:14:35 +0200

This is an automated email from the git hooks/post-receive script.

marcello pushed a commit to branch master
in repository deployment.

The following commit(s) were added to refs/heads/master by this push:
     new 60b0f6b  fix paths
60b0f6b is described below

commit 60b0f6bb93ee4ab9e88453b7b847bec988283caf
Author: Marcello Stanisci <address@hidden>
AuthorDate: Tue Apr 16 22:14:29 2019 +0200

    fix paths
---
 buildbot/master.cfg |  6 ++++--
 buildbot/switch.sh  | 25 ++++++++-----------------
 2 files changed, 12 insertions(+), 19 deletions(-)

diff --git a/buildbot/master.cfg b/buildbot/master.cfg
index 055401f..f2702b5 100644
--- a/buildbot/master.cfg
+++ b/buildbot/master.cfg
@@ -323,14 +323,16 @@ BUILD_FACTORY.addStep(ShellCommand(
     haltOnFailure=True,
     env={'DEPLOYMENT': "test"}))
 
+
+SWITCH_FACTORY.addStep(git_step(
+    "git://git.taler.net/deployment.git"))
 SWITCH_FACTORY = util.BuildFactory()
 SWITCH_FACTORY.addStep(ShellCommand(
     name="switch active party",
     description="Switch to the party which was inactive.",
     descriptionDone="Active party has been switched.",
     command=["./switch.sh"],
-    workdir="build/buildbot",
-    env={'BRANCH': util.Property("branch")}))
+    workdir="build/buildbot"))
 
 SELENIUM_FACTORY = util.BuildFactory()
 SELENIUM_FACTORY.addStep(ShellCommand(
diff --git a/buildbot/switch.sh b/buildbot/switch.sh
index 5b464ca..ae17325 100755
--- a/buildbot/switch.sh
+++ b/buildbot/switch.sh
@@ -1,22 +1,13 @@
 #!/bin/bash
 
-DEPLOYMENT="test"
+set -e
 
-if test "stable" = ${BRANCH}; then
-  DEPLOYMENT="demo"
-fi
+NONACTIVE_COLOR="$(cat /home/test/nonactive)"
 
-active=$(cat /home/${DEPLOYMENT}/active)
-nonactive="${DEPLOYMENT}-blue"
-echo "Active party: ${active}"
+##
+# PWD is the weak part here, as it makes this script
+# only useful if run under Buildbot..
+CMD="${PWD}/bin/taler-deployment-switch-${NONACTIVE_COLOR}"
 
-if test $active = "${DEPLOYMENT}-blue"; then
-  nonactive="${DEPLOYMENT}-green"
-fi
-
-cmd=$(printf "%s; %s" \
-  "cd /home/test" \
-  "./deployment/bin/taler-deployment-switch-${nonactive}")
-
-echo "Switching to ${nonactive}."
-sudo -u test bash -c "${cmd}"
+echo "Switching to ${NONACTIVE_COLOR}."
+bash -c "${CMD}"

-- 
To stop receiving notification emails like this one, please contact
address@hidden



reply via email to

[Prev in Thread] Current Thread [Next in Thread]