-
Notifications
You must be signed in to change notification settings - Fork 1
/
jenkinsfile
77 lines (73 loc) · 2.13 KB
/
jenkinsfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
currentBuild.displayName = "Test#"+currentBuild.number
pipeline {
agent {
kubernetes {
label master
yaml """
kind: Pod
metadata:
name: jenkins-slave
spec:
containers:
- name: kaniko
image: gcr.io/kaniko-project/executor:debug
imagePullPolicy: Always
command:
- /busybox/cat
tty: true
volumeMounts:
- name: aws-secret
mountPath: /root/.aws/
- name: docker-registry-config
mountPath: /kaniko/.docker
restartPolicy: Never
volumes:
- name: aws-secret
secret:
secretName: aws-secret
- name: docker-registry-config
configMap:
name: docker-registry-config
"""
}
}
//tools {
// maven 'MAVEN354'
//}
environment {
//AWS_PROFILE = "v2d"
//KUBECONFIG = "$HOME/.kube/kubeconfig-dev"
//PATH = "$PATH:/usr/local/bin"
//SBT_OPTS="-Xss20M"
//DOCKER_HOST= "tcp://127.0.0.1:2375"
//DOCKER_BASE_REGISTRY= "969364019056.dkr.ecr.us-east-1.amazonaws.com"
//DOCKER_TARGET_REGISTRY= "969364019056.dkr.ecr.us-east-1.amazonaws.com"
//BUILD_DISPLAY_NAME= "calcite.1.${BUILD_NUMBER}"
GIT_CREDENTIAL_ID = "b0eb09fd-c156-4629-bdf4-2435fda563c7"
//ARTIFACTORY_SERVER_ID = "696333576@1449114955179"
}
stages {
stage('Clone') {
// agent {
// // Local Agent block(scope is local only for "Clone" stage), Agent is a docker image.
// docker {
// reuseNode false
// image 'ubuntu'
// }
// }
steps {
sh "printenv | sort" // prints all the environment variable
// Get some code from a GitHub repository
//git branch: "${params.BRANCH}",
//credentialsId: env.GIT_CREDENTIAL_ID,
//url: env.GIT_URL
}
}
stage('Maven Build') {
steps {
sh 'echo Test'
//sh 'mvn -Ppackage -U clean install -Dcheckstyle.skip=false -DskipTests=false -e -DskipDocker=false'
}
}
}
}