소스 검색

fix repositories at images based on debian/eol

(cherry picked from commit 2e0639282368eee4a507d12aea8e536d03a2936c)
Victor Seva 1 년 전
부모
커밋
49a3bbf7b8
1개의 변경된 파일9개의 추가작업 그리고 0개의 파일을 삭제
  1. 9 0
      create_dockerfile.sh

+ 9 - 0
create_dockerfile.sh

@@ -49,7 +49,16 @@ LABEL org.opencontainers.image.authors Victor Seva <linuxmaniac@torreviejawirele
 # 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 ${DATE}
+EOF
+
+if [[ "${docker_tag}" =~ "debian/eol" ]] ; then
+  cat >>"${DOCKERFILE}" <<EOF
+# fix repositories
+RUN sed -i -e 's/deb.debian.org/archive.debian.org/g' -e '/${dist}-updates/d' /etc/apt/sources.list
+EOF
+fi
 
+  cat >>"${DOCKERFILE}" <<EOF
 RUN rm -rf /var/lib/apt/lists/* && apt-get update && \
   DEBIAN_FRONTEND=noninteractive apt-get install -qq --assume-yes gnupg wget apt-transport-https
 # kamailio repo