Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CloudLinux 7 Support #7

Open
paulie51 opened this issue Mar 16, 2020 · 0 comments
Open

CloudLinux 7 Support #7

paulie51 opened this issue Mar 16, 2020 · 0 comments

Comments

@paulie51
Copy link

The fix for Centos 7 support (this issue : #5 ) doesn't work for CloudLinux 7 due to the test in apm.sh failing for CloudLinux 7 , specifically this line :

if [ $(rpm -q --qf "%{VERSION}" $(rpm -q --whatprovides redhat-release)) -eq 7 ]

Output on Centos7 : 7

Output on CloudLinux7 : 7.7

One option to fix is to change the if to use [[ ]] and regex :

if [[ $(rpm -q --qf "%{VERSION}" $(rpm -q --whatprovides redhat-release)) =~ ^7 ]]

To cover Centos 7 and CloudLinux 7 (and minor versions going forwards).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant