From b7d369f4fcd9dd67f45ba2915964c18d4d0cdd89 Mon Sep 17 00:00:00 2001 From: Alexander Lutay Date: Tue, 2 Jul 2019 14:54:08 +0200 Subject: [PATCH] TT#60100 TT#44859 Update janus-admin Dockerfile (as we mark it as 'upstream') It was never build before, we have just recently started handling this repository as 'upstream' and build it per git branch, see TT#44859. Previous Jenkins was not able to build it: > The following packages have unmet dependencies: > nodejs : Conflicts: nodejs-legacy > Conflicts: npm Removing unnecessary dependencies. Change-Id: I754a382e506fb8ffff7db37ec534a8966262cb28 --- t/Dockerfile | 23 +++++++++++++---------- t/sources.list.d/builddeps.list | 0 t/sources.list.d/preferences | 0 3 files changed, 13 insertions(+), 10 deletions(-) create mode 100644 t/sources.list.d/builddeps.list create mode 100644 t/sources.list.d/preferences diff --git a/t/Dockerfile b/t/Dockerfile index f453815..915262c 100644 --- a/t/Dockerfile +++ b/t/Dockerfile @@ -5,17 +5,17 @@ FROM docker.mgm.sipwise.com/sipwise-stretch:latest # is updated with the current date. It will force refresh of all # of the base images and things like `apt-get update` won't be using # old cached versions when the Dockerfile is built. -ENV REFRESHED_AT 2017-09-25 +ENV REFRESHED_AT 2019-07-02 -# TODO - the release-trunk-stretch is too dynamic yet, though required build deps -RUN echo "deb https://deb.sipwise.com/autobuild/ release-trunk-stretch main" >>/etc/apt/sources.list +COPY t/sources.list.d/builddeps.list /etc/apt/sources.list.d/ +COPY t/sources.list.d/preferences /etc/apt/preferences.d/ -RUN apt-get update -RUN apt-get install --assume-yes \ +RUN apt-get update && \ + apt-get install --assume-yes \ curl \ nodejs \ - nodejs-legacy \ - npm + && \ + apt-get clean ADD package.json /tmp/ ADD npm-shrinkwrap.json /tmp/ @@ -30,10 +30,13 @@ RUN echo "cd /code && ./t/testrunner" >/root/.bash_history WORKDIR /code ################################################################################ -# Instructions for usage +# Instructions for usage (from root folder of git repository) # ---------------------- -# When you want to build the base image from scratch (jump to the next section if you don't want to build yourself!): -# NOTE: run the following commands from root folder of git repository: +# When you want to build the base image from scratch +# (jump to the next section if you don't want to build yourself!). +# The first you need to put the proper NGCP sources at t/sources.list.d/builddeps.list +# for instance, trunk: +# % echo "deb https://deb.sipwise.com/autobuild/ release-trunk-buster main" > t/sources.list.d/builddeps.list # % docker build --tag="janus-admin-stretch" -f ./t/Dockerfile . # % docker run --rm -i -t -v $(pwd):/code:ro -v /results janus-admin-stretch:latest bash # diff --git a/t/sources.list.d/builddeps.list b/t/sources.list.d/builddeps.list new file mode 100644 index 0000000..e69de29 diff --git a/t/sources.list.d/preferences b/t/sources.list.d/preferences new file mode 100644 index 0000000..e69de29