最新国产好看的视频,伊人天堂AV在线,国产Aaaaaa视频,蜜臀视频在线观看一区,人妻av色图,密臀久久久精品影片,青青视频免费观看毛片,久草在线观看视,国产三级精品色情在线

docker容器無(wú)法執(zhí)行vim的解決方案

 更新時(shí)間:2023年05月15日 10:15:08   作者:Danger_Life  
這篇文章主要介紹了docker容器無(wú)法執(zhí)行vim的解決方案,本文給大家介紹的非常詳細(xì),對(duì)大家的學(xué)習(xí)或工作具有一定的參考借鑒價(jià)值,需要的朋友可以參考下

docker容器無(wú)法執(zhí)行vim【已解決】

解決問(wèn)題直接看完整步驟目錄

docker容器中執(zhí)行vim失敗

bash: ll: command not found
bash: vim: command not found
bash: vi: command not found
安裝vim依舊報(bào)錯(cuò)

我的版本 cat /etc/debian_version
11.2

安裝文件

# 正常步驟,但是第一步下載非常慢,需要更換一下地址
1:apt-get update
2: apt-get install -y vim

沒(méi)更換之前,速度非常的慢

【失敗】這里我更換了163的但是報(bào)錯(cuò)

Ign:1 http://mirrors.163.com/debian jessie InRelease
Ign:2 http://mirrors.163.com/debian jessie-proposed-updates InRelease
Ign:3 http://mirrors.163.com/debian jessie-updates InRelease
Ign:4 http://mirrors.163.com/debian jessie-backports InRelease
Ign:5 http://mirrors.163.com/debian-security jessie/updates InRelease
Get:6 http://apt.postgresql.org/pub/repos/apt bullseye-pgdg InRelease [116 kB]
Err:7 http://mirrors.163.com/debian jessie Release
404 Not Found [IP: 101.71.33.11 80]
Err:8 http://mirrors.163.com/debian jessie-proposed-updates Release
404 Not Found [IP: 101.71.33.11 80]
Err:9 http://mirrors.163.com/debian jessie-updates Release
404 Not Found [IP: 101.71.33.11 80]
Err:10 http://mirrors.163.com/debian jessie-backports Release
404 Not Found [IP: 101.71.33.11 80]
Err:11 http://mirrors.163.com/debian-security jessie/updates Release
404 Not Found [IP: 101.71.33.11 80]
Reading package lists... Done
E: The repository 'http://mirrors.163.com/debian jessie 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.
E: The repository 'http://mirrors.163.com/debian jessie-proposed-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.
E: The repository 'http://mirrors.163.com/debian jessie-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.
E: The repository 'http://mirrors.163.com/debian jessie-backports 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.
E: The repository 'http://mirrors.163.com/debian-security jessie/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.

【失敗】這里我更換了阿里的第一種報(bào)錯(cuò)

root@a7e7ebb2ecad:/var/lib/apt/lists# echo -e "deb http://mirrors.aliyun.com/debian/ stretch main non-free contrib \ndeb-src http://mirrors.aliyun.com/debian/ stretch main non-free contrib \ndeb http://mirrors.aliyun.com/debian-security stretch/updates main \ndeb-src http://mirrors.aliyun.com/debian-security stretch/updates main \ndeb http://mirrors.aliyun.com/debian/ stretch-updates main non-free contrib \ndeb-src http://mirrors.aliyun.com/debian/ stretch-updates main non-free contrib \ndeb http://mirrors.aliyun.com/debian/ stretch-backports main non-free contrib \ndeb-src http://mirrors.aliyun.com/debian/ stretch-backports main non-free contrib" > /etc/apt/sources.list
root@a7e7ebb2ecad:/var/lib/apt/lists#
root@a7e7ebb2ecad:/var/lib/apt/lists# cat /etc/apt/sources.list
deb http://mirrors.aliyun.com/debian/ stretch main non-free contrib
deb-src http://mirrors.aliyun.com/debian/ stretch main non-free contrib
deb http://mirrors.aliyun.com/debian-security stretch/updates main
deb-src http://mirrors.aliyun.com/debian-security stretch/updates main
deb http://mirrors.aliyun.com/debian/ stretch-updates main non-free contrib
deb-src http://mirrors.aliyun.com/debian/ stretch-updates main non-free contrib
deb http://mirrors.aliyun.com/debian/ stretch-backports main non-free contrib
deb-src http://mirrors.aliyun.com/debian/ stretch-backports main non-free contrib
root@a7e7ebb2ecad:/var/lib/apt/lists# apt-get update
Ign:1 http://mirrors.aliyun.com/debian stretch InRelease
Ign:2 http://mirrors.aliyun.com/debian-security stretch/updates InRelease
Ign:3 http://mirrors.aliyun.com/debian stretch-updates InRelease
Ign:4 http://mirrors.aliyun.com/debian stretch-backports InRelease
Get:5 http://apt.postgresql.org/pub/repos/apt bullseye-pgdg InRelease [116 kB]
Err:6 http://mirrors.aliyun.com/debian stretch Release
404 Not Found [IP: 60.28.226.53 80]
Err:7 http://mirrors.aliyun.com/debian-security stretch/updates Release
404 Not Found [IP: 60.28.226.53 80]
Err:8 http://mirrors.aliyun.com/debian stretch-updates Release
404 Not Found [IP: 60.28.226.53 80]
Err:9 http://mirrors.aliyun.com/debian stretch-backports Release
404 Not Found [IP: 60.28.226.53 80]
Reading package lists... Done
E: The repository 'http://mirrors.aliyun.com/debian stretch 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.
E: The repository 'http://mirrors.aliyun.com/debian-security stretch/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.
E: The repository 'http://mirrors.aliyun.com/debian stretch-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.
E: The repository 'http://mirrors.aliyun.com/debian stretch-backports 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.

【成功】::::這里我更換了阿里的第二種成功

#Aliyun Apt Source 阿里云鏡像源
echo "deb http://mirrors.aliyun.com/debian/ bullseye main contrib" >> /etc/apt/sources.list
echo "deb-src http://mirrors.aliyun.com/debian/ bullseye main contrib" >> /etc/apt/sources.list
echo "deb http://mirrors.aliyun.com/debian/ bullseye-updates main contrib" >> /etc/apt/sources.list
echo "deb-src http://mirrors.aliyun.com/debian/ bullseye-updates main contrib" >> /etc/apt/sources.list
echo "deb http://mirrors.aliyun.com/debian/ bullseye-backports main contrib" >> /etc/apt/sources.list
echo "deb-src http://mirrors.aliyun.com/debian/ bullseye-backports main contrib" >> /etc/apt/sources.list
echo "deb http://mirrors.aliyun.com/debian/ bullseye-proposed-updates main contrib" >> /etc/apt/sources.list
echo "deb-src http://mirrors.aliyun.com/debian/ bullseye-proposed-updates main contrib" >> /etc/apt/sources.list
root@a7e7ebb2ecad:/# apt-get update
Get:1 http://mirrors.aliyun.com/debian bullseye InRelease [116 kB]
Get:2 http://mirrors.aliyun.com/debian bullseye-updates InRelease [44.1 kB]           
Get:3 http://mirrors.aliyun.com/debian bullseye-backports InRelease [49.0 kB]
Get:4 http://apt.postgresql.org/pub/repos/apt bullseye-pgdg InRelease [116 kB]
Get:5 http://mirrors.aliyun.com/debian bullseye-proposed-updates InRelease [54.0 kB]
Get:6 http://mirrors.aliyun.com/debian bullseye/contrib Sources [43.2 kB]
Get:7 http://mirrors.aliyun.com/debian bullseye/main Sources [8,637 kB]        
Get:8 http://mirrors.aliyun.com/debian bullseye/main amd64 Packages [8,183 kB]
Get:9 http://mirrors.aliyun.com/debian bullseye/contrib amd64 Packages [50.6 kB]
Get:10 http://mirrors.aliyun.com/debian bullseye-updates/main Sources [4,812 B]
Get:11 http://mirrors.aliyun.com/debian bullseye-updates/main amd64 Packages [14.6 kB]
Get:12 http://mirrors.aliyun.com/debian bullseye-backports/main Sources [429 kB]
Get:13 http://mirrors.aliyun.com/debian bullseye-backports/contrib Sources [4,280 B]
Get:14 http://mirrors.aliyun.com/debian bullseye-backports/main amd64 Packages [419 kB]
Get:15 http://mirrors.aliyun.com/debian bullseye-backports/contrib amd64 Packages [5,692 B]
Get:16 http://mirrors.aliyun.com/debian bullseye-proposed-updates/main Sources [8,072 B]
Get:17 http://mirrors.aliyun.com/debian bullseye-proposed-updates/main amd64 Packages [29.3 kB]
Fetched 18.2 MB in 6s (2,999 kB/s)                                                                                                                                                              
Reading package lists... Done

完整步驟

1:備份配置

cp /etc/apt/sources.list /etc/apt/sources.list.bak

2:修改配置

# Aliyun Apt Source 阿里云鏡像源
echo "deb http://mirrors.aliyun.com/debian/ bullseye main contrib" >> /etc/apt/sources.list
echo "deb-src http://mirrors.aliyun.com/debian/ bullseye main contrib" >> /etc/apt/sources.list
echo "deb http://mirrors.aliyun.com/debian/ bullseye-updates main contrib" >> /etc/apt/sources.list
echo "deb-src http://mirrors.aliyun.com/debian/ bullseye-updates main contrib" >> /etc/apt/sources.list
echo "deb http://mirrors.aliyun.com/debian/ bullseye-backports main contrib" >> /etc/apt/sources.list
echo "deb-src http://mirrors.aliyun.com/debian/ bullseye-backports main contrib" >> /etc/apt/sources.list
echo "deb http://mirrors.aliyun.com/debian/ bullseye-proposed-updates main contrib" >> /etc/apt/sources.list
echo "deb-src http://mirrors.aliyun.com/debian/ bullseye-proposed-updates main contrib" >> /etc/apt/sources.list

3:檢查配置

cat /etc/apt/sources.list

4:執(zhí)行:apt-get update

5:執(zhí)行:apt-get install -y vim

6:驗(yàn)證

vim /etc/hosts

參考資料:

https://blog.csdn.net/yimaoya/article/details/125345414
https://blog.csdn.net/peng2hui1314/article/details/113247648

到此這篇關(guān)于docker容器無(wú)法執(zhí)行vim的文章就介紹到這了,更多相關(guān)docker容器無(wú)法執(zhí)行vim內(nèi)容請(qǐng)搜索腳本之家以前的文章或繼續(xù)瀏覽下面的相關(guān)文章希望大家以后多多支持腳本之家!

相關(guān)文章

  • 深入解析docker三種網(wǎng)絡(luò)模式

    深入解析docker三種網(wǎng)絡(luò)模式

    這篇文章主要介紹了docker三種網(wǎng)絡(luò)模式,分別是bridge橋接模式,host主機(jī)模式,none無(wú)網(wǎng)絡(luò)模式,每種模式給大家介紹的非常詳細(xì),需要的朋友可以參考下
    2022-04-04
  • docker 安裝 php-fpm 服務(wù) / 擴(kuò)展 / 配置的示例教程詳解

    docker 安裝 php-fpm 服務(wù) / 擴(kuò)展 / 配置的示例教程詳解

    這篇文章主要介紹了docker 安裝 php-fpm 服務(wù) / 擴(kuò)展 / 配置,本文通過(guò)實(shí)例代碼給大家介紹的非常詳細(xì),對(duì)大家的學(xué)習(xí)或工作具有一定的參考借鑒價(jià)值,需要的朋友可以參考下
    2020-05-05
  • Docker部署web項(xiàng)目的實(shí)現(xiàn)

    Docker部署web項(xiàng)目的實(shí)現(xiàn)

    這篇文章主要介紹了Docker部署web項(xiàng)目的實(shí)現(xiàn),文中通過(guò)示例代碼介紹的非常詳細(xì),對(duì)大家的學(xué)習(xí)或者工作具有一定的參考學(xué)習(xí)價(jià)值,需要的朋友們下面隨著小編來(lái)一起學(xué)習(xí)學(xué)習(xí)吧
    2020-10-10
  • Linux下docker安裝mysql8并配置遠(yuǎn)程連接

    Linux下docker安裝mysql8并配置遠(yuǎn)程連接

    本文主要介紹了Linux下docker安裝mysql8并配置遠(yuǎn)程連接,文中通過(guò)示例代碼介紹的非常詳細(xì),對(duì)大家的學(xué)習(xí)或者工作具有一定的參考學(xué)習(xí)價(jià)值,需要的朋友們下面隨著小編來(lái)一起學(xué)習(xí)學(xué)習(xí)吧
    2022-07-07
  • docker 學(xué)習(xí)筆記之docker連接網(wǎng)絡(luò)的設(shè)置

    docker 學(xué)習(xí)筆記之docker連接網(wǎng)絡(luò)的設(shè)置

    本篇文章主要介紹了docker 學(xué)習(xí)筆記之docker連接網(wǎng)絡(luò)的設(shè)置 ,小編覺(jué)得挺不錯(cuò)的,現(xiàn)在分享給大家,也給大家做個(gè)參考。一起跟隨小編過(guò)來(lái)看看吧
    2017-02-02
  • docker-registry使用筆記

    docker-registry使用筆記

    在國(guó)內(nèi)docker-hub是肯定用不了的,不解釋:所以最好還是建一個(gè)私有的docker-registry,存儲(chǔ)一些常用的images方便隨時(shí)pull
    2016-09-09
  • Docker搭建Redis5.0并掛載數(shù)據(jù)

    Docker搭建Redis5.0并掛載數(shù)據(jù)

    本文主要介紹了Docker搭建Redis5.0并掛載數(shù)據(jù),文中通過(guò)示例代碼介紹的非常詳細(xì),需要的朋友們下面隨著小編來(lái)一起學(xué)習(xí)學(xué)習(xí)吧
    2021-07-07
  • Docker開(kāi)啟安全的TLS遠(yuǎn)程連接訪問(wèn)方式

    Docker開(kāi)啟安全的TLS遠(yuǎn)程連接訪問(wèn)方式

    本篇文章給大家介紹Docker開(kāi)啟安全的TLS遠(yuǎn)程連接,重新加載docker配置方法,教大家如何建立基于TLS數(shù)字簽名的安全連接,本文給大家介紹的非常詳細(xì),需要的朋友可以參考下
    2022-01-01
  • Docker使用Dockerfile創(chuàng)建支持ssh服務(wù)自啟動(dòng)的容器鏡像

    Docker使用Dockerfile創(chuàng)建支持ssh服務(wù)自啟動(dòng)的容器鏡像

    這篇文章主要介紹了Docker使用Dockerfile創(chuàng)建支持ssh服務(wù)自啟動(dòng)的容器鏡像,需要的朋友可以參考下
    2016-10-10
  • Docker之限制容器的資源使用過(guò)程

    Docker之限制容器的資源使用過(guò)程

    這篇文章主要介紹了Docker之限制容器的資源使用過(guò)程,具有很好的參考價(jià)值,希望對(duì)大家有所幫助,如有錯(cuò)誤或未考慮完全的地方,望不吝賜教
    2024-07-07

最新評(píng)論

拉萨市| 高密市| 台湾省| 长子县| 龙江县| 虎林市| 盖州市| 平湖市| 广丰县| 上思县| 板桥市| 蒙山县| 邵东县| 阿鲁科尔沁旗| 云林县| 灵武市| 陆河县| 白沙| 姚安县| 湘阴县| 昌黎县| 理塘县| 铁岭市| 天水市| 兴隆县| 同仁县| 寿宁县| 永平县| 和林格尔县| 社会| 子长县| 定日县| 丘北县| 瑞丽市| 肥乡县| 德州市| 建昌县| 博兴县| 大关县| 卫辉市| 田阳县|