voxpupuli / puppet-yum

Puppet module for Yum
https://forge.puppet.com/puppet/yum
MIT License
16 stars 101 forks source link

Support Amazon Linux 2 #164

Open vchepkov opened 4 years ago

vchepkov commented 4 years ago

Amazon Linux 2 is compatible with EL7, not EL6

# facter os
{
  architecture => "x86_64",
  family => "RedHat",
  hardware => "x86_64",
  name => "Amazon",
  release => {
    full => "2",
    major => "2"
  },
  selinux => {
    enabled => false
  }
}
vchepkov commented 4 years ago
# cat amzn2-core.repo 
[amzn2-core]
name=Amazon Linux 2 core repository
mirrorlist=http://amazonlinux.$awsregion.$awsdomain/$releasever/$product/$target/$basearch/mirror.list
priority=10
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-amazon-linux-2
enabled=1
metadata_expire=300
mirrorlist_expire=300
report_instanceid=yes

[amzn2-core-source]
name=Amazon Linux 2 core repository - source packages
mirrorlist=http://amazonlinux.$awsregion.$awsdomain/$releasever/$product/$target/SRPMS/mirror.list
priority=10
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-amazon-linux-2
enabled=0
metadata_expire=300
mirrorlist_expire=300
report_instanceid=yes

[amzn2-core-debuginfo]
name=Amazon Linux 2 core repository - debuginfo packages
mirrorlist=http://amazonlinux.$awsregion.$awsdomain/$releasever/$product/$target/debuginfo/$basearch/mirror.list
priority=10
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-amazon-linux-2
enabled=0
metadata_expire=300
mirrorlist_expire=300
report_instanceid=yes
# cat amzn2-extras.repo 

[amzn2extra-docker-source]
enabled = 0
name = Amazon Extras source repo for docker
mirrorlist = http://amazonlinux.$awsregion.$awsdomain/$releasever/extras/docker/latest/SRPMS/mirror.list
gpgcheck = 1
gpgkey = file:///etc/pki/rpm-gpg/RPM-GPG-KEY-amazon-linux-2
priority = 10

[amzn2extra-docker-debuginfo]
enabled = 0
name = Amazon Extras debuginfo repo for docker
mirrorlist = http://amazonlinux.$awsregion.$awsdomain/$releasever/extras/docker/latest/debuginfo/$basearch/mirror.list
gpgcheck = 1
gpgkey = file:///etc/pki/rpm-gpg/RPM-GPG-KEY-amazon-linux-2
priority = 10

[amzn2extra-docker]
enabled = 1
name = Amazon Extras repo for docker
mirrorlist = http://amazonlinux.$awsregion.$awsdomain/$releasever/extras/docker/latest/$basearch/mirror.list
gpgcheck = 1
gpgkey = file:///etc/pki/rpm-gpg/RPM-GPG-KEY-amazon-linux-2
priority = 10
vchepkov commented 4 years ago

extras repo are managed using amazon-linux-extras command, so maybe it should be left alone