-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
Add Tag info to docker label meta data #2058
Conversation
597c3d6
to
21536ff
Compare
Signed-off-by: Jipan Yang <jipan.yang@alibaba-inc.com>
21536ff
to
874b4d9
Compare
functions.sh
Outdated
@@ -55,7 +55,11 @@ sonic_get_version() { | |||
local latest_tag=$(git describe --tags --abbrev=0) | |||
local branch_name=$(git rev-parse --abbrev-ref HEAD) | |||
if [ -n "$(git status --untracked-files=no -s --ignore-submodules)" ]; then | |||
local dirty="-dirty-$DIRTY_SUFFIX" | |||
if [ -z "$DIRTY_SUFFIX" ]; then | |||
local dirty="-dirty-"$(date +%Y%m%d\.%H%M%S) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
DIRTY_SUFFIX is defined in slave.mk, why do we need this check?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I tried changes like moving DIRTY_SUFFIX before SONIC_GET_VERSION
DIRTY_SUFFIX="$(shell date +%Y%m%d\.%H%M%S)"
SONIC_GET_VERSION=$(shell . functions.sh && sonic_get_version)
And even export DIRTY_SUFFIX before docker build. They didn't work, tag like "warm-reboot.0-dirty-" was populated.
I guess there is some evaluation issue with layered macro with shell command in Makefile.
If you have any new idea or different way of handling it, I may give it a try.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
does DIRTY_SUFFIX work now?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
DIRTY_SUFFIX works if sonic_get_version() is called from another shell script. But calling it in Makefile is not working. I have not figured out how to do it.
Since DIRTY_SUFFIX is only used in sonic_get_version(), but defined in slave.mk, maybe it should be moved to sonic_get_version() to get rid of the issue introduced with jumping from Makefile to shell and back to Makefile again.
Signed-off-by: Jipan Yang <jipan.yang@alibaba-inc.com>
c78aa1b (HEAD -> master, origin/master, origin/HEAD) OA changes to support Ordered ECMP and DVS test for same. (sonic-net#2092) b4b0003 Handling Invalid CRM configuration gracefully (sonic-net#2109) d240cb2 [Mellanox] '_8lane' not added to Mellanox 5xxx models with 800G (sonic-net#2090) 8fd6e48 [pfcwd] Add vs test infrastructure (sonic-net#2077) b96ee54 [vnetorch] Advertise vnet tunnel routes (sonic-net#2058) Signed-off-by: Abhishek Dosi <abdosi@microsoft.com>
[Submodule update] sonic-swss c78aa1b (HEAD -> master, origin/master, origin/HEAD) OA changes to support Ordered ECMP and DVS test for same. (#2092) b4b0003 Handling Invalid CRM configuration gracefully (#2109) d240cb2 [Mellanox] '_8lane' not added to Mellanox 5xxx models with 800G (#2090) 8fd6e48 [pfcwd] Add vs test infrastructure (#2077) b96ee54 [vnetorch] Advertise vnet tunnel routes (#2058)
What I did Advertise active vnet tunnel routes. Why I did it The overlay routes programmed on the device need to be advertised to BGP peers. This PR aims to meet this requirement. How I verified it Add an entry in ADVERTISE_NETWORK_TABLE for active overlay routes
Signed-off-by: Jipan Yang jipan.yang@alibaba-inc.com
- What I did
Add tag info to docker label meta data
- How I did it
- How to verify it
build docker, upgrade to new docker image and check version.
Dirty build
Clean build
Before upgrade
upgrade docker
After upgrade
- A picture of a cute animal (not mandatory but encouraged)