security.debian.org には Debian Docker イメージの「リリース ファイルがありません」

security.debian.org には Debian Docker イメージの「リリース ファイルがありません」

と は両方とも現在壊れているようですdebian:stable-slim(debian:stable更新のため):

> $ docker run -ti --rm  debian:stable-slim
Unable to find image 'debian:stable-slim' locally
stable-slim: Pulling from library/debian
fc491617b0f1: Pull complete
Digest: sha256:a85c2c0e634946e92a6f4a9a4f6ce5f19ce7c11885bc198f04ab3ae8dacbaffa
Status: Downloaded newer image for debian:stable-slim
root@e610973ac2f8:/# apt update
Ign:1 http://security.debian.org/debian-security stable/updates InRelease
Err:2 http://security.debian.org/debian-security stable/updates Release
  404  Not Found [IP: 151.101.130.132 80]
Get:3 http://deb.debian.org/debian stable InRelease [113 kB]
Get:4 http://deb.debian.org/debian stable-updates InRelease [36.8 kB]
Get:5 http://deb.debian.org/debian stable/main amd64 Packages [8178 kB]
Reading package lists... Done
E: The repository 'http://security.debian.org/debian-security stable/updates Release' does not have a Release file.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.

他にこれを経験した人、または回避策を見つけた人はいますか?

答え1

この行を変更することでこれを修正できました:

deb http://security.debian.org/debian-security stable/updates main

deb http://security.debian.org/debian-security stable-security/updates main

次のコマンドを実行することでそれを実行できます:

sed -i 's/stable\/updates/stable-security\/updates/' /etc/apt/sources.list

答え2

問題

Debian Stretch (9) Docker イメージでこの問題が発生しました。

apt-get updateを実行したときに以下のエラーが発生しました

W: The repository 'http://security.debian.org/debian-security stretch/updates Release' does not have a Release file.
W: The repository 'http://deb.debian.org/debian stretch Release' does not have a Release file.
W: The repository 'http://deb.debian.org/debian stretch-updates Release' does not have a Release file.
E: Failed to fetch http://security.debian.org/debian-security/dists/stretch/updates/main/binary-amd64/Packages  404  Not Found [IP: xx]
E: Failed to fetch http://deb.debian.org/debian/dists/stretch/main/binary-amd64/Packages  404  Not Found
E: Failed to fetch http://deb.debian.org/debian/dists/stretch-updates/main/binary-amd64/Packages  404  Not Found
E: Some index files failed to download. They have been ignored, or old ones used instead.

背景

これは特にセキュリティ リポジトリに関連しています。

これらのリポジトリ定義はaptが更新を取得するために使用され、/etc/apt/sources.list

公式Debianセキュリティ推奨事項 -https://www.debian.org/セキュリティ/

To keep your Debian operating system up-to-date with security patches, please add the following line to your /etc/apt/sources.list file

`deb http://security.debian.org/debian-security bullseye-security main contrib non-free`

答え

Dockerfileにこの行を追加します

RUN echo "deb http://security.debian.org/debian-security bullseye-security main contrib non-free" > /etc/apt/sources.list

RUN apt-get update

その他の解決策

私にとってうまくいかなかったこと:

  • リポジトリを stable-security に変更する
  • フラグ付きでaptを実行--allow-releaseinfo-change- apt-get updateと組み合わせたフラグが認識されませんでした

他に効果があったもの:

  • bullseye セキュリティ リポジトリを使用する代わりに、stretch アーカイブ リポジトリを使用することもできますdeb http://archive.debian.org/debian stretch main contrib non-free。セキュリティの観点からは、最新リリースのセキュリティに固執する方がよいでしょう。

アップデート

セキュリティ リポジトリの問題だけに焦点を当てている場合は、上記は正しいです。

セキュリティ リポジトリでこのような問題が発生するのはなぜでしょうか?

私の場合、Debian 9 はアーカイブされてお​​り、サポートもメンテナンスもされていないバージョンです。

セキュリティ リポジトリを「修正」(バイパス) することはできましたが、APT の依存関係リポジトリでさらに問題が発生しました。バージョンが廃止されたため、これらのリポジトリはアーカイブを指す必要がありました。

一般的に、これにより Debian 10 へのアップグレードが強制されました。Debian 10 では上記の修正は必要ありませんでした。

答え3

debian.org から... ("stretch" を現在実行中のバージョンに置き換えます)。類似している他の行を消去してから、apt-get update と apt-get upgrade を実行します。

deb http://archive.debian.org/debian/ stretch main non-free contrib
deb-src http://archive.debian.org/debian/ stretch main non-free contrib

deb http://archive.debian.org/debian-security/ stretch/updates main non-free contrib
deb-src http://archive.debian.org/debian-security/ stretch/updates main non-free contrib

関連情報