From: Wesley Hirsch Date: Fri, 17 Mar 2017 19:50:56 +0000 (-0400) Subject: Added Dockerfile and Jenkinsfile X-Git-Tag: v2.0.0~29 X-Git-Url: https://osm.etsi.org/gitweb/?a=commitdiff_plain;h=adbe65e68fc515f5ecb792192ce4d404061689f8;p=osm%2FSO.git Added Dockerfile and Jenkinsfile Change-Id: I18622cb6075bedd70156a907f845d4e03a61d815 Signed-off-by: Wesley Hirsch --- diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 00000000..463b1c60 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,22 @@ +FROM ubuntu:16.04 + +RUN apt-get update && apt-get -y install python3 curl build-essential +RUN curl http://repos.riftio.com/public/xenial-riftware-public-key | apt-key add - && \ + curl -o /etc/apt/sources.list.d/OSM.list http://buildtracker.riftio.com/repo_file/ub16/OSM/ && \ + apt-get update && \ + apt-get -y install rw.toolchain-rwbase \ + rw.toolchain-rwtoolchain \ + rw.core.mgmt-mgmt \ + rw.core.util-util \ + rw.core.rwvx-rwvx \ + rw.core.rwvx-rwdts \ + rw.automation.core-RWAUTO \ + rw.tools-container-tools \ + rw.tools-scripts \ + python-cinderclient \ + libxml2-dev \ + libxslt-dev + +RUN /usr/rift/container_tools/mkcontainer --modes build --modes ext --repo OSM + +RUN chmod 777 /usr/rift /usr/rift/usr/share diff --git a/Jenkinsfile b/Jenkinsfile new file mode 100644 index 00000000..0c556a47 --- /dev/null +++ b/Jenkinsfile @@ -0,0 +1,27 @@ +pipeline { + agent any + stages { + stage("Build") { + agent { + dockerfile true + } + steps { + sh 'make NOT_DEVELOPER_BUILD=TRUE -j16 package' + stash name: "deb-files", includes: ".build/*.deb" + } + } + stage("Repo Component") { + steps { + unstash "deb-files" + sh ''' + mkdir -p pool/SO + mv .build/*.deb pool/SO/ + mkdir -p dists/$RELEASE/SO/binary-amd64/ + apt-ftparchive packages pool/SO > dists/$RELEASE/SO/binary-amd64/Packages + gzip -9fk dists/$RELEASE/SO/binary-amd64/Packages + ''' + archiveArtifacts artifacts: "dists/**,pool/SO/*.deb" + } + } + } +}