-
Notifications
You must be signed in to change notification settings - Fork 1
/
build.sh
24 lines (17 loc) · 1.06 KB
/
build.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#!/bin/bash
interpolate() {
perl -p -e 's/\$\{([^}]+)\}/defined $ENV{$1} ? $ENV{$1} : $&/eg; s/\$\{([^}]+)\}//eg' $1 > $2
}
$(find -L $BUILDPATH -type f -executable -name python) setup.py install --no-compile
interpolate svc/platoon.yaml platoon.yaml.install
install -D -m 0644 platoon.yaml.install $BUILDPATH$SVCPATH/platoon/platoon.yaml
interpolate svc/platoon.monit platoon.monit.install
install -D -m 0644 platoon.monit.install $BUILDPATH$SVCPATH/platoon/platoon.monit
interpolate svc/platoon-ctl.sh platoon-ctl.sh.install
install -D -m 0755 platoon-ctl.sh.install $BUILDPATH$SVCPATH/platoon/platoon-ctl
interpolate svc/platoonapi.yaml platoonapi.yaml.install
install -D -m 0644 platoonapi.yaml.install $BUILDPATH$SVCPATH/platoon/platoonapi.yaml
interpolate svc/logrotate-platoonapi.conf logrotate-platoonapi.conf.install
install -D -m 0644 logrotate-platoonapi.conf.install $BUILDPATH/etc/logrotate.d/siq-platoonapi
interpolate svc/logrotate-platoon.conf logrotate-platoon.conf.install
install -D -m 0644 logrotate-platoon.conf.install $BUILDPATH/etc/logrotate.d/siq-platoon