Skip to content

Commit

Permalink
MCU8QA-498 added new CICD files
Browse files Browse the repository at this point in the history
  • Loading branch information
Aman Hebbale authored and Aman Hebbale committed Apr 5, 2021
1 parent 4d31a50 commit 2e40340
Show file tree
Hide file tree
Showing 3 changed files with 63 additions and 174 deletions.
59 changes: 59 additions & 0 deletions .citd/Jenkinsfilek8s
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
// Jenkinsfile v2.0.0
pipeline {
agent {
kubernetes {

defaultContainer 'xc8-mplabx'
yamlFile '.citd/cloudprovider.yml'
}
}
parameters {
string( name: 'NOTIFICATION_EMAIL',
defaultValue: 'PICAVR_Examples_GateKeepers@microchip.com',
description: "Email to send build failure and fixed notifications.")
}

environment {
GITHUB_OWNER = 'microchip-pic-avr-examples'
GITHUB_URL ='https://github.com/microchip-pic-avr-examples/avr128db48-getting-started-with-opamp-mplab-mcc'
BITBUCKET_URL = 'https://bitbucket.microchip.com/scm/ebe/avr128db48-getting-started-with-opamp-mplab-mcc.git'
SEMVER_REGEX = '^(0|[1-9]\\d*)+\\.(0|[1-9]\\d*)+\\.(0|[1-9]\\d*)+$'
ARTIFACTORY_SERVER = 'https://artifacts.microchip.com:7999/artifactory'
}
options {
timestamps()
timeout(time: 30, unit: 'MINUTES')
}

stages {
stage('setup') {
steps {
script {
execute("git clone https://bitbucket.microchip.com/scm/citd/mpae-buildpipeline-groovy-scripts.git")
def buildPipeline = load ('mpae-buildpipeline-groovy-scripts/xc8mplabx-buildpipeline.groovy')
buildPipeline.runStages()
}
}
}
}

post {
failure {
script {
sendPipelineFailureEmail()
}
}
}
}
def execute(String cmd) {
if(isUnix()) {
sh cmd
} else {
bat cmd
}
}
def sendPipelineFailureEmail() {
mail to: "${env.EMAILLIST},${params.NOTIFICATION_EMAIL}",
subject: "Failed Pipeline: ${currentBuild.fullDisplayName}",
body: "Pipeline failure. ${env.BUILD_URL}"
}
8 changes: 4 additions & 4 deletions cloudprovider.yml → .citd/cloudprovider.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ spec:
tty: true
resources:
requests:
cpu: 1
memory: 4Gi
cpu: 0.25
memory: 500Mi
limits:
cpu: 2
memory: 8Gi
cpu: 0.5
memory: 750Mi
170 changes: 0 additions & 170 deletions Jenkinsfilek8s

This file was deleted.

0 comments on commit 2e40340

Please sign in to comment.