apt-mirror
Debianのミラーを建てる DockerでCI/CDをしだすと、Docker Hub・Debianリポジトリとの通信がかなり増える。 (Debianベースじゃないイメージもあるが、 概ねDebianベースが推奨されている ので。) Debianのガイド ではftpmirrorが推奨されているが、場合によってはもっとお手軽なほうが良いこともある。(他人も面倒を見うる、など。) 以下は、 apt-mirror を使う例。 ############# config ################## # # set base_path /var/spool/apt-mirror # # set mirror_path $base_path/mirror # set skel_path $base_path/skel # set var_path $base_path/var # set cleanscript $var_path/clean.sh # set defaultarch <running host architecture> # set postmirror_script $var_path/postmirror.sh # set run_postmirror 0 set nthreads 20 set _tilde 0 # ############# end config ############## deb-amd64 http://ftp.jp.debian.org/debian stretch main contrib non-free deb-i386 http://ftp.jp.debian.org/debian stretch main contrib non-free deb-src http://ftp.jp.debian.org/debian stretch main contrib non-free deb-amd64 http://ftp.jp.debian.org/debian stretch-updates main contrib non-free deb-i386 http://ftp.jp.debian.org/debian stretch-updates