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

Push to dockerhub #63

Merged
merged 16 commits into from
Mar 21, 2022
Merged

Push to dockerhub #63

merged 16 commits into from
Mar 21, 2022

Conversation

jburel
Copy link
Member

@jburel jburel commented Mar 14, 2022

https://hub.docker.com/r/openmicroscopy/omero-web/ and https://hub.docker.com/r/openmicroscopy/omero-web-standalone/ have not been updated since the release of omero-web 5.11
This PR automatically will push to dockerhub when a tag is pushed to this repo

cc @sbesson @will-moore

Tested using my account see https://hub.docker.com/r/jburel/omero-web/ and https://hub.docker.com/r/jburel/omero-web-standalone

@sbesson
Copy link
Member

sbesson commented Mar 14, 2022

I assume the tag still must be created using https://github.com/ome/omero-web-docker/blob/master/Makefile i.e. replacing the variables and effectively, this replaces the docker-build and docker-push steps?

@jburel
Copy link
Member Author

jburel commented Mar 14, 2022

The tag needs to be created and pushed cf. description. The changes follow a similar approach that the one taken in omero-server-docker and replace docker-build/push
Another option could be to post an event from omero-web when a tag is pushed and listen to that event here but it is outside the scope of this PR

Copy link
Member

@sbesson sbesson left a comment

Choose a reason for hiding this comment

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

The images pushed to https://hub.docker.com/r/jburel/omero-web/tags and https://hub.docker.com/r/jburel/omero-web-standalone/tags have exactly the same checksums and sizes. I assume the build step needs to specify which Dockerfile should be used for each image, which in turn might speak for creating two upload workflows rather than combining them into one.

@jburel
Copy link
Member Author

jburel commented Mar 15, 2022

I realised that afterwards. I am going to slip things up

@jburel
Copy link
Member Author

jburel commented Mar 16, 2022

Copy link
Member

@sbesson sbesson left a comment

Choose a reason for hiding this comment

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

The updated logic makes sense although I haven't functionally tested the generated images. Getting it in will certainly automate part of the update of these images and reduce the manual load.

I share some of the re-usability concerns expressed here and in #64 (comment). In the case of these images. I assume the only way to reduce the customization of the workflow would be to extract the standalone Docker files into its own repository.

@jburel
Copy link
Member Author

jburel commented Mar 18, 2022

As indicated previously during discussion, web-standalone should be extracted so we can push a new version each time a new web app included in the standalone image is released.
When that is done, we can have a reusable workflow i.e. omero-server-docker and omero-web-docker will follow a similar pattern

@sbesson
Copy link
Member

sbesson commented Mar 18, 2022

As indicated previously during discussion, web-standalone should be extracted so we can push a new version each time a new web app included in the standalone image is released.

But the extraction will break the workflow that is proposed in this PR. So I guess the question is whether we want to extrac first or capture as an issue and come back to it?

@jburel
Copy link
Member Author

jburel commented Mar 18, 2022

If we extract, of course the workflow will need to be reviewed. The proposed changes automate the build/push of the images.
I think we can extract afterwards and adjust accordingly

@jburel
Copy link
Member Author

jburel commented Mar 18, 2022

#53 already captures the release of apps problem. i did not notice the issue

@jburel
Copy link
Member Author

jburel commented Mar 18, 2022

The commit 6d985b7 adds labels cf. in ome/omero-server-docker#57. More labels than the 3 current listed in the Dockerfile are added.

List of labels:

org.opencontainers.image.title=omero-web-docker
  org.opencontainers.image.description= OMERO.web production docker image
  org.opencontainers.image.url=https://github.com/***/omero-web-docker
  org.opencontainers.image.source=https://github.com/***/omero-web-docker
  org.opencontainers.image.version=5.13.0-15
  org.opencontainers.image.created=2022-03-18T11:40:23.[34](https://github.com/jburel/omero-web-docker/runs/5599778430?check_suite_focus=true#step:3:34)5Z
  org.opencontainers.image.revision=6d985b7284edacba4f3d094d43ddeb3c[39](https://github.com/jburel/omero-web-docker/runs/5599778430?check_suite_focus=true#step:3:39)73075f
  org.opencontainers.image.licenses=

@jburel
Copy link
Member Author

jburel commented Mar 18, 2022

Copy link
Member

@sbesson sbesson left a comment

Choose a reason for hiding this comment

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

(base) [sbesson@idr2-slot3 ~]$ docker pull jburel/omero-web:latest && docker inspect jburel/omero-web:latest | grep opencon
latest: Pulling from jburel/omero-web
Digest: sha256:e55b1e767779aa51517d979a2c8482ee83eea16e406d149ea376abae5966eeeb
Status: Image is up to date for jburel/omero-web:latest
docker.io/jburel/omero-web:latest
                "org.opencontainers.image.created": "2022-03-18T11:40:23.345Z",
                "org.opencontainers.image.description": " OMERO.web production docker image",
                "org.opencontainers.image.licenses": "",
                "org.opencontainers.image.revision": "6d985b7284edacba4f3d094d43ddeb3c3973075f",
                "org.opencontainers.image.source": "https://github.com/jburel/omero-web-docker",
                "org.opencontainers.image.title": "omero-web-docker",
                "org.opencontainers.image.url": "https://github.com/jburel/omero-web-docker",
                "org.opencontainers.image.vendor": "CentOS",
                "org.opencontainers.image.version": "5.13.0-15"
(base) [sbesson@idr2-slot3 ~]$ docker pull jburel/omero-web-standalone:latest && docker inspect jburel/omero-web-standalone:latest  | grep opencon
latest: Pulling from jburel/omero-web-standalone
Digest: sha256:eafffcf657c150dcaf1c715c62872fa379750f461100a9bb7fcd3046149e0025
Status: Image is up to date for jburel/omero-web-standalone:latest
docker.io/jburel/omero-web-standalone:latest
                "org.opencontainers.image.created": "2022-03-18T11:40:23.345Z",
                "org.opencontainers.image.description": " OMERO.web production docker image",
                "org.opencontainers.image.licenses": "",
                "org.opencontainers.image.revision": "6d985b7284edacba4f3d094d43ddeb3c3973075f",
                "org.opencontainers.image.source": "https://github.com/jburel/omero-web-docker",
                "org.opencontainers.image.title": "omero-web-docker",
                "org.opencontainers.image.url": "https://github.com/jburel/omero-web-docker",
                "org.opencontainers.image.vendor": "CentOS",
                "org.opencontainers.image.version": "5.13.0-15"

Looks good. Can you clean up the corresponding LABEL statements from the Dockerfile for both images?

The redundancy of org.opencontainers.image.title and other metadata is probably an indicator that we will need to extract the standalone image eventually

@jburel
Copy link
Member Author

jburel commented Mar 21, 2022

@sbesson I have cleaned up the LABEL.
It will be good to have this PR merged before deploying omero-web so I can tag with a 5.13 web then a Django upgrade image.

Copy link
Member

@sbesson sbesson left a comment

Choose a reason for hiding this comment

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

There are a few potential follow-ups mentioned in the thread worth capturing as issues but otherwise I am fine for this to get merged to start making incremental improvement of our deployment workflow

@@ -34,8 +34,6 @@ ifndef VERSION
endif

perl -i -pe 's/OMERO_VERSION=(\S+)/OMERO_VERSION=$(VERSION)/' Dockerfile
Copy link
Member

Choose a reason for hiding this comment

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

Since I cannot spot any OMERO_VERSION left in Dockerfile, these changes might make the Makefile irrelevant and it can probably cleaned up as a follow-up.

Copy link
Member Author

Choose a reason for hiding this comment

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

I could not spot it but I kept it "just in case"
With the automation option proposed in another PR, the Makefile will become totally irrelevant

This was referenced Mar 21, 2022
@jburel jburel merged commit 9f85a7d into ome:master Mar 21, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants