Merge pull request #12870 from electron/remove-macci-refs
Remove references to no longer used https://mac-ci.electronjs.org
This commit is contained in:
commit
1cc5492784
5 changed files with 2 additions and 164 deletions
48
Jenkinsfile
vendored
48
Jenkinsfile
vendored
|
@ -1,48 +0,0 @@
|
||||||
pipeline {
|
|
||||||
agent none
|
|
||||||
stages {
|
|
||||||
stage('Build') {
|
|
||||||
parallel {
|
|
||||||
stage('electron-osx-x64') {
|
|
||||||
agent {
|
|
||||||
label 'osx'
|
|
||||||
}
|
|
||||||
steps {
|
|
||||||
timeout(60) {
|
|
||||||
sh 'script/bootstrap.py --target_arch=x64 --dev'
|
|
||||||
sh 'npm run lint'
|
|
||||||
sh 'script/build.py -c D'
|
|
||||||
sh 'script/test.py --ci --rebuild_native_modules'
|
|
||||||
}
|
|
||||||
}
|
|
||||||
post {
|
|
||||||
always {
|
|
||||||
cleanWs()
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
stage('electron-mas-x64') {
|
|
||||||
agent {
|
|
||||||
label 'osx'
|
|
||||||
}
|
|
||||||
environment {
|
|
||||||
MAS_BUILD = '1'
|
|
||||||
}
|
|
||||||
steps {
|
|
||||||
timeout(60) {
|
|
||||||
sh 'script/bootstrap.py --target_arch=x64 --dev'
|
|
||||||
sh 'npm run lint'
|
|
||||||
sh 'script/build.py -c D'
|
|
||||||
sh 'script/test.py --ci --rebuild_native_modules'
|
|
||||||
}
|
|
||||||
}
|
|
||||||
post {
|
|
||||||
always {
|
|
||||||
cleanWs()
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
|
@ -1,36 +0,0 @@
|
||||||
pipeline {
|
|
||||||
agent {
|
|
||||||
docker {
|
|
||||||
image 'electronbuilds/arm64v8:0.0.2'
|
|
||||||
args '--privileged'
|
|
||||||
}
|
|
||||||
}
|
|
||||||
environment {
|
|
||||||
TARGET_ARCH='arm64'
|
|
||||||
DISPLAY=':99.0'
|
|
||||||
MOCHA_TIMEOUT='60000'
|
|
||||||
}
|
|
||||||
stages {
|
|
||||||
stage('Bootstrap') {
|
|
||||||
steps {
|
|
||||||
sh 'script/bootstrap.py -v --dev --target_arch=$TARGET_ARCH'
|
|
||||||
}
|
|
||||||
}
|
|
||||||
stage('Build') {
|
|
||||||
steps {
|
|
||||||
sh 'script/build.py -c D --ninja-path /usr/local/ninja/ninja'
|
|
||||||
}
|
|
||||||
}
|
|
||||||
stage('Test') {
|
|
||||||
steps {
|
|
||||||
sh '/etc/init.d/xvfb start'
|
|
||||||
sh 'script/test.py --ci'
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
post {
|
|
||||||
always {
|
|
||||||
cleanWs()
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
|
@ -3,7 +3,6 @@
|
||||||
|
|
||||||
[![CircleCI Build Status](https://circleci.com/gh/electron/electron/tree/master.svg?style=shield)](https://circleci.com/gh/electron/electron/tree/master)
|
[![CircleCI Build Status](https://circleci.com/gh/electron/electron/tree/master.svg?style=shield)](https://circleci.com/gh/electron/electron/tree/master)
|
||||||
[![AppVeyor Build Status](https://windows-ci.electronjs.org/api/projects/status/nilyf07hcef14dvj/branch/master?svg=true)](https://windows-ci.electronjs.org/project/AppVeyor/electron/branch/master)
|
[![AppVeyor Build Status](https://windows-ci.electronjs.org/api/projects/status/nilyf07hcef14dvj/branch/master?svg=true)](https://windows-ci.electronjs.org/project/AppVeyor/electron/branch/master)
|
||||||
[![Jenkins Build Status](https://mac-ci.electronjs.org/buildStatus/icon?job=Electron%20org/electron/master)](https://mac-ci.electronjs.org/blue/organizations/jenkins/Electron%20org%2Felectron/activity?branch=master)
|
|
||||||
[![devDependency Status](https://david-dm.org/electron/electron/dev-status.svg)](https://david-dm.org/electron/electron?type=dev)
|
[![devDependency Status](https://david-dm.org/electron/electron/dev-status.svg)](https://david-dm.org/electron/electron?type=dev)
|
||||||
[![Join the Electron Community on Slack](https://atom-slack.herokuapp.com/badge.svg)](https://atom-slack.herokuapp.com/)
|
[![Join the Electron Community on Slack](https://atom-slack.herokuapp.com/badge.svg)](https://atom-slack.herokuapp.com/)
|
||||||
|
|
||||||
|
|
|
@ -35,8 +35,6 @@ Create a token from https://windows-ci.electronjs.org/api-token
|
||||||
If you don't have an account, ask a team member to add you.
|
If you don't have an account, ask a team member to add you.
|
||||||
* `CIRCLE_TOKEN`:
|
* `CIRCLE_TOKEN`:
|
||||||
Create a token from "Personal API Tokens" at https://circleci.com/account/api
|
Create a token from "Personal API Tokens" at https://circleci.com/account/api
|
||||||
* `JENKINS_AUTH_TOKEN` and `JENKINS_BUILD_TOKEN`:
|
|
||||||
Are provided by a Jenkins admin
|
|
||||||
|
|
||||||
## Run the prepare-release script
|
## Run the prepare-release script
|
||||||
The prepare release script will do the following:
|
The prepare release script will do the following:
|
||||||
|
@ -86,9 +84,7 @@ $ ./script/bump-version.py --bump minor --dry-run
|
||||||
The `prepare-release` script will trigger the builds via API calls.
|
The `prepare-release` script will trigger the builds via API calls.
|
||||||
To monitor the build progress, see the following pages:
|
To monitor the build progress, see the following pages:
|
||||||
|
|
||||||
- [mac-ci.electronjs.org/blue/organizations/jenkins/electron-mas-x64-release/activity](https://mac-ci.electronjs.org/blue/organizations/jenkins/electron-mas-x64-release/activity) for Mac App Store
|
- [circleci.com/gh/electron/electron](https://circleci.com/gh/electron) for OS X and Linux
|
||||||
- [mac-ci.electronjs.org/blue/organizations/jenkins/electron-osx-x64-release/activity](https://mac-ci.electronjs.org/blue/organizations/jenkins/electron-osx-x64-release/activity) for OS X
|
|
||||||
- [circleci.com/gh/electron/electron](https://circleci.com/gh/electron) for Linux
|
|
||||||
- [windows-ci.electronjs.org/project/AppVeyor/electron](https://windows-ci.electronjs.org/project/AppVeyor/electron) for Windows
|
- [windows-ci.electronjs.org/project/AppVeyor/electron](https://windows-ci.electronjs.org/project/AppVeyor/electron) for Windows
|
||||||
|
|
||||||
## Compile release notes
|
## Compile release notes
|
||||||
|
|
|
@ -1,7 +1,6 @@
|
||||||
const assert = require('assert')
|
const assert = require('assert')
|
||||||
const request = require('request')
|
const request = require('request')
|
||||||
const buildAppVeyorURL = 'https://windows-ci.electronjs.org/api/builds'
|
const buildAppVeyorURL = 'https://windows-ci.electronjs.org/api/builds'
|
||||||
const jenkinsServer = 'https://mac-ci.electronjs.org'
|
|
||||||
|
|
||||||
const circleCIJobs = [
|
const circleCIJobs = [
|
||||||
'electron-linux-arm',
|
'electron-linux-arm',
|
||||||
|
@ -11,11 +10,6 @@ const circleCIJobs = [
|
||||||
'electron-linux-x64'
|
'electron-linux-x64'
|
||||||
]
|
]
|
||||||
|
|
||||||
const jenkinsJobs = [
|
|
||||||
'electron-mas-x64-release',
|
|
||||||
'electron-osx-x64-release'
|
|
||||||
]
|
|
||||||
|
|
||||||
async function makeRequest (requestOptions, parseResponse) {
|
async function makeRequest (requestOptions, parseResponse) {
|
||||||
return new Promise((resolve, reject) => {
|
return new Promise((resolve, reject) => {
|
||||||
request(requestOptions, (err, res, body) => {
|
request(requestOptions, (err, res, body) => {
|
||||||
|
@ -111,68 +105,6 @@ function buildCircleCI (targetBranch, ghRelease, job) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
async function buildJenkins (targetBranch, ghRelease, job) {
|
|
||||||
assert(process.env.JENKINS_AUTH_TOKEN, 'JENKINS_AUTH_TOKEN not found in environment')
|
|
||||||
assert(process.env.JENKINS_BUILD_TOKEN, 'JENKINS_BUILD_TOKEN not found in environment')
|
|
||||||
let jenkinsCrumb = await getJenkinsCrumb()
|
|
||||||
|
|
||||||
if (job) {
|
|
||||||
assert(jenkinsJobs.includes(job), `Unknown CI job name: ${job}.`)
|
|
||||||
callJenkinsBuild(job, jenkinsCrumb, targetBranch, ghRelease)
|
|
||||||
} else {
|
|
||||||
jenkinsJobs.forEach((job) => {
|
|
||||||
callJenkinsBuild(job, jenkinsCrumb, targetBranch, ghRelease)
|
|
||||||
})
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
async function callJenkins (path, requestParameters, requestHeaders) {
|
|
||||||
let requestOptions = {
|
|
||||||
url: `${jenkinsServer}/${path}`,
|
|
||||||
auth: {
|
|
||||||
user: 'build',
|
|
||||||
pass: process.env.JENKINS_AUTH_TOKEN
|
|
||||||
},
|
|
||||||
qs: requestParameters
|
|
||||||
}
|
|
||||||
if (requestHeaders) {
|
|
||||||
requestOptions.headers = requestHeaders
|
|
||||||
}
|
|
||||||
let jenkinsResponse = await makeRequest(requestOptions).catch(err => {
|
|
||||||
console.log(`Error calling Jenkins:`, err)
|
|
||||||
})
|
|
||||||
return jenkinsResponse
|
|
||||||
}
|
|
||||||
|
|
||||||
async function callJenkinsBuild (job, jenkinsCrumb, targetBranch, ghRelease) {
|
|
||||||
console.log(`Triggering Jenkins to run build job: ${job} on branch: ${targetBranch} with release flag.`)
|
|
||||||
let jenkinsParams = {
|
|
||||||
token: process.env.JENKINS_BUILD_TOKEN,
|
|
||||||
BRANCH: targetBranch
|
|
||||||
}
|
|
||||||
if (!ghRelease) {
|
|
||||||
jenkinsParams.RUN_RELEASE_BUILD = 1
|
|
||||||
}
|
|
||||||
await callJenkins(`job/${job}/buildWithParameters`, jenkinsParams, jenkinsCrumb)
|
|
||||||
.catch(err => {
|
|
||||||
console.log(`Error calling Jenkins build`, err)
|
|
||||||
})
|
|
||||||
let buildUrl = `${jenkinsServer}/job/${job}/lastBuild/`
|
|
||||||
console.log(`Jenkins build request successful. Check build status at ${buildUrl}.`)
|
|
||||||
}
|
|
||||||
|
|
||||||
async function getJenkinsCrumb () {
|
|
||||||
let crumbResponse = await callJenkins('crumbIssuer/api/xml', {
|
|
||||||
xpath: 'concat(//crumbRequestField,":",//crumb)'
|
|
||||||
}).catch(err => {
|
|
||||||
console.log(`Error getting jenkins crumb:`, err)
|
|
||||||
})
|
|
||||||
let crumbDetails = crumbResponse.split(':')
|
|
||||||
let crumbHeader = {}
|
|
||||||
crumbHeader[crumbDetails[0]] = crumbDetails[1]
|
|
||||||
return crumbHeader
|
|
||||||
}
|
|
||||||
|
|
||||||
function runRelease (targetBranch, options) {
|
function runRelease (targetBranch, options) {
|
||||||
if (options.ci) {
|
if (options.ci) {
|
||||||
switch (options.ci) {
|
switch (options.ci) {
|
||||||
|
@ -184,15 +116,10 @@ function runRelease (targetBranch, options) {
|
||||||
buildAppVeyor(targetBranch, options.ghRelease)
|
buildAppVeyor(targetBranch, options.ghRelease)
|
||||||
break
|
break
|
||||||
}
|
}
|
||||||
case 'Jenkins': {
|
|
||||||
buildJenkins(targetBranch, options.ghRelease, options.job)
|
|
||||||
break
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
buildCircleCI(targetBranch, options.ghRelease, options.job)
|
buildCircleCI(targetBranch, options.ghRelease, options.job)
|
||||||
buildAppVeyor(targetBranch, options.ghRelease)
|
buildAppVeyor(targetBranch, options.ghRelease)
|
||||||
buildJenkins(targetBranch, options.ghRelease, options.job)
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -203,7 +130,7 @@ if (require.main === module) {
|
||||||
const targetBranch = args._[0]
|
const targetBranch = args._[0]
|
||||||
if (args._.length < 1) {
|
if (args._.length < 1) {
|
||||||
console.log(`Trigger CI to build release builds of electron.
|
console.log(`Trigger CI to build release builds of electron.
|
||||||
Usage: ci-release-build.js [--job=CI_JOB_NAME] [--ci=CircleCI|AppVeyor|Jenkins] [--ghRelease] TARGET_BRANCH
|
Usage: ci-release-build.js [--job=CI_JOB_NAME] [--ci=CircleCI|AppVeyor] [--ghRelease] TARGET_BRANCH
|
||||||
`)
|
`)
|
||||||
process.exit(0)
|
process.exit(0)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue