summaryrefslogtreecommitdiff
path: root/taler-build/switch_switch.sh
blob: e09b94368174d6ea2c19628d675891f2f1f383ed (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
#!/bin/bash

active=$(sudo -u test cat /home/test/active)
nonactive="test-blue"
echo "Active party: ${active}"

if test $active = "test-blue"; then
  nonactive="test-green"
fi

echo "Switching to ${nonactive}."
sudo -u test bash -c "cd /home/test; ./ln-${nonactive}.sh"
sudo -u $nonactive bash -c 'cd $HOME; . activate; taler-deployment-restart'