]> Untitled Git - godot-builder.git/blob - builder/entrypoint.sh
Squashed commit of the following:
[godot-builder.git] / builder / entrypoint.sh
1 #!/bin/bash
2
3
4 function intr() {
5     echo Halting
6     exit
7 }
8
9 trap intr SIGINT
10
11 echo Starting builder polling...
12
13 # polls a redis queue for jobs, starts the builder when it's got some
14 while true
15 do
16     SNAPSHOT_URI=$(redis-cli -h redis LPOP snapshots)
17     [[ -n "$SNAPSHOT_URI" ]] && ./godot-export.sh "$SNAPSHOT_URI"
18     sleep 1
19 done
20
21