taler-deployment

Deployment scripts and configuration files
Log | Files | Refs | README

bootstrap-docbuilder (904B)


      1 #!/bin/bash
      2 
      3 # Bootstrap the Taler setup for the user account that
      4 # is currently logged in.
      5 
      6 # Generates a setup for a single user,
      7 # including a postgresql DB.
      8 
      9 set -eu
     10 
     11 BRANCH=master
     12 REPOS="docs"
     13 
     14 cd $HOME
     15 
     16 for component in $REPOS; do
     17   if ! test -d $HOME/$component; then
     18     git clone git://git.taler.net/$component.git
     19   fi
     20 done
     21 
     22 for component in $REPOS; do
     23   echo "Checking out $component to $BRANCH"
     24   git -C $HOME/$component checkout $BRANCH
     25 done
     26 
     27 if [[ ! -d worker ]]; then
     28   buildbot-worker create-worker --umask=0o22 ~/worker localhost:9989 doc-worker doc-pass
     29 fi
     30 
     31 mkdir -p ~/.config/systemd/user/
     32 cp systemd-services/buildbot-worker-doc.service ~/.config/systemd/user/
     33 
     34 systemctl --user daemon-reload || echo "Please use 'machinectl shell docbuilder@.host' to log in to use this script"
     35 
     36 systemctl --user enable buildbot-worker-doc.service
     37 systemctl --user start buildbot-worker-doc.service