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

deb: explicitly install docker-ce-cli, scan-plugin, and docker-ce #235

Merged
merged 1 commit into from
Jun 7, 2021

Conversation

thaJeztah
Copy link
Member

@thaJeztah thaJeztah commented Jun 3, 2021

internal ticket: POS-27

supersedes / replaces #195 (except for the "containerd.io" part)
closes #195

The scripts is using "--no-install-recommends" to provide a more minimal install, and to prevent installing "latest" version of (e.g.) the engine when installing the CLI.

This patch:

  • adds some utilities to compare versions
  • skips CLI-version discovery on older versions (before 18.09) which did not have separate packages for the CLI
  • on versions 20.10 and up (or if no version was specified), also install the scan cli plugin (support for cli plugins was added in docker 19.03, but not installing on that version by default))

@thaJeztah thaJeztah force-pushed the install_recommends branch 2 times, most recently from 5771251 to eeace91 Compare June 3, 2021 14:44
@thaJeztah
Copy link
Member Author

@chris-crone @glours PTAL

Copy link
Member

@chris-crone chris-crone left a comment

Choose a reason for hiding this comment

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

I ran a quick test with an Ubuntu container and it worked as expected. I didn't have a chance to test the version code path though

@thaJeztah thaJeztah force-pushed the install_recommends branch from eeace91 to a5a7d55 Compare June 3, 2021 16:14
@thaJeztah
Copy link
Member Author

rebased, after #236 was merged

chris-crone
chris-crone previously approved these changes Jun 3, 2021
Copy link
Member

@chris-crone chris-crone left a comment

Choose a reason for hiding this comment

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

Tested the version path a bit and LGTM!

install.sh Outdated
command_exists() {
command -v "$@" > /dev/null 2>&1
}

# is_at_least_version checks if the version specified in $VERSION is at least
Copy link
Member Author

Choose a reason for hiding this comment

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

oh! forgot to update this comment (renamed the function at some point); let me fix

Copy link
Member Author

Choose a reason for hiding this comment

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

done 👍

The scripts is using "--no-install-recommends" to provide a more
minimal install, and to prevent installing "latest" version of
(e.g.) the engine when installing the CLI.

This patch:

- adds some utilities to compare versions
- skips CLI-version discovery on older versions (before 18.09)
  which did not have separate packages for the CLI
- on versions 20.10 and up (or if no version was specified), also
  install the scan cli plugin (support for cli plugins was added
  in docker 19.03, but not installing on that version by default))

Signed-off-by: Sebastiaan van Stijn <[email protected]>
Copy link

@glours glours left a comment

Choose a reason for hiding this comment

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

LGTM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants