From 65d69fb41316e96d401c45a5dd2340366d307673 Mon Sep 17 00:00:00 2001 From: TheBrokenRail Date: Mon, 21 Dec 2020 14:50:41 -0500 Subject: [PATCH] Fix Jenkins + Improve Build --- Dockerfile | 8 ++++---- Jenkinsfile | 7 +++++-- {DEBIAN => build/DEBIAN}/control | 0 build-irrlicht.sh => build/build-irrlicht.sh | 0 build-minetest.sh => build/build-minetest.sh | 2 ++ install-dependencies.sh => build/install-dependencies.sh | 0 6 files changed, 11 insertions(+), 6 deletions(-) rename {DEBIAN => build/DEBIAN}/control (100%) rename build-irrlicht.sh => build/build-irrlicht.sh (100%) rename build-minetest.sh => build/build-minetest.sh (99%) rename install-dependencies.sh => build/install-dependencies.sh (100%) diff --git a/Dockerfile b/Dockerfile index e659008..4a0169a 100644 --- a/Dockerfile +++ b/Dockerfile @@ -5,11 +5,11 @@ ENV DEBIAN_FRONTEND noninteractive RUN mkdir /app WORKDIR /app -ADD ./install-dependencies.sh /app/ +ADD build/install-dependencies.sh /app/ RUN ./install-dependencies.sh -ADD ./build-irrlicht.sh /app/ +ADD build/build-irrlicht.sh /app/ RUN ./build-irrlicht.sh -ADD ./build-minetest.sh /app/ -ADD ./DEBIAN /app/DEBIAN +ADD build/build-minetest.sh /app/ +ADD build/DEBIAN /app/DEBIAN diff --git a/Jenkinsfile b/Jenkinsfile index dc058a2..4b75a06 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -7,11 +7,14 @@ pipeline { stages { stage('Build') { steps { - sh './build-minetest.sh' + # Build + sh 'cd /app; ./build-minetest.sh' + # Copy Artifacts + sh 'mkdir out; cp /out/*.deb out' } post { success { - archiveArtifacts artifacts: '/out/*.deb', fingerprint: true + archiveArtifacts artifacts: 'out/*.deb', fingerprint: true } } } diff --git a/DEBIAN/control b/build/DEBIAN/control similarity index 100% rename from DEBIAN/control rename to build/DEBIAN/control diff --git a/build-irrlicht.sh b/build/build-irrlicht.sh similarity index 100% rename from build-irrlicht.sh rename to build/build-irrlicht.sh diff --git a/build-minetest.sh b/build/build-minetest.sh similarity index 99% rename from build-minetest.sh rename to build/build-minetest.sh index dd4f35b..52ca1b2 100755 --- a/build-minetest.sh +++ b/build/build-minetest.sh @@ -2,6 +2,8 @@ set -e +cd /app + git clone https://github.com/TheBrokenRail/minetest.git -b desktop-touch cd minetest diff --git a/install-dependencies.sh b/build/install-dependencies.sh similarity index 100% rename from install-dependencies.sh rename to build/install-dependencies.sh