Patrick Pschorn | 59e2580 | 2019-01-15 14:41:03 +0100 | [diff] [blame] | 1 | pipeline { |
2 | agent { | ||||
3 | kubernetes { | ||||
Patrick Pschorn | 5389fc0 | 2019-01-16 12:07:06 +0100 | [diff] [blame] | 4 | label 'my-agent-pod' |
Patrick Pschorn | 59e2580 | 2019-01-15 14:41:03 +0100 | [diff] [blame] | 5 | yaml """ |
6 | apiVersion: v1 | ||||
7 | kind: Pod | ||||
8 | spec: | ||||
9 | containers: | ||||
10 | - name: maven | ||||
11 | image: maven:alpine | ||||
mdamm | f36e86b | 2019-03-06 13:11:45 +0100 | [diff] [blame] | 12 | resources: |
mdamm | 7655273 | 2019-03-06 15:04:29 +0100 | [diff] [blame] | 13 | requests: |
14 | memory: "2Gi" | ||||
15 | cpu: "1" | ||||
16 | limits: | ||||
17 | memory: "2Gi" | ||||
18 | cpu: "1" | ||||
19 | command: | ||||
Patrick Pschorn | 59e2580 | 2019-01-15 14:41:03 +0100 | [diff] [blame] | 20 | - cat |
21 | tty: true | ||||
22 | """ | ||||
23 | } | ||||
24 | } | ||||
25 | stages { | ||||
26 | stage('Run maven') { | ||||
27 | steps { | ||||
28 | container('maven') { | ||||
Thomas Psota | 8276223 | 2019-06-18 14:23:24 +0200 | [diff] [blame] | 29 | sh ''' |
Thomas Psota | fe88233 | 2019-06-18 14:52:08 +0200 | [diff] [blame] | 30 | cd "sdks/java/basys.sdk/" |
Thomas Psota | 9820d76 | 2019-06-18 15:04:00 +0200 | [diff] [blame] | 31 | mvn -B clean verify |
Thomas Psota | 8276223 | 2019-06-18 14:23:24 +0200 | [diff] [blame] | 32 | ''' |
Patrick Pschorn | 59e2580 | 2019-01-15 14:41:03 +0100 | [diff] [blame] | 33 | } |
34 | } | ||||
35 | } | ||||
36 | } | ||||
Patrick Pschorn | 042f970 | 2019-01-15 13:34:52 +0100 | [diff] [blame] | 37 | } |