Awx: Build under CentOS fails with: unknown option `first-parent'

Created on 15 Jan 2018  路  15Comments  路  Source: ansible/awx

ISSUE TYPE
  • Bug Report
COMPONENT NAME
  • Installer
SUMMARY

Build fails with:

error: unknown option `first-parent'
usage: git describe [options] *
or: git describe [options] --dirty

--contains            find the tag that comes after the commit
--debug               debug search strategy on stderr
--all                 use any ref
--tags                use any tag, even unannotated
--long                always use long format
--abbrev[=<n>]        use <n> digits to display SHA-1s
--exact-match         only output exact matches
--candidates <n>      consider <n> most recent tags (default: 10)
--match <pattern>     only consider tags matching <pattern>
--always              show abbreviated commit object as fallback
--dirty[=<mark>]      append <mark> on dirty working tree (default: "-dirty")
#

Artifacts:
dist/awx-.tar.gz

This first happened in awx-1.0.2.372.. build need git 1.8.4 but only 1.8.3 is available in CentOS

installer bug

Most helpful comment

Well, Ansible belongs to red hat, Centos is open-source Red Hat and release 7 is the latest to date.
So I suppose Red Hat corp has all cards on hands to solve this.

All 15 comments

+1
Local build fails on CentOS 7.4.1708 (Core). A local build will also fail on RHEL 7.4
git --version returns 1.8.3.1

changing back commit #52e5316 works.... but this should be fixed in some way...

I've confirmed I'm also seeing this. Taking a look.

Yeah, looks like the git version needs to be >= 1.8.4

But that makes building on CentOS "impossible" .. Can't we change it to something that will be generic

Should be fixed with the merging of #1012

Instead of going with 3rd party "external" repos, has anyone considered utilizing Red Hat Software Collection Library? CentOS has access to the RHSCL via https://www.softwarecollections.org/en/scls/rhscl/rh-git29/
RH SCL's git for 2.9 is rh-git29-2.3-4.el7.x86_64.rpm (unless RH SCL is a PREMIUM subscription)

Good suggestion, I honestly didn't know about it until you mentioned it. It seems like a better choice for this.

One last off topic note, postgresql 9.6 is also part of the RHSCL (for RPM based installs).

Original issue fixed. Submit PR if there's something better.

It doesn't seem #1012 fixed the issue.
You change the git installed in the build image whereas the git used to compute awx_version is the local one.

I would just add the version requirement to the Install documentation.

Agree with @kwaio, issue is not resolved. One on Centos/RHEL7 should do the following steps to install newer git version:
yum install -y https://centos7.iuscommunity.org/ius-release.rpm
yum -y remove git
yum -y install git2u

It doesn't look like a good solution.

Agreed, not resolved @matburt @wwitzel3 @shanemcd

Recap the trail of destruction: https://github.com/ansible/awx/pull/982 https://github.com/ansible/awx/pull/987 https://github.com/ansible/awx/pull/1049 https://github.com/ansible/awx/pull/1037

Another issue was opened and summarily closed, same as this one: https://github.com/ansible/awx/issues/1045

This breaks development of AWX on CentOS. People are not going to enable the IUS repo to get a newer version. The reason for the original change is not clear in #982. I'd would be interested to know what the original problem was.

Could we consider reverting all of this and figuring out a better way to derive the tag from git describe in a way that is compatible with the version of git that is in the CentOS repos? I know plenty of other projects that derive a version/tag from git describe without this flag.

We totally did not add this flag for no reason.

We're tracking multiple release branches and Tower release branches. These follow a different versioning scheme (for good reason) than AWX itself. Since all of changes are coalescing into AWX as the upstream we need to be able to track our version number from the parent branch.

I'm open to other options, but we rely on this to generate version numbers across all of our release branches. Obviously if you are just tracking AWX you wouldn't run into this issue but for Tower maintenance we do.

The Tower and AWX source trees are the same and we're not interested in having divergent patches or branches, nor would the community want us to.

If you are installing from a system with an outdated git then you'll need to update per the install instructions. If you're building your own images or maintaining your own deployment mechanism then this is just going to have to be something you deal with. As I said, I'm open to other options or having RHEL/CentOS upgrade to a version of git that's newer than August 2013(!).

Well, Ansible belongs to red hat, Centos is open-source Red Hat and release 7 is the latest to date.
So I suppose Red Hat corp has all cards on hands to solve this.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

artmakh picture artmakh  路  3Comments

marshmalien picture marshmalien  路  3Comments

pebbledavec picture pebbledavec  路  3Comments

beenje picture beenje  路  3Comments

cs35-owncloud picture cs35-owncloud  路  3Comments