Skip to content

Commit 38d4746

Browse files
authored
Update our Jenkinsfile to emit version tagged binaries (#49)
It's desirable to emit binaries that have the version number baked right into them. With this fancy binary sitting there in S3 we'll be able to auto-deploy new versions / control which versions are in production. Real fancy. Signed-off-by: Brian L. Troutwine <blt@postmates.com>
1 parent bd7d1e7 commit 38d4746

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

Jenkinsfile

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,11 @@ node {
1717
env.VERSION = readFile('ver.current').trim()
1818
echo "${env.VERSION}"
1919

20+
sh "awk -F'\"' '/version/ {print \$2}' Cargo.toml > semvar.current"
21+
env.SEMVAR = readFile('semvar.current').trim()
22+
echo "${env.SEMVAR}"
23+
24+
2025
stage 'Install Deps'
2126
env.LD_LIBRARY_PATH = "${env.WORKSPACE}/rust/rustc/lib:${env.LD_LIBRARY_PATH}"
2227
env.PATH = "${env.WORKSPACE}/rust/bin:${env.PATH}"
@@ -47,5 +52,6 @@ node {
4752
sh "aws s3 cp target/release/cernan s3://artifacts.postmates.com/binaries/cernan/cernan-${env.VERSION}"
4853
if (env.BRANCH_NAME == "stable") {
4954
sh "aws s3 cp target/release/cernan s3://artifacts.postmates.com/binaries/cernan/cernan"
55+
sh "aws s3 cp target/release/cernan s3://artifacts.postmates.com/binaries/cernan/cernan-${env.SEMVAR}"
5056
}
5157
}

0 commit comments

Comments
 (0)