Skip to content

Update ubuntu packaging scripts #10615

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

Conversation

danudey
Copy link
Contributor

@danudey danudey commented Jun 27, 2025

  • Add checks for two required binaries
  • Fix changelog being generated with incorrect distributions

* Add checks for two required binaries
* Fix changelog being generated with incorrect distributions
@Copilot Copilot AI review requested due to automatic review settings June 27, 2025 18:11
@danudey danudey added docs-not-required Docs not required for this change release-note-not-required Change has no user-facing impact labels Jun 27, 2025
@danudey danudey requested a review from a team as a code owner June 27, 2025 18:11
@danudey danudey self-assigned this Jun 27, 2025
@marvin-tigera marvin-tigera added this to the Calico v3.31.0 milestone Jun 27, 2025
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR enhances the Ubuntu packaging scripts by adding runtime checks for required tools and correcting the changelog generation to target the proper distribution.

  • Added validation for dch and patchelf binaries in the update script
  • Modified the dch invocation in the packaging script to include the correct distribution series

Reviewed Changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
release/packaging/utils/make-packages.sh Updated dch call to pass a --distribution flag for the series
release/packaging/utils/create-update-packages.sh Added check_bin calls for dch and patchelf
Comments suppressed due to low confidence (1)

release/packaging/utils/create-update-packages.sh:51

  • [nitpick] Make error messages more actionable by suggesting an installation command, e.g.: error_exit "Please install devscripts (e.g., sudo apt install devscripts)".
    check_bin dch || error_exit "This script requires the 'dch' command from the 'devscripts' package."

@@ -59,7 +59,7 @@ for package_type in "$@"; do
fi
rm -f debian/changelog debian/changelog.dch
dch --controlmaint --create --package "${PKG_NAME}" -v "${DEB_EPOCH}${debver}-$series" "${changelog_message}"
dch --controlmaint --release ""
dch --controlmaint --release --distribution $series ""
Copy link
Preview

Copilot AI Jun 27, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The --distribution flag should come after the empty release text and the $series variable should be quoted. For example:

dch --controlmaint --release "" --distribution "${series}"
Suggested change
dch --controlmaint --release --distribution $series ""
dch --controlmaint --release "" --distribution "${series}"

Copilot uses AI. Check for mistakes.

@nelljerram nelljerram merged commit 602fe5d into projectcalico:master Jun 30, 2025
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs-not-required Docs not required for this change release-note-not-required Change has no user-facing impact
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants