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

Fix debian OS determination #193

Merged
merged 1 commit into from
Feb 21, 2018
Merged

Conversation

jturel
Copy link
Contributor

@jturel jturel commented Feb 20, 2018

Running Transaction                             
  Installing : katello-ca-consumer-centos7-dev2.strangeways.example.com-1.0-1.noarch                                                                                                           1/1 
sed: can't read /etc/os-release: No such file or directory                                       
warning: %post(katello-ca-consumer-centos7-dev2.strangeways.example.com-1.0-1.noarch) scriptlet failed, exit status 2                                                                              
Non-fatal POSTIN scriptlet failure in rpm package katello-ca-consumer-centos7-dev2.strangeways.example.com-1.0-1.noarch                                                                              Verifying  : katello-ca-consumer-centos7-dev2.strangeways.example.com-1.0-1.noarch                                                                                                           1/1 

Installed:                                      
  katello-ca-consumer-centos7-dev2.strangeways.example.com.noarch 0:1.0-1 

Hmm, what happened?

[root@rhel6 vagrant]# katello-rhsm-consumer
sed: can't read /etc/os-release: No such file or directory

Ah! We don't have os-release in EL6.. I think I've fixed it. I also corrected the regex by adding a '^' in front of 'ID' since it was matching too much.

@jturel
Copy link
Contributor Author

jturel commented Feb 20, 2018

@mdellweg you might wanna confirm my regex change :)

@mdellweg
Copy link
Member

Looks good. If you like, you can also add $ to the end of the regex to be really sure.

@ekohl
Copy link
Member

ekohl commented Feb 20, 2018

Looks good. If you like, you can also add $ to the end of the regex to be really sure.

Isn't that a bit redundant with a greedy regex?

@mdellweg
Copy link
Member

Sure. I tend to forget, which regex implementations are greedy, and this redundancy might not hurt. But i'm fine with either ways.

Copy link
Member

@sean797 sean797 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @jturel 👍

Copy link
Member

@ekohl ekohl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should this be merged then @mdellweg?

@mdellweg
Copy link
Member

@ekohl I'm fine.

Sorry for breaking CentOS6 in the first place.

@sean797 sean797 merged commit c5d6d12 into theforeman:master Feb 21, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants