31135ddec6
This PS is to update the node problem detector base image to focal from bionic. Change-Id: Ib0c4e9234712483222b64a35f333fb9d29bf9809
20 lines
849 B
Docker
20 lines
849 B
Docker
ARG FROM=docker.io/ubuntu:focal
|
|
FROM ${FROM}
|
|
|
|
ARG NPD_VERSION="v0.8.10"
|
|
ARG NPD_SRC_URL="https://github.com/kubernetes/node-problem-detector/releases/download/${NPD_VERSION}"
|
|
|
|
RUN apt-get update ;\
|
|
apt-get upgrade -y ;\
|
|
apt-get install --no-install-recommends -y wget ca-certificates ;\
|
|
#Create a Temp dir to download and extract the package
|
|
TMP_DIR=$(mktemp --directory) ;\
|
|
wget -q ${NPD_SRC_URL}/node-problem-detector-${NPD_VERSION}-linux_amd64.tar.gz -O ${TMP_DIR}/node-problem-detector-${NPD_VERSION}.tar.gz ;\
|
|
mkdir -p /opt/node-problem-detector/ ;\
|
|
tar zxf ${TMP_DIR}/node-problem-detector-${NPD_VERSION}.tar.gz -C /opt/node-problem-detector ;\
|
|
#Cleanup the directories
|
|
apt-get autoremove --purge ca-certificates ;\
|
|
apt-get clean ;\
|
|
rm -rf /var/lib/apt/lists/* /root/.cache ;\
|
|
rm -rf ${TMP_DIR}
|