码迷,mamicode.com
首页 > 其他好文 > 详细

yum源的制作

时间:2019-10-29 21:50:19      阅读:87      评论:0      收藏:0      [点我收藏+]

标签:creat   repo   font   ado   har   pos   添加   http   tmp   

第一步:准备需要的安装包

[root@compute1 tmp]# mkdir -pv /tmp/soft
cd /tmp/soft
[root@compute1 soft]# ll /tmp/soft
total 0
[root@compute1 soft]# yum install nginx --downloadonly --downloaddir=/tmp/soft
[root@compute1 soft]# ll /tmp/soft

  

提示不能使用--downloadonly的请先安装yum-utils软件

[root@compute1 soft]# yum -y install yum-utils
利用yum的参数,进行只下载,不安装,同时会下载对应依赖的软件

自建仓库
将上述app复制到客户内网机器,假设目录为/usr/app

[root@iZ25vh2zuf2Z ~]# cd /usr/app
[root@iZ25vh2zuf2Z app]# createrepo ./
createrepo命令不存在的,可以yum install createrepo进行安装

这样自行仓库就建立完成,然后/etc/yum.repos.d/添加对应的配置文件

  

rm -fr /etc/httpd/conf.d/welcome.conf

cp 1/* /var/www/html/ 

 

yum源的制作

标签:creat   repo   font   ado   har   pos   添加   http   tmp   

原文地址:https://www.cnblogs.com/itzhao/p/11761466.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!