@@ -53,6 +53,49 @@ gpgkey = https://sdk-snapshots.couchbase.com/libcouchbase/couchbase.key
5353 }
5454 }
5555
56+ stage(' rhel8 x86_64' ) {
57+ agent { label ' centos7-signing' }
58+ steps {
59+ cleanWs()
60+ copyArtifacts(projectName : ' lcb-lnx-scripted-build-pipeline' , selector : upstream(), filter : ' libcouchbase-*rhel8*.tar' )
61+ writeFile(file : " rpmsign-wrapper.expect" , text : """
62+ set pkgName [lrange \$ argv 0 0]
63+ spawn rpm --addsign -D "_signature gpg" -D "_gpg_name ${ GPG_NAME} " \$ pkgName
64+ expect -exact "Enter pass phrase: "
65+ send -- "\\ r"
66+ expect eof
67+ wait
68+ """ )
69+ sh(" tar xf libcouchbase-*x86_64.tar" )
70+ sh(' mkdir -p repo/el8/x86_64' )
71+ dir(' repo' ) {
72+ sh(" gpg --export --armor ${ GPG_NAME} > couchbase.key" )
73+ writeFile(file : ' libcouchbase-rhel8-x86_64.repo' , text : """
74+ [couchbase]
75+ enabled = 1
76+ name = libcouchbase package for rhel8 x86_64
77+ baseurl = https://sdk-snapshots.couchbase.com/libcouchbase/el8/x86_64
78+ gpgcheck = 1
79+ gpgkey = https://sdk-snapshots.couchbase.com/libcouchbase/couchbase.key
80+ """ )
81+ }
82+ sh(' cp -a libcouchbase-*x86_64/*rpm repo/el8/x86_64' )
83+ sh(' for p in repo/el8/x86_64/*.rpm; do expect rpmsign-wrapper.expect \$ p; done' )
84+ sh(' createrepo --checksum sha repo/el8/x86_64' )
85+ sh(" gpg --batch --yes --local-user ${ GPG_NAME} --detach-sign --armor repo/el8/x86_64/repodata/repomd.xml" )
86+ sh(" rm -rf repo/el8/x86_64@tmp" )
87+ sh(" tar cf repo-${ BUILD_NUMBER} -rhel8-x86_64.tar repo" )
88+ archiveArtifacts(artifacts : " repo-${ BUILD_NUMBER} -rhel8-x86_64.tar" , fingerprint : true )
89+ withAWS(credentials : ' aws-sdk' , region : ' us-east-1' ) {
90+ s3Upload(
91+ bucket : ' sdk-snapshots.couchbase.com' ,
92+ file : ' repo/' ,
93+ path : ' libcouchbase/' ,
94+ )
95+ }
96+ }
97+ }
98+
5699 stage(' amzn2 x86_64' ) {
57100 agent { label ' centos7-signing' }
58101 steps {
0 commit comments