openshift-online/ocm-cli

.sha256 files contain different file names than the corresponding binary file in release 0.1.58

grdryn opened this issue · 3 comments

Up to release 0.1.56, the <file>.sha256 contained the output of sha256 sum run on the corresponding binary file name from the release page. E.g.

$ cat ocm-linux-amd64.sha256 
48b7c7270793493f0c6603f54ae9143797602a206b80a1860a1b51392ba55fb1  ocm-linux-amd64

In release 0.1.58, Each of those files contains the sha256sum output of the corresponding file, but the file name is just ocm rather than ocm-linux-amd64:

$ cat ocm-linux-amd64.sha256 
8700beaec0c67c7699a55c80d526e1175bc80b6c5524b014ff44f62132ebef61  ocm

This isn't a huge issue, and you might have good reasons for doing it. It does, however, appear to break the checksum parameter's auto-checking in the Ansible get_url module. E.g.:

  - name: "Download ocm version {{ ocm_version }}"
    get_url:
      url: "https://github.com/openshift-online/ocm-cli/releases/download/v{{ ocm_version }}/ocm-linux-amd64"
      dest: "/home/gryan/bin/ocm"
      checksum: "sha256:https://github.com/openshift-online/ocm-cli/releases/download/v{{ ocm_version }}/ocm-linux-amd64.sha256"
      owner: "gryan"
      group: "gryan"
      mode: 0755

There are no good reasons for this, it is just a bug in the build script. I am fixing it.

The issue in the build script has been fixed in #324, so next release will have the correct .sha256 files. I have also manually fixed the .sha256 files in release 0.1.58.

Thanks a lot @jhernand!