You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe
The Image Layers grid section shown on the edit image page (../images/edit/image.html) is very useful for showing the image history, however it is missing one key property: the creation date.
Describe the solution you'd like
The data is already available in the API service ImageLayer model (../queries/images/useImageHistory.ts) and view model ImageLayerViewModel (../models/imageLayer.ts), which is basically a Unix timestamp. So likely all we need to do here is update the UI side under the edit image page (shared above), plus some basic date formatting.
Current API result payload shown in dev tools:
Describe alternatives you've considered
Currently the only way to get this information is to use the docker CLI directly and use the docker image history command. Example:
docker image history portainer/portainer-ce:lts
Example output:
IMAGE CREATED CREATED BY SIZE COMMENT
9921b88610a2 13 days ago ENTRYPOINT ["/portainer.exe"] 0B buildkit.dockerfile.v0
<missing> 13 days ago LABEL io.portainer.server=true 0B buildkit.dockerfile.v0
<missing> 13 days ago EXPOSE map[8000/tcp:{}] 0B buildkit.dockerfile.v0
<missing> 13 days ago EXPOSE map[9443/tcp:{}] 0B buildkit.dockerfile.v0
<missing> 13 days ago EXPOSE map[9000/tcp:{}] 0B buildkit.dockerfile.v0
<missing> 13 days ago COPY dist/storybook* /storybook/ # buildkit 0B buildkit.dockerfile.v0
<missing> 13 days ago COPY dist/public /public/ # buildkit 47.5MB buildkit.dockerfile.v0
<missing> 13 days ago COPY dist/portainer.exe / # buildkit 97.5MB buildkit.dockerfile.v0
<missing> 13 days ago COPY dist/mustache-templates /mustache-templ… 643B buildkit.dockerfile.v0
<missing> 13 days ago COPY dist/docker.exe / # buildkit 43.6MB buildkit.dockerfile.v0
<missing> 13 days ago COPY dist/mingit/ mingit/ # buildkit 108MB buildkit.dockerfile.v0
<missing> 13 days ago USER ContainerAdministrator 0B buildkit.dockerfile.v0
<missing> 13 days ago COPY /Windows/System32/netapi32.dll /Windows… 113kB buildkit.dockerfile.v0
<missing> 13 days ago ENV PATH=C:\mingit\cmd;C:\Windows\system32;C… 0B buildkit.dockerfile.v0
<missing> 2 weeks ago Apply image 10.0.20348.4297 297MB
Additional context
Worth noting that in the original PR #425 for this feature, the design originally had the create date showing, as well as a few other datapoints, however at the request of @deviantony in this #425 (comment), these items were removed.
Personally I would find it very valuable to show the create date, as it generally will make it easier to group layers together from a quick glance. For example, it might allow us to identify which layers were part of the base image vs built by the image maintainer. Given the portainer/portainer-ce:lts image history CLI results from above, I can discern that the base layer starts at position #0 and and the remaining layers were likely produced by the portainer specific dockerfile. This also makes me somewhat confident that the portainer image was built from a nanoserver base image (for Windows that is), rather than a servercore image, which helps me to know what default capabilities the image has (i.e. can't install MSI's or use powershell on nanoserver).
There are additional benefits of making it very obvious when a particular image is quite outdated or potentially was built against pretty outdated base layers.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
Is your feature request related to a problem? Please describe
The Image Layers grid section shown on the edit image page (../images/edit/image.html) is very useful for showing the image history, however it is missing one key property: the creation date.
Describe the solution you'd like
The data is already available in the API service
ImageLayermodel (../queries/images/useImageHistory.ts) and view modelImageLayerViewModel(../models/imageLayer.ts), which is basically a Unix timestamp. So likely all we need to do here is update the UI side under the edit image page (shared above), plus some basic date formatting.Current API result payload shown in dev tools:
Describe alternatives you've considered
Currently the only way to get this information is to use the docker CLI directly and use the docker image history command. Example:
docker image history portainer/portainer-ce:ltsExample output:
Additional context
Worth noting that in the original PR #425 for this feature, the design originally had the create date showing, as well as a few other datapoints, however at the request of @deviantony in this #425 (comment), these items were removed.
Personally I would find it very valuable to show the create date, as it generally will make it easier to group layers together from a quick glance. For example, it might allow us to identify which layers were part of the base image vs built by the image maintainer. Given the
portainer/portainer-ce:ltsimage history CLI results from above, I can discern that the base layer starts at position #0 and and the remaining layers were likely produced by the portainer specific dockerfile. This also makes me somewhat confident that the portainer image was built from a nanoserver base image (for Windows that is), rather than a servercore image, which helps me to know what default capabilities the image has (i.e. can't install MSI's or use powershell on nanoserver).There are additional benefits of making it very obvious when a particular image is quite outdated or potentially was built against pretty outdated base layers.
Beta Was this translation helpful? Give feedback.
All reactions