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

dhcp-relay and macsec dockers are not tagged with the image version #11521

Closed
saiarcot895 opened this issue Jul 23, 2022 · 8 comments
Closed
Labels
MSFT Triaged this issue has been triaged

Comments

@saiarcot895
Copy link
Contributor

Description

The dhcp-relay and macsec docker containers are not tagged with the image version in docker images. They have the latest tag, but not the image version tag.

Steps to reproduce the issue:

  1. Load any master branch or 202205 branch image.
  2. Run docker images to see what images are available

Describe the results you received:

REPOSITORY                    TAG                       IMAGE ID       SIZE
docker-orchagent              latest                    fe3e64b7e543   478MB
docker-orchagent              master.125402-ba991ab2b   fe3e64b7e543   478MB
docker-macsec                 latest                    dc43ce04e308   462MB
docker-gbsyncd-vs             latest                    6ba40ca23dee   452MB
docker-gbsyncd-vs             master.125402-ba991ab2b   6ba40ca23dee   452MB
docker-dhcp-relay             latest                    56eb71be4440   453MB
docker-sonic-telemetry        latest                    4e801dfe7b2c   524MB
docker-sonic-telemetry        master.125402-ba991ab2b   4e801dfe7b2c   524MB
docker-router-advertiser      latest                    2d779505bd70   444MB
docker-router-advertiser      master.125402-ba991ab2b   2d779505bd70   444MB
docker-platform-monitor       latest                    0389dc544406   566MB
docker-platform-monitor       master.125402-ba991ab2b   0389dc544406   566MB
docker-mux                    latest                    880232ae811e   492MB
docker-mux                    master.125402-ba991ab2b   880232ae811e   492MB
docker-database               latest                    d20792b5f223   444MB
docker-database               master.125402-ba991ab2b   d20792b5f223   444MB
docker-fpm-frr                latest                    f2120bde67bc   458MB
docker-fpm-frr                master.125402-ba991ab2b   f2120bde67bc   458MB
docker-nat                    latest                    6154fa670a3a   431MB
docker-nat                    master.125402-ba991ab2b   6154fa670a3a   431MB
docker-teamd                  latest                    09b5a3bdf40f   429MB
docker-teamd                  master.125402-ba991ab2b   09b5a3bdf40f   429MB
docker-sflow                  latest                    e7343335c5bd   429MB
docker-sflow                  master.125402-ba991ab2b   e7343335c5bd   429MB
docker-syncd-vs               latest                    361573578999   426MB
docker-syncd-vs               master.125402-ba991ab2b   361573578999   426MB
docker-snmp                   latest                    bed1cdc88f51   457MB
docker-snmp                   master.125402-ba991ab2b   bed1cdc88f51   457MB
docker-sonic-mgmt-framework   latest                    7843f3440cec   558MB
docker-sonic-mgmt-framework   master.125402-ba991ab2b   7843f3440cec   558MB
docker-lldp                   latest                    58ce11598f95   454MB
docker-lldp                   master.125402-ba991ab2b   58ce11598f95   454MB

docker-dhcp-relay:latest is tagged, but not docker-dhcp-relay:master.125402-ba991ab2b. docker-macsec isn't present in this build, but is also affected.

Describe the results you expected:

docker-dhcp-relay:master.125402-ba991ab2b should be present.

Output of show version:

This was taken from the log of the most recent VS image build.

Output of show techsupport:

Additional information you deem important (e.g. issue happens only occasionally):

@stepanblyschak
Copy link
Collaborator

@saiarcot895 Could you please describe the use case where you need to see the docker image tagged also with the image version?

It is by design that the app. ext images have a single tag present in the system, so that it is easy to manage the image. You can find the Tag in the docker image labels.

@saiarcot895
Copy link
Contributor Author

It's more of a visual expectation. All of the other dockers that are packaged with this image are tagged with the image version. Older images (such as those from the 202012 branch) have docker-dhcp-relay tagged with the image version.

@yxieca
Copy link
Contributor

yxieca commented Jul 25, 2022

@renukamanavalan Can you assess this design change from K8 perspective?

@renukamanavalan
Copy link
Contributor

@renukamanavalan Can you assess this design change from K8 perspective?

Looks good to me.

@zhangyanzhao
Copy link
Collaborator

Is this issue fix?

@zhangyanzhao zhangyanzhao added Triaged this issue has been triaged MSFT labels Aug 3, 2022
@qiluo-msft
Copy link
Collaborator

Could you please describe the use case where you need to see the docker image tagged also with the image version?

It is by design that the app. ext images have a single tag present in the system, so that it is easy to manage the image. You can find the Tag in the docker image labels.

@stepanblyschak We should support multiple tags. I could give a use case. If some docker controller ask SONiC device to pull a latest docker-macsec:latest image, the previous image will lose the tag and it is not convenient to refer the previous one. If would be quite meaningful, if we add a label like master.125402-ba991ab2b because it comes with this image version.

@stepanblyschak
Copy link
Collaborator

@qiluo-msft Just to understand is this your use case? Have you tested it?:

  1. Load SONiC image in local docker mode
  2. Deploy latest with kubernetes
  3. Switch back to local and observe there's no original docker SONiC was built with?

@stepanblyschak
Copy link
Collaborator

Discussed online. Will keep SONiC version string instead of latest, but will not keep the latest, scripts generated by spm are using image id to identify image. Medium priority issue.

mssonicbld pushed a commit to mssonicbld/sonic-buildimage that referenced this issue Dec 5, 2022
Fixes: sonic-net#11521

- Why I did it
When build SONiC dockers, SONiC build system tags all of them with latest tag. This is Ok for all built-in dockers because we will also tag them with image version tag in sonic_debian_extension.j2 script. On the other hand, some of these dockers are SONiC packages and they are installed by sonic-package-manager which creates a only one tag whcih is recorded in the corresponding .gz file. This leads to having these dockers tagged only with latest tag. This change saves the tag as an image version string in .gz file, so that these dockers have version identification in their tag.

- How I did it
I modified slave.mk to save the version tag instead of latest tag.

- How to verify it
I verified this change by running show version

Signed-off-by: Stepan Blyschak <stepanb@nvidia.com>
StormLiangMS pushed a commit to StormLiangMS/sonic-buildimage that referenced this issue Dec 8, 2022
Fixes: sonic-net#11521

- Why I did it
When build SONiC dockers, SONiC build system tags all of them with latest tag. This is Ok for all built-in dockers because we will also tag them with image version tag in sonic_debian_extension.j2 script. On the other hand, some of these dockers are SONiC packages and they are installed by sonic-package-manager which creates a only one tag whcih is recorded in the corresponding .gz file. This leads to having these dockers tagged only with latest tag. This change saves the tag as an image version string in .gz file, so that these dockers have version identification in their tag.

- How I did it
I modified slave.mk to save the version tag instead of latest tag.

- How to verify it
I verified this change by running show version

Signed-off-by: Stepan Blyschak <stepanb@nvidia.com>
StormLiangMS pushed a commit that referenced this issue Dec 10, 2022
Fixes: #11521

- Why I did it
When build SONiC dockers, SONiC build system tags all of them with latest tag. This is Ok for all built-in dockers because we will also tag them with image version tag in sonic_debian_extension.j2 script. On the other hand, some of these dockers are SONiC packages and they are installed by sonic-package-manager which creates a only one tag whcih is recorded in the corresponding .gz file. This leads to having these dockers tagged only with latest tag. This change saves the tag as an image version string in .gz file, so that these dockers have version identification in their tag.

- How I did it
I modified slave.mk to save the version tag instead of latest tag.

- How to verify it
I verified this change by running show version

Signed-off-by: Stepan Blyschak <stepanb@nvidia.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
MSFT Triaged this issue has been triaged
Projects
None yet
Development

No branches or pull requests

6 participants