首页 > 系统相关 >Ubuntu18.04.5配置离线镜像仓库

Ubuntu18.04.5配置离线镜像仓库

时间:2023-11-01 16:47:27浏览次数:33  
标签:http 离线 repo huaweicloud ubuntu 镜像 Ubuntu18.04 com ports

1、配置apt-mirror配置文件

cat>/etc/apt/apt-mirror<<EOF
root@Huawei-sources-list:/etc/apt# cat mirror.list
############# config ##################
#
#set base_path    /var/www/html/18.04.5/
#
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 ##############
# 18.04.5
deb http://repo.huaweicloud.com/ubuntu-ports/ bionic main restricted universe multiverse

deb http://repo.huaweicloud.com/ubuntu-ports/ bionic-updates main restricted universe multiverse

deb http://repo.huaweicloud.com/ubuntu-ports/ bionic-backports main restricted universe multiverse

deb http://repo.huaweicloud.com/ubuntu-ports/ bionic-proposed  main restricted universe multiverse

deb http://repo.huaweicloud.com/ubuntu-ports/ bionic-security main restricted universe multiverse

clean http://archive.huaweicloud.com/ubuntu-ports/


EOF
cat>/etc/apt/source.list<<'EOF'
############# config ##################
#
set base_path    /var/www/html/
#
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 http://repo.huaweicloud.com/ubuntu-ports/ focal main restricted
deb http://repo.huaweicloud.com/ubuntu-ports/ focal-updates main restricted
deb http://repo.huaweicloud.com/ubuntu-ports/ focal universe
deb http://repo.huaweicloud.com/ubuntu-ports/ focal-updates universe
deb http://repo.huaweicloud.com/ubuntu-ports/ focal multiverse
deb http://repo.huaweicloud.com/ubuntu-ports/ focal-updates multiverse
deb http://repo.huaweicloud.com/ubuntu-ports/ focal-backports main restricted universe multiverse
deb http://repo.huaweicloud.com/ubuntu-ports/ focal-security main restricted
deb http://repo.huaweicloud.com/ubuntu-ports/ focal-security universe
deb http://repo.huaweicloud.com/ubuntu-ports/ focal-security multiverse

clean http://archive.huaweicloud.com/ubuntu-ports/
EOF
Ubuntu20.04

 

2、执行下载

nohup apt-mirror &

标签:http,离线,repo,huaweicloud,ubuntu,镜像,Ubuntu18.04,com,ports
From: https://www.cnblogs.com/vmsysjack/p/17803467.html

相关文章

  • 阿里云镜像加速器
    是什么:https://promotion.aliyun.com/ntms/act/kubernetes.html注册一个属于自己的阿里云账号(可复用淘宝账号)获取加速器地址连接控制台->容器镜像服务->镜像工具->镜像加速器mkdir-p/etc/dockertee/etc/docker/daemon.json<<-'EOF'{"registry-mirrors":["......
  • 在linux下 geoserver 离线安装GDAL
        ......
  • Docker导出镜像的总结
    Docker导出镜像的总结安装Dockermkdir-p/etc/dockercat>/etc/docker/daemon.josn<<EOF{"bip":"10.233.0.1/16"}EOFyuminstalldocker-ysystemctlenable--nowdocker下载部分镜像dockerpullredis:7.2dockerpullnginx:1.24docker......
  • Ubuntu18.04安装mysql5.7.27
    步骤如下:1.获取mysql-apt-config工具wgethttps://dev.mysql.com/get/mysql-apt-config_0.8.11-1_all.deb2.安装config工具第一项点进去选择5.7(默认是8.0)dpkg-imysql-apt-config_0.8.11-1_all.deb3.更新源sudoapt-getupdate4.安装mysqksudoapt-getinstallmysql-server......
  • centos7:安装python3.6.8:安装uvicorn、fastapi、pymysql:指定国内的pypi镜像源
    yuminstallpython3python3-develgccmakelibaio-develpip3install-ihttp://mirrors.aliyun.com/pypi/simple--trusted-hostmirrors.aliyun.com"uvicorn[standard]"==0.16.0pymysqlfastapi 关键点:因为centos7的软件仓库中,python3的版本比较低:python3-3.6.8-1......
  • 离线操作
    将询问离线,根据询问的区间$[l,r]$的按特定的顺序排序。一般是按$r$进行升序。当没有询问时,可以当作是无数个区间,然后每次$r++$即可维护所有的区间,这个技术被某些人称为扫描线,但实质上是与计算几何中的扫描线不是一个东西,只是为了形象的描述而已。eq1.P1972HH的项链题解将询问......
  • kubernetes拉取私有Harbor仓库镜像
    场景描述私有镜像仓库:http://172.16.30.56kubernete集群使用的是containerdkubernete集群中部署服务时,报错:Error:ImagePullBackOffkubernetes拉取私有Harbor仓库镜像配置说明harbor检查确保私有harbor能正常访问,能正常推送镜像:页面访问正常docker获取镜像正常......
  • pip安装库包,及镜像源的配置
     pip安装库包,及镜像源的配置一、常用镜像源下载地址:1清华:https://pypi.tuna.tsinghua.edu.cn/simple2阿里云:http://mirrors.aliyun.com/pypi/simple/3中国科技大学https://pypi.mirrors.ustc.edu.cn/simple/4华中理工大学:http://pypi.hustunique.com/5山东理工大学......
  • nexus3 作为docker仓库与镜像缓存的记录
    因为搞k8s拉取镜像太慢,不同版本每次都要等待半天,用nexus3作为docker镜像的缓存与仓库镜像,虽然权限控制弱一些,够用,记录用法及踩坑。1作为镜像缓存,唯一的坑,就是第一次拉取及后续拉取镜像,没有缓存,也不晓得为啥配置了 insecure-registries和 registry-mirrors没生效,iftop观察流......
  • 收藏从未停止,练习从未开始——MYSQL游标存储过程IDEA快捷键配置SpringBoot入门到入土G
    “收藏从未停止,练习从未开始”,或许有那么一些好题好方法,在被你选中收藏后却遗忘在收藏夹里积起了灰?今天请务必打开你沉甸甸的收藏重新回顾,分享一下那些曾让你拍案叫绝的好东西吧!本人详解:(提醒:随笔)本人详解作者:王文峰,参加过2020年度博客之星,《Java王大师王天师》作者采购供应链共享......