Add jq to sriovdp image 97/997/1
authorFerenc Tóth <ferenc.2.toth@nokia.com>
Fri, 14 Jun 2019 12:42:23 +0000 (14:42 +0200)
committerFerenc Tóth <ferenc.2.toth@nokia.com>
Fri, 14 Jun 2019 12:42:23 +0000 (14:42 +0200)
Signed-off-by: Ferenc Tóth <ferenc.2.toth@nokia.com>
Change-Id: I19893e39652003640f995a6a88342ceb12c7a9d3

SPECS/caas-sriovdp.spec
docker-build/sriovdp/Dockerfile

index 1da400e..08352b6 100644 (file)
@@ -15,7 +15,7 @@
 %define COMPONENT sriovdp
 %define RPM_NAME caas-%{COMPONENT}
 %define RPM_MAJOR_VERSION 2.0.0
-%define RPM_MINOR_VERSION 2
+%define RPM_MINOR_VERSION 3
 %define IMAGE_TAG %{RPM_MAJOR_VERSION}-%{RPM_MINOR_VERSION}
 
 Name:           %{RPM_NAME}
@@ -28,7 +28,7 @@ BuildArch:      x86_64
 Vendor:         %{_platform_vendor} and intel/sriov-network-device-plugin unmodified
 Source0:        %{name}-%{version}.tar.gz
 
-Requires: docker-ce >= 18.09.2
+Requires: docker-ce >= 18.09.2, rsync
 BuildRequires: docker-ce >= 18.09.2
 
 %description
@@ -48,7 +48,7 @@ docker build \
   --build-arg http_proxy="${http_proxy}" \
   --build-arg https_proxy="${https_proxy}" \
   --build-arg no_proxy="${no_proxy}" \
-  --build-arg SRIOV="%{RPM_MAJOR_VERSION}" \
+  --build-arg SRIOVDP="%{RPM_MAJOR_VERSION}" \
   --tag %{COMPONENT}:%{IMAGE_TAG} \
   %{_builddir}/%{RPM_NAME}-%{RPM_MAJOR_VERSION}/docker-build/%{COMPONENT}/
 
index 7fc7b68..e478e91 100644 (file)
 FROM alpine:3.9
 MAINTAINER Levente Kale <levente.kale@nokia.com>
 
-ARG SRIOV
-ENV SRIOV_VERSION=$SRIOV
+ARG SRIOVDP
+ENV SRIOVDP_VERSION=$SRIOVDP
 ENV GOPATH /go
 ENV PATH $GOPATH/bin:/usr/local/go/bin:$PATH
 ENV GOOS=linux
 
 WORKDIR /
 
-RUN apk add --no-cache --virtual .tools ca-certificates gcc musl-dev go glide git \
+RUN apk add --no-cache jq \
+&& apk add --no-cache --virtual .tools ca-certificates gcc musl-dev go glide git \
 && mkdir -p $GOPATH/src/github.com/intel \
-&& git clone https://github.com/intel/sriov-network-device-plugin.git $GOPATH/src/github.com/intel/sriov-network-device-plugin --branch=v${SRIOV_VERSION} \
+&& git clone https://github.com/intel/sriov-network-device-plugin.git $GOPATH/src/github.com/intel/sriov-network-device-plugin --branch=v${SRIOVDP_VERSION} \
 && cd $GOPATH/src/github.com/intel/sriov-network-device-plugin \
 && glide --quiet install -v \
 && go install -a -ldflags '-extldflags "-static"' github.com/intel/sriov-network-device-plugin/cmd/sriovdp \
@@ -38,7 +39,7 @@ RUN apk add --no-cache --virtual .tools ca-certificates gcc musl-dev go glide gi
 && rm -rf /tmp/* \
 && rm -rf ~/.glide
 
-RUN chmod 700 /usr/local/bin/sriovdp 
+RUN chmod 700 /usr/local/bin/sriovdp
 
 LABEL io.k8s.display-name="SRIOV Network Device Plugin"
 ENTRYPOINT ["/usr/local/bin/sriovdp"]