Skip to content

Commit 61579e7

Browse files
committed
Add MAX_EXECUTION_TIME_{EXTRACT,INSTALL,PACKAGE,DEINSTALL} overrides
1 parent 87d5f46 commit 61579e7

File tree

1 file changed

+9
-4
lines changed

1 file changed

+9
-4
lines changed

src/share/poudriere/common.sh

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3057,7 +3057,7 @@ _real_build_port() {
30573057
JUSER=root
30583058
;;
30593059
extract)
3060-
max_execution_time=3600
3060+
max_execution_time=${MAX_EXECUTION_TIME_EXTRACT}
30613061
if [ "${JUSER}" != "root" ]; then
30623062
chown -R ${JUSER} ${mnt}/wrkdirs
30633063
fi
@@ -3081,12 +3081,12 @@ _real_build_port() {
30813081
checksum|*-depends) JUSER=root ;;
30823082
stage) [ -n "${PORTTESTING}" ] && markfs prestage ${mnt} ;;
30833083
install)
3084-
max_execution_time=3600
3084+
max_execution_time=${MAX_EXECUTION_TIME_INSTALL}
30853085
JUSER=root
30863086
[ -n "${PORTTESTING}" ] && markfs preinst ${mnt}
30873087
;;
30883088
package)
3089-
max_execution_time=7200
3089+
max_execution_time=${MAX_EXECUTION_TIME_PACKAGE}
30903090
if [ -n "${PORTTESTING}" ]; then
30913091
check_fs_violation ${mnt} prestage \
30923092
"${originspec}" \
@@ -3100,7 +3100,7 @@ _real_build_port() {
31003100
fi
31013101
;;
31023102
deinstall)
3103-
max_execution_time=3600
3103+
max_execution_time=${MAX_EXECUTION_TIME_DEINSTALL}
31043104
JUSER=root
31053105
# Skip for all linux ports, they are not safe
31063106
if [ "${PKGNAME%%*linux*}" != "" ]; then
@@ -7419,6 +7419,11 @@ DRY_RUN=0
74197419
# Be sure to update poudriere.conf to document the default when changing these
74207420
: ${RESOLV_CONF="/etc/resolv.conf"}
74217421
: ${MAX_EXECUTION_TIME:=86400} # 24 hours for 1 command (phase)
7422+
# Some phases have different timeouts.
7423+
: ${MAX_EXECUTION_TIME_EXTRACT:=3600}
7424+
: ${MAX_EXECUTION_TIME_INSTALL:=3600}
7425+
: ${MAX_EXECUTION_TIME_PACKAGE:=7200}
7426+
: ${MAX_EXECUTION_TIME_DEINSTALL:=3600}
74227427
: ${NOHANG_TIME:=7200} # 120 minutes with no log update
74237428
: ${QEMU_MAX_EXECUTION_TIME:=345600} # 4 days for 1 command (phase)
74247429
: ${QEMU_NOHANG_TIME:=21600} # 6 hours with no log update

0 commit comments

Comments
 (0)