-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
record components version in base os
Signed-off-by: Stepan Blyschak <stepanb@nvidia.com>
- Loading branch information
1 parent
24d299e
commit 3912caf
Showing
7 changed files
with
47 additions
and
20 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
--- | ||
build_version: '{{ build_version }}' | ||
{% if debian_version is defined -%} | ||
debian_version: '{{ debian_version }}' | ||
{% endif -%} | ||
{% if kernel_version is defined -%} | ||
kernel_version: '{{ kernel_version }}' | ||
{% endif -%} | ||
asic_type: {{ asic_type }} | ||
commit_id: '{{ commit_id }}' | ||
build_date: {{ build_date }} | ||
build_number: {{ build_number }} | ||
built_by: {{ built_by }} | ||
{% if components is defined -%} | ||
{% for component in components.split() | unique -%} | ||
{% set name, version = component.split('==') -%} | ||
{{ name }}: {{ version }} | ||
{% endfor -%} | ||
{% endif -%} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,7 @@ | ||
tee $1 > /dev/null <<EOF | ||
build_version: '$sonic_version' | ||
asic_type: $sonic_asic_platform | ||
commit_id: '$(git rev-parse --short HEAD)' | ||
build_date: $(date -u) | ||
build_number: ${BUILD_NUMBER:-0} | ||
built_by: $USER@$BUILD_HOSTNAME | ||
EOF | ||
export build_version="${sonic_version}" | ||
export asic_type="${sonic_asic_platform}" | ||
export commit_id="$(git rev-parse --short HEAD)" | ||
export build_date="$(date -u)" | ||
export build_number="${BUILD_NUMBER:-0}" | ||
export built_by="$USER@$BUILD_HOSTNAME" | ||
j2 sonic_version.yml.j2 > $1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
../../../files/build_templates/sonic_version.yml.j2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters