-
Notifications
You must be signed in to change notification settings - Fork 1
/
540.poudriere
executable file
·62 lines (51 loc) · 1.34 KB
/
540.poudriere
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
#!/bin/sh -
#
# $FreeBSD$
#
if [ -r /etc/defaults/periodic.conf ]; then
. /etc/defaults/periodic.conf
source_periodic_confs
fi
rc=0
poudrierecmd=/usr/local/bin/poudriere
case "${daily_poudriere_update_ports_enable:-YES}" in
[Nn][Oo])
;;
*)
if [ -z "$daily_poudriere_update_ports_name" ]; then
daily_poudriere_update_ports_name=default
fi
portsup=`$poudrierecmd ports -u -p $daily_poudriere_update_ports_name`
if [ $? -gt 0 ]; then
echo "$portsup"
exit $?
fi
;;
esac
case "${daily_poudriere_check_bulk_enable:-NO}" in
[Nn][Oo])
;;
*)
if [ -z "${daily_poudriere_check_bulk_jails}" ]; then
daily_poudriere_check_bulk_jails=`$poudrierecmd jail -l | awk '!/JAILNAME/ {print $1}'`
fi
if [ -z "${daily_poudriere_check_bulk_pkglist}" ]; then
daily_poudriere_check_bulk_pkglist=/usr/local/etc/poudriere.d/ports-list
fi
for jail in ${daily_poudriere_check_bulk_jails}; do
checkjail=`$poudrierecmd bulk -n -j $jail -f $daily_poudriere_check_bulk_pkglist`
if [ $? -gt 1 ]; then
echo "$checkjail"
exit $?
fi
buildports=`echo "$checkjail" | awk -F'> ' '/Ports to build:/ {print $NF}'`
if [ -n "$buildports" ]; then
echo "Poudriere jail ${jail}:"
echo "$checkjail" | awk -F'> ' '/Deleting.* (new version|missing dependency)/ {print $NF}'
echo "$buildports"
echo
fi
done
;;
esac
exit $rc