4 Commits

Author SHA1 Message Date
Armel Soro
8c2c633755 Fix rpminspect specname inspection failure (#6241)
To anticipate the sunsetting of rpmdiff (replaced by rpminspect), this
makes sure that the odo RPM package passes rpminspect's inspections.
The only error reported at this time was about an invalid spec
filename.

```
specname:
---------
1) Spec filename does not exactly match the primary name odo; got
'openshift-odo.spec'

Result: BAD
Waiver Authorization: Not Waivable

Suggested Remedy: The spec file name does not match the expected
NAME.spec
format.  Rename the spec file to conform to this policy.
```

See
https://docs.google.com/document/d/1PolwQHoZzf0oeOUN1IK7T_NDRAay-nurwL0xYj2JuOo/edit#
for more details.
2022-11-02 10:40:41 -04:00
Mohammed Ahmed
4305079156 Cleaning up odo rpm spec and scripts (#3904)
* Fixing rpm spec Provides and Obsoletes to be more specific

Signed-off-by: Mohammed Zeeshan Ahmed <mohammed.zee1000@gmail.com>

* Fixing local build script to use dist/rpmbuild and topdir for build

 - This prevents polluting users main rpmbuild

Signed-off-by: Mohammed Zeeshan Ahmed <mohammed.zee1000@gmail.com>

* Setting goflags during `make test` and turning off missing buildid

 - without goflags, unit tests take a while as they dont use vendor
 - providing -mod=vendor does not seem to help
 - missing gnu build ids in go binaries can cause warnings

Signed-off-by: Mohammed Zeeshan Ahmed <mohammed.zee1000@gmail.com>

* Removing GOFLAGS from spec and adding build_flags to test target

Signed-off-by: Mohammed Zeeshan Ahmed <mohammed.zee1000@gmail.com>

* Unsetting any goflags for make test in openshift ci

Signed-off-by: Mohammed Zeeshan Ahmed <mohammed.zee1000@gmail.com>

* Removing the set +x from local build script

Signed-off-by: Mohammed Zeeshan Ahmed <mohammed.zee1000@gmail.com>

* Adding rpm tests

Signed-off-by: Mohammed Zeeshan Ahmed <mohammed.zee1000@gmail.com>

* Removing last rm -rf

Signed-off-by: Mohammed Zeeshan Ahmed <mohammed.zee1000@gmail.com>

* Reverting to explicitly setting GOFLAGS for make test

 - It appears that while `-mod=vendor` flag is available for `go test`
   it is sometimes not respected
 - It is therefore, better to just set GOFLAGS only for make test
 - More investigation is needed to find better solution, but we should
   not break stuff relation to testing and release, where we should not
   be pulling from outside world

Signed-off-by: Mohammed Zeeshan Ahmed <mohammed.zee1000@gmail.com>

* Cleaning up rpm-prepare

Signed-off-by: Mohammed Zeeshan Ahmed <mohammed.zee1000@gmail.com>

* Removing unnessasary newline

Signed-off-by: Mohammed Zeeshan Ahmed <mohammed.zee1000@gmail.com>

* Adding version file to spec for any future automation to have easier time

Signed-off-by: Mohammed Zeeshan Ahmed <mohammed.zee1000@gmail.com>
2020-09-10 11:55:19 -04:00
Mohammed Ahmed
46b512ee21 Building redistributable only on x86_64 and updating golang version to 1.13 (#3464)
* Building redistributable only on x86_64

We dont need redistributable package building
on multiple architectures as it is happening right
now (case in point internal scratch build)

Eg:
  - openshift-odo-redistributable-1.2.3-1.el8.s390x.rpm
  - openshift-odo-redistributable-1.2.3-1.el8.ppc64le.rpm
  - openshift-odo-redistributable-1.2.3-1.el8.x86_64.rpm

We only need last one as individual rpms for specific architectures
is fine but not the redistributable ones.

Signed-off-by: Mohammed Zeeshan Ahmed <mohammed.zee1000@gmail.com>

* Updating golang version to 1.13

Signed-off-by: Mohammed Zeeshan Ahmed <mohammed.zee1000@gmail.com>
2020-07-08 22:59:10 +02:00
Mohammed Ahmed
567ad811de Setting up rpm spec for odo for rpm build (#2107)
* Setting up rpm spec for odo for rpm build

Signed-off-by: Mohammed Zeeshan Ahmed <mohammed.zee1000@gmail.com>

* Fixing typo

* Printing envs for debugging

* Removing -rpm suffix for rpm target

* Update rpm prepare script to store version information alongside rpmbuild artifacts

* Adding script to create tarball of the source. To be run after rpm-prepare is done

* Fixing dist git tarball generator

Signed-off-by: Mohammed Zeeshan Ahmed <mohammed.zee1000@gmail.com>

* Removing script from commit as its not yet perfect

* Updating redistributable to use name-redistributable

* Removing version replacement in version.go

* Some minor fixes to spec and script

* Record the need to update version in rpm-prepare script into release process

* Renaming atomic-openshift-odo to openshift-odo
2019-09-20 16:59:19 +02:00