| garciadeblas | 3a82fc0 | 2017-04-21 15:03:48 +0200 | [diff] [blame] | 1 | pipeline { |
| garciadeblas | 0323ff6 | 2017-04-21 15:28:47 +0200 | [diff] [blame] | 2 | agent { |
| 3 | label "pipeline" |
| 4 | } |
| garciadeblas | 3a82fc0 | 2017-04-21 15:03:48 +0200 | [diff] [blame] | 5 | stages { |
| 6 | stage("Build") { |
| 7 | agent { |
| 8 | dockerfile true |
| 9 | } |
| 10 | steps { |
| garciadeblas | d40e551 | 2017-04-21 15:09:26 +0200 | [diff] [blame] | 11 | sh 'make package' |
| garciadeblas | 3a82fc0 | 2017-04-21 15:03:48 +0200 | [diff] [blame] | 12 | stash name: "deb-files", includes: ".build/*.deb" |
| 13 | } |
| 14 | } |
| 15 | stage("Unittest") { |
| 16 | agent { |
| 17 | dockerfile true |
| 18 | } |
| 19 | steps { |
| 20 | sh 'echo "UNITTEST"' |
| 21 | } |
| 22 | } |
| 23 | stage("Repo Component") { |
| 24 | steps { |
| 25 | unstash "deb-files" |
| 26 | sh ''' |
| 27 | mkdir -p pool/RO |
| garciadeblas | d40e551 | 2017-04-21 15:09:26 +0200 | [diff] [blame] | 28 | mv .build/*.deb pool/RO/ |
| garciadeblas | 3a82fc0 | 2017-04-21 15:03:48 +0200 | [diff] [blame] | 29 | mkdir -p dists/$RELEASE/unstable/RO/binary-amd64/ |
| 30 | apt-ftparchive packages pool/RO > dists/$RELEASE/unstable/RO/binary-amd64/Packages |
| 31 | gzip -9fk dists/$RELEASE/unstable/RO/binary-amd64/Packages |
| 32 | ''' |
| 33 | archiveArtifacts artifacts: "dists/**,pool/RO/*.deb" |
| 34 | } |
| 35 | } |
| 36 | } |
| 37 | } |