From 8199211e4dfdab956f1e69900d2c17748b7b57c4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jakub=20Soko=C5=82owski?= Date: Tue, 30 Oct 2018 10:38:52 +0100 Subject: [PATCH] add jenkins timeouts MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Jakub SokoĊ‚owski --- ci/Jenkinsfile.android | 7 +++++-- ci/Jenkinsfile.combined | 3 +++ ci/Jenkinsfile.ios | 7 +++++-- ci/Jenkinsfile.linux | 7 +++++-- ci/Jenkinsfile.macos | 7 +++++-- 5 files changed, 23 insertions(+), 8 deletions(-) diff --git a/ci/Jenkinsfile.android b/ci/Jenkinsfile.android index 9f4fa65370..916422f889 100644 --- a/ci/Jenkinsfile.android +++ b/ci/Jenkinsfile.android @@ -2,10 +2,13 @@ pipeline { agent { label 'linux' } options { + /* Prevent Jenkins jobs from running forever */ + timeout(time: 25, unit: 'MINUTES') + /* Limit builds retained */ buildDiscarder(logRotator( - numToKeepStr: '60', + numToKeepStr: '90', daysToKeepStr: '30', - artifactNumToKeepStr: '60', + artifactNumToKeepStr: '90', )) } diff --git a/ci/Jenkinsfile.combined b/ci/Jenkinsfile.combined index b9622cbb4f..81a69274b0 100644 --- a/ci/Jenkinsfile.combined +++ b/ci/Jenkinsfile.combined @@ -3,6 +3,9 @@ pipeline { options { disableConcurrentBuilds() + /* Prevent Jenkins jobs from running forever */ + timeout(time: 25, unit: 'MINUTES') + /* Limit builds retained */ buildDiscarder(logRotator( numToKeepStr: '10', daysToKeepStr: '30', diff --git a/ci/Jenkinsfile.ios b/ci/Jenkinsfile.ios index 631a6481ac..5e9c67da71 100644 --- a/ci/Jenkinsfile.ios +++ b/ci/Jenkinsfile.ios @@ -2,10 +2,13 @@ pipeline { agent { label 'fastlane' } options { + /* Prevent Jenkins jobs from running forever */ + timeout(time: 25, unit: 'MINUTES') + /* Limit builds retained */ buildDiscarder(logRotator( - numToKeepStr: '30', + numToKeepStr: '60', daysToKeepStr: '30', - artifactNumToKeepStr: '30', + artifactNumToKeepStr: '60', )) } diff --git a/ci/Jenkinsfile.linux b/ci/Jenkinsfile.linux index fa3efbb435..69547952ad 100644 --- a/ci/Jenkinsfile.linux +++ b/ci/Jenkinsfile.linux @@ -15,10 +15,13 @@ pipeline { } options { + /* Prevent Jenkins jobs from running forever */ + timeout(time: 25, unit: 'MINUTES') + /* Limit builds retained */ buildDiscarder(logRotator( - numToKeepStr: '30', + numToKeepStr: '60', daysToKeepStr: '30', - artifactNumToKeepStr: '30', + artifactNumToKeepStr: '60', )) } diff --git a/ci/Jenkinsfile.macos b/ci/Jenkinsfile.macos index d8fc4c9e5f..138db29aed 100644 --- a/ci/Jenkinsfile.macos +++ b/ci/Jenkinsfile.macos @@ -2,10 +2,13 @@ pipeline { agent { label 'macos' } options { + /* Prevent Jenkins jobs from running forever */ + timeout(time: 25, unit: 'MINUTES') + /* Limit builds retained */ buildDiscarder(logRotator( - numToKeepStr: '30', + numToKeepStr: '60', daysToKeepStr: '30', - artifactNumToKeepStr: '30', + artifactNumToKeepStr: '60', )) }