]> git.pld-linux.org Git - projects/pld-builder.new.git/blame - admin/fresh-queue.sh
Merge branch 'master' of ssh://git.pld-linux.org/projects/pld-builder.new
[projects/pld-builder.new.git] / admin / fresh-queue.sh
CommitLineData
18f24d83
MM
1#!/bin/sh
2
6db97676
MM
3umask 077
4
e935685b
KK
5CONFIG=$HOME/.pldbuilderrc
6[ -f "$CONFIG" ] && . $CONFIG
7[ -n "$BUILDERPATH" ] || BUILDERPATH="$HOME/pld-builder.new/"
8export BUILDERPATH
9
10if [ -d "$BUILDERPATH" ]; then
11 cd "$BUILDERPATH"
eea1325b 12else
e935685b 13 echo "the $BUILDERPATH directory does not exist"
eea1325b 14 exit 1
15fi
16
17
e935685b
KK
18if [ -f "$BUILDERPATH/config/global" ]; then
19 . $BUILDERPATH/config/global
95693b17 20fi
21
18f24d83
MM
22if [ "$1" != "y" ] ; then
23 echo "this scripts kills current queue and installs new"
24 echo "run '$0 y' to run it"
25 exit 1
26fi
27
63319e0a 28mkdir -p spool/{builds,buildlogs,notify,ftp} www/srpms lock
4d9b6f71
MM
29echo 0 > www/max_req_no
30echo 0 > spool/last_req_no
18f24d83 31echo -n > spool/processed_ids
3fefb769 32echo -n > spool/got_lock
18f24d83 33echo '<queue/>' > spool/queue
b5a39692 34echo '<queue/>' > spool/req_queue
95693b17 35test ! -z "$binary_builders" && for bb in $binary_builders; do
36 echo '<queue/>' > spool/queue-$bb
37done
6db97676
MM
38
39chmod 755 www www/srpms
40chmod 644 www/max_req_no
This page took 0.304111 seconds and 4 git commands to generate.