forked from envoyproxy/envoy
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Adds Jenkinsfile and updates release-binary to create a SHA. (envoypr…
…oxy#71) * Adds Jenkinsfile and update release-binary * Update Jenkinsfile and gitignore * Fixes typo and use normal build Node * Uses default bazel config * Using batch mode * Update bazel memory settings * Do not use Jenkins bazel env * Set .bazelrc for postsubmit
- Loading branch information
1 parent
d29a195
commit fdac61b
Showing
4 changed files
with
80 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
# This is from Bazel's former travis setup, to avoid blowing up the RAM usage. | ||
startup --host_jvm_args=-Xmx8192m | ||
startup --host_jvm_args=-Xms8192m | ||
startup --batch | ||
|
||
# This is so we understand failures better | ||
build --verbose_failures | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,3 @@ | ||
/bazel-* | ||
.idea/* | ||
*.iml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
#!groovy | ||
|
||
@Library('testutils') | ||
|
||
import org.istio.testutils.Utilities | ||
import org.istio.testutils.GitUtilities | ||
import org.istio.testutils.Bazel | ||
|
||
// Utilities shared amongst modules | ||
def gitUtils = new GitUtilities() | ||
def utils = new Utilities() | ||
def bazel = new Bazel() | ||
|
||
node { | ||
gitUtils.initialize() | ||
// Proxy does build work correctly with Hazelcast. | ||
// Must use .bazelrc.jenkins | ||
bazel.setVars('', '') | ||
} | ||
|
||
mainFlow(utils) { | ||
if (utils.runStage('PRESUBMIT')) { | ||
def success = true | ||
utils.updatePullRequest('run') | ||
try { | ||
presubmit(gitUtils, bazel) | ||
} catch (Exception e) { | ||
success = false | ||
throw e | ||
} finally { | ||
utils.updatePullRequest('verify', success) | ||
} | ||
} | ||
if (utils.runStage('POSTSUBMIT')) { | ||
buildNode(gitUtils) { | ||
bazel.updateBazelRc() | ||
sh 'script/release-binary' | ||
} | ||
} | ||
} | ||
|
||
def presubmit(gitUtils, bazel) { | ||
buildNode(gitUtils) { | ||
stage('Code Check') { | ||
sh('script/check-style') | ||
} | ||
bazel.updateBazelRc() | ||
stage('Bazel Fetch') { | ||
bazel.fetch('-k //...') | ||
} | ||
stage('Bazel Build') { | ||
bazel.build('//...') | ||
} | ||
stage('Bazel Tests') { | ||
bazel.test('//...') | ||
} | ||
stage('Push Test Binary') { | ||
sh 'script/release-binary' | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters