-
Notifications
You must be signed in to change notification settings - Fork 170
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
Preserve snapshot version of images? #197
Comments
I'm not sure if there has been discussion about adding tags with a date in the name. I would recommend tagging the image that should remain frozen instead.
|
@sloretz Yes, actually in my team we're already tagging and pushing certain snapshot images to our own registry. With lack of mechanism for more complete coverage, we only have very specific versions of snapshots. I am wondering if it makes sense on a common repository (like this repo) to maintain such a mechanism to realize more snapshot version coverage. Maybe taking a snapshot per every public sync of each distro and push the image to the public registry. Having this will:
Building and tagging images by external trigger seems not complicated for hub.docker.com (e.g. this SO article) although I haven't tried yet. Having said these, I'm not sure how cost effective it is to have such a feature, but if there's enough support for the idea I'm willing to contribute. |
@130s , I suspect you would like to pin by its digest, or immutable identifier: Pull an image by digest (immutable identifier)
See this related comment here for more details: #104 (comment) If you to dig through the archives to trace back any particular build (or "snapshot"), you may want to check out the Extended Information repo for the docker library: docker-library/repo-info. Specifically, for ros: https://github.com/docker-library/repo-info/tree/master/repos/ros
In theory, I think the Using the repo above, you should be able recover the image digest that correlates to a particular metapackage version release. E.g. I can see from the commit history that: release of Using this method, you can also pull only up to a specific set of layers, e.g. dropping any number of layers in a tag you want to avoid in the tagged image; although I wouldn't recommend operating at that low of a level with your parent image declarations. I suspect you would still argue for time like tags like with ubuntu ( |
@130s , please checkout #204 |
Looks like the unique identifier #197 (comment) is good enough, for at least our usecases. But I'm also interested in more organized solution e.g. #204 (hence my comment #204 (comment)), as the unique id above doesn't seem to be tagged so it's not super user-friendly. Do you think it's a good idea to 'document' about this workaround? If so, is wiki.ros.org/docker/Tutorials a good place to add that? |
Yea, sound like a fine idea. Ping me if you'd like me to take a look at it. |
Revesting this idea, we could simply add a date timestamp tag (like that used already for ubuntu) to the end of the existing ones that updates itself with respect to the ros sync dates. Eg. Tags:
This time stamp could derived from rosdistro as referenced here: https://discourse.ros.org/t/new-packages-for-ros-2-rolling-ridley-2022-01-28/24067/5 Pro:
Cons:
Questions:
|
I still have general misgivings about providing named images that are guaranteed to be stable. I understand the drive to maintain control over pipelines but the way I see it, it makes it way too easy to rely on stale images. The base image is of greater concern than the ROS overlay. I don't see how any kind of pinning in the Dockerfile would allow us to update the base image while keeping the ROS packages pinned since the main ROS repositories only store the latest version of packages. For LTS ROS distributions which have snapshots published it would be possible to use the snapshots repository to build snapshot based images but that does not currently include Rolling or non-LTS releases of ROS 2. We may update the policy for non-LTS releases in the future but I'm pretty firmly against snapshots for Rolling given the amount of churn in the release policies by design. |
Instead of pinning by date/time, a simple option I proposed internally is using tagging by docker image hash. This works with existing infra without any code, and it is also unique for each pushed image. docker images -q ros:humble
>>> d5146462a4c1 Our team would like a way to reproduce previous deployments including all base packages from multiple different syncs. |
Has there been any demand/plan to preserve "snapshot" images, e.g. images taken at the certain period that will basically never be updated?
This would allow us to take a control over the version of all packages on the container.
I believe those who build the products upon Docker images somehow maintain the version of the packages inside the image and/or the base image version.
On Ubuntu's hub there are such images. E.g. xenial-20180808.
(CC @AustinDeric, ros-industrial/docker repo maintainer.)
The text was updated successfully, but these errors were encountered: