zoukankan      html  css  js  c++  java
  • 用docker 下载NGINX nginx安装错误:No package nginx available

    docker 内安装 nginx,提示

    解决方案:

    1,备份

    mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.backup

    2、下载新的CentOS-Base.repo 到/etc/yum.repos.d/

    复制代码
    centos 5
    
    wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-5.repo
    
    或者
    
    curl -o /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-5.repo
    
    centos 6
    
    wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-6.repo
    
    或者
    
    curl -o /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-6.repo
    
     centos 7
    
    wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo
    
    或者
    
    curl -o /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo
    复制代码

    3,运行 yum clean all

        yum makecache

    4,运行yum install epel-release 

    5,运行yum install nginx

  • 相关阅读:
    MemCached总结二:数据管理指令
    MemCached总结一:Unbutu操作系统下memcached服务器安装和telnet方式连接memcache
    Laravel5 开启Debug
    状压dp
    树形dp
    区间dp
    线性dp
    背包九讲
    dp求解各种子串子序列
    线段树详解
  • 原文地址:https://www.cnblogs.com/royfans/p/10964767.html
Copyright © 2011-2022 走看看