Am not able to install microk8 on amazon linux or red hat , the snapd package can't download

Am working on a project to run a ci-cd pipeline , am using amazon linux 2 then switch to Red hat, still unable to install microk8s ,when i run : yum -y install snapd

i get the below message :

[ec2-user@ip-172-31-18-77 ~]$ yum -y install snapd
Loaded plugins: extras_suggestions, langpacks, priorities, update-motd
You need to be root to perform this command.
[ec2-user@ip-172-31-18-77 ~]$ sudo yum -y install snapd
Loaded plugins: extras_suggestions, langpacks, priorities, update-motd
amzn2-core | 3.7 kB 00:00
amzn2extra-docker | 3.0 kB 00:00
amzn2extra-kernel-5.10 | 3.0 kB 00:00
No package snapd available.
Error: Nothing to do
[ec2-user@ip-172-31-18-77 ~]$

i need a work around ,any suggestion will help

Hi @ndefrutitus22,

snapd isn’t in the default repos for Red Hat.

You need to install the EPEL repo as described here:

Not sure what the steps are for Amazon Linux, but they should be similar.