ome / openmicroscopy

OME (Open Microscopy Environment) develops open-source software and data format standards for the storage and manipulation of biological light microscopy data. A joint project between universities, research establishments and industry in Europe and the USA, OME has over 20 active researchers with strong links to the microscopy community. Funded by private and public research grants, OME has been a major force on the international microscopy stage since 2000.
https://www.openmicroscopy.org/omero
GNU General Public License v2.0
200 stars 102 forks source link

upload assets on tag #6318

Closed jburel closed 2 years ago

jburel commented 2 years ago

Follow up from 5.6.4 release. This PR adds steps to the build workflow to avoid the manual migration of the artifacts from downloads.o.org to GitHub.

The workflow does the following, When a tag is pushed:

I have opted for one single SHASUMS and MD5 collecting the various values to simplify the selection and reduce the number of uploaded files.

This can replaced the "release" job on CI

See https://github.com/jburel/openmicroscopy/releases/tag/v5.6.4-m1

sbesson commented 2 years ago

Immediate thoughts:

jburel commented 2 years ago
joshmoore commented 2 years ago

One thing to keep in mind that I went through with https://github.com/zarr-developers/zarr-logo/pull/2/commits is that on download things get automatically zipped.

Also: I can highly recommend experimenting with the gh release commands to make sure what's being upload and downloaded matches your expectations.

sbesson commented 2 years ago

Another component which I forgot to mention in my previous comment is our Ansible deployment stack especially ome.omero_server and the underlying omego library currently rely on the current https://downloads.openmicroscopy.org/omero layout and naming for retrieving the server artifacts. Amongst other, this proposal might force us to revisit https://github.com/ome/omego/pull/127 to download components directly from GitHub.

Something to think about is the breaking impact on deployment if a new library/role release or new scripts are required to upgrade a server. I don't consider it to be a blocker per se but it might lead us to a dedicated upgrade documentation page similar to what we did for the Python3 migration.

jburel commented 2 years ago

Reactivate that work

jburel commented 2 years ago

Add openmicroscopy-XXX.zipsee https://github.com/jburel/openmicroscopy/releases/tag/v5.6.5-m2

jburel commented 2 years ago

cf. https://github.com/ome/openmicroscopy/pull/6318#issuecomment-1113450540 Re-activated see https://github.com/ome/omego/pull/132.

jburel commented 2 years ago

A few inline comments and a couple of questions:

  • the new process seems to fully drop the build suffix. Is that on purpose and do we know whether this might cause impact downstream?

I can't get a build number as bXXXX is internal to our CI. The build is now happening in GHA.

sbesson commented 2 years ago

I can't get a build number as bXXXX is internal to our CI. The build is now happening in GHA.

I assume in the GitHub context github.run_id would be the closest equivalent. As mentioned above, I do not know of the impact of dropping the build. it An advantage is that would certainly make the download URL fully predictable from the OMERO.server version.

jburel commented 2 years ago

Using the job id is an option

jburel commented 2 years ago

https://github.com/jburel/openmicroscopy/releases/tag/v5.6.5-m3 using the run_id in the name This should match the convention currently used when the artifacts are built via Jenkins CI

jburel commented 2 years ago

Looking closely, I don't think the build number needs to be kept. I am also looking into improving https://github.com/ome/omego/pull/132 so we can pass major or major.minor so we can install the latest version from a major version without having to update the link

the usage of get_latest_runs will need to be reviewed. This is mainly (only!) used to retrieve a latest run from Jenkins latest.

jburel commented 2 years ago

Looking at another part, candidate for automation, not including the build number will allow to create the url by finding the latest release tag from the GitHub API . Including the build number will not permit that.

jburel commented 2 years ago
jburel commented 2 years ago

For the build number, it will be matter of adjusting a few places. If we agree, I will roll back and do not add the build number A rebuild will be happening by pushing a new tag. One downside of this approach is if we want to retract a release. For that eventually e.g. major releases, rc will be used or possible intermediate dev tags.

jburel commented 2 years ago

Last 2 commits

Tested via https://github.com/jburel/openmicroscopy/releases/tag/5.6.5-m5

jburel commented 2 years ago

Any more comments on this PR?

sbesson commented 2 years ago

Is the missing leading 5 in https://github.com/jburel/openmicroscopy/releases/tag/5.6.5-m5 on purpose?

jburel commented 2 years ago

oh. Let me check. That should not be the case.

Edit: This is because I did not tag with vX.X.X and I remove the first character i.e. tag_value="${tag_name:1}-ice36" I will add check if it starts with v to avoid such mistake

jburel commented 2 years ago

The last commit has been tested using 2 tags. One starting with v and one without v https://github.com/jburel/openmicroscopy/releases/tag/5.6.5-m7 https://github.com/jburel/openmicroscopy/releases/tag/v5.6.5-m6