diff --git a/tomcat/native.sls b/tomcat/native.sls index 75482654ff504123b76f1401ce5bf3736542adcc..b292f744b2e731f93c8088ae261689f1299a83d3 100644 --- a/tomcat/native.sls +++ b/tomcat/native.sls @@ -4,6 +4,18 @@ include: - tomcat.config tomcat {{ tomcat.native_pkg }}: + {%- if grains.get('osfinger', '') == 'Amazon Linux-2' %} + pkgrepo.managed: + - name: epel + - humanname: Extra Packages for Enterprise Linux 7 - $basearch + - mirrorlist: https://mirrors.fedoraproject.org/metalink?repo=epel-7&arch=$basearch + - enabled: 1 + - gpgcheck: 1 + - gpgkey: https://dl.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-7 + - failovermethod: priority + - require_in: + - pkg: tomcat {{ tomcat.native_pkg }} + {%- endif %} pkg.installed: - name: {{ tomcat.native_pkg }}