[root@mycloudhost yum.repos.d]# cat AliYun.repo ## Note, this file is written by cloud-init on first boot of an instance ## modifications made here will not survive a re-bundle. ## if you wish to make changes you can: ## a.) do the same in user-data ## b.) add sources in /etc/yum.repos.d/ ## c.) make changes to template file /etc/cloud/templates/sources.list.aliyun.tmpl ### # AliYun.repo [base] name=AliYun-$releasever - Base - mirrors.aliyun.com baseurl=http://mirrors.cloud.aliyuncs.com/alinux/$releasever/os/$basearch/ gpgcheck=1 gpgkey=http://mirrors.cloud.aliyuncs.com/alinux/RPM-GPG-KEY-ALIYUN #released updates [updates] name=AliYun-$releasever - Updates - mirrors.aliyun.com baseurl=http://mirrors.cloud.aliyuncs.com/alinux/$releasever/updates/$basearch/ gpgcheck=1 gpgkey=http://mirrors.cloud.aliyuncs.com/alinux/RPM-GPG-KEY-ALIYUN #additional packages that may be useful [extras] name=AliYun-$releasever - Extras - mirrors.aliyun.com baseurl=http://mirrors.cloud.aliyuncs.com/alinux/$releasever/extras/$basearch/ gpgcheck=1 gpgkey=http://mirrors.cloud.aliyuncs.com/alinux/RPM-GPG-KEY-ALIYUN # plus packages provided by Aliyun Linux dev team [plus] name=AliYun-$releasever - Plus - mirrors.aliyun.com baseurl=http://mirrors.cloud.aliyuncs.com/alinux/$releasever/plus/$basearch/ gpgcheck=1 gpgkey=http://mirrors.cloud.aliyuncs.com/alinux/RPM-GPG-KEY-ALIYUN[root@mycloudhost yum.repos.d]# [root@mycloudhost yum.repos.d]# [root@mycloudhost yum.repos.d]# [root@mycloudhost yum.repos.d]# [root@mycloudhost yum.repos.d]# cat epel.repo ## Note, this file is written by cloud-init on first boot of an instance ## modifications made here will not survive a re-bundle. ## if you wish to make changes you can: ## a.) do the same in user-data ## b.) add sources in /etc/yum.repos.d/ ## c.) make changes to template file /etc/cloud/templates/sources.list.aliyun.epel.tmpl ### [epel] name=Extra Packages for Enterprise Linux 7 - $basearch baseurl=http://mirrors.cloud.aliyuncs.com/epel/7/$basearch failovermethod=priority enabled=1 gpgcheck=1 gpgkey=http://mirrors.cloud.aliyuncs.com/epel/RPM-GPG-KEY-EPEL-7 [epel-debuginfo] name=Extra Packages for Enterprise Linux 7 - $basearch - Debug baseurl=http://mirrors.cloud.aliyuncs.com/epel/7/$basearch/debug failovermethod=priority enabled=0 gpgkey=http://mirrors.cloud.aliyuncs.com/epel/RPM-GPG-KEY-EPEL-7 gpgcheck=1 [epel-source] name=Extra Packages for Enterprise Linux 7 - $basearch - Source baseurl=http://mirrors.cloud.aliyuncs.com/epel/7/SRPMS failovermethod=priority enabled=0 gpgkey=http://mirrors.cloud.aliyuncs.com/epel/RPM-GPG-KEY-EPEL-7 gpgcheck=1
原文:https://www.cnblogs.com/yzg-14/p/13961393.html