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

Upgrade docker images to ubuntu mantic #5537

Merged
merged 1 commit into from
Dec 8, 2023

Conversation

ptodev
Copy link
Contributor

@ptodev ptodev commented Oct 19, 2023

PR Description

Upgrading our docker files to ubuntu mantic.

Also, this PR removes the apt-get upgrade -y because it makes our docker builds more non-deterministic.

Notes to the Reviewer

apt-get upgrade -y was introduced recently as a temporary measure to make sure we are not using a particular library which had a known vulnerability.

PR Checklist

  • CHANGELOG.md updated
  • Documentation added
  • Tests updated
  • Config converters updated

@ptodev ptodev requested a review from tpaschalis October 19, 2023 12:01
@ptodev ptodev requested review from a team as code owners October 19, 2023 12:01
Copy link
Member

@tpaschalis tpaschalis left a comment

Choose a reason for hiding this comment

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

LGTM. Does the new image update all tools to the correct versions we wanted? Then let's get this merged.

@captncraig
Copy link
Contributor

Does trivy have definitions for mantic yet? I'm building and testing locally to verify.

@captncraig
Copy link
Contributor

I am not getting valid scans on ubuntu:mantic locally currently:

trivy i ubuntu:mantic
2023-10-19T10:56:16.723-0400    INFO    Need to update DB
2023-10-19T10:56:16.723-0400    INFO    DB Repository: ghcr.io/aquasecurity/trivy-db
2023-10-19T10:56:16.723-0400    INFO    Downloading DB...
40.57 MiB / 40.57 MiB [-------------------------------------------------------------------------------------------------------------------------------------] 100.00% 12.51 MiB p/s 3.4s
2023-10-19T10:56:20.614-0400    INFO    Vulnerability scanning is enabled
2023-10-19T10:56:20.615-0400    INFO    Secret scanning is enabled
2023-10-19T10:56:20.615-0400    INFO    If your scanning is slow, please try '--scanners vuln' to disable secret scanning
2023-10-19T10:56:20.615-0400    INFO    Please see also https://aquasecurity.github.io/trivy/v0.43/docs/scanner/secret/#recommendation for faster secret detection
2023-10-19T10:56:23.438-0400    INFO    Detected OS: ubuntu
2023-10-19T10:56:23.438-0400    WARN    This OS version is not on the EOL list: ubuntu 23.10
2023-10-19T10:56:23.438-0400    INFO    Detecting Ubuntu vulnerabilities...
2023-10-19T10:56:23.439-0400    INFO    Number of language-specific files: 0
2023-10-19T10:56:23.439-0400    WARN    This OS version is no longer supported by the distribution: ubuntu 23.10
2023-10-19T10:56:23.439-0400    WARN    The vulnerability detection may be insufficient because security updates are not provided

ubuntu:mantic (ubuntu 23.10)

Total: 0 (UNKNOWN: 0, LOW: 0, MEDIUM: 0, HIGH: 0, CRITICAL: 0)

I'm not sure we can update till that tool gives valid results.

@ptodev
Copy link
Contributor Author

ptodev commented Oct 19, 2023

I am also unable to scan Ubuntu 23.10 with Trivy:

└─▪ trivy --scanners vuln image ubuntu:mantic
2023-10-19T16:21:46.700+0100	INFO	Vulnerability scanning is enabled
2023-10-19T16:21:47.569+0100	INFO	Detected OS: ubuntu
2023-10-19T16:21:47.569+0100	WARN	This OS version is not on the EOL list: ubuntu 23.10
2023-10-19T16:21:47.569+0100	INFO	Detecting Ubuntu vulnerabilities...
2023-10-19T16:21:47.569+0100	INFO	Number of language-specific files: 0
2023-10-19T16:21:47.569+0100	WARN	This OS version is no longer supported by the distribution: ubuntu 23.10
2023-10-19T16:21:47.569+0100	WARN	The vulnerability detection may be insufficient because security updates are not provided

ubuntu:mantic (ubuntu 23.10)

Total: 0 (UNKNOWN: 0, LOW: 0, MEDIUM: 0, HIGH: 0, CRITICAL: 0)

I raised a PR for Trivy to support it. We can retry after it is merged. But tbh I'm not sure why we don't just use the latest Ubuntu LTS - 22.04.

@captncraig
Copy link
Contributor

@ptodev this should be good to go since that has merged. If you can fix the conflicts, we can merge this.

@captncraig captncraig removed their assignment Dec 7, 2023
Also, remove the "apt-get upgrade -y" because
it makes our docker builds more non-deterministic.
@tpaschalis tpaschalis force-pushed the ptodev/upgrade-ubuntu-mantic branch from 07a4ea3 to 26027cd Compare December 8, 2023 14:16
Copy link
Member

@tpaschalis tpaschalis left a comment

Choose a reason for hiding this comment

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

Looks like it's had some eyes on this, I'm going to merge this.

@tpaschalis
Copy link
Member

cc @ptodev @captncraig I'm going ahead to merge this since the Trivy PR was merged. Let's keep an eye out on main builds just in case.

@tpaschalis tpaschalis enabled auto-merge (squash) December 8, 2023 14:18
@tpaschalis tpaschalis merged commit 2899c9d into main Dec 8, 2023
10 checks passed
@tpaschalis tpaschalis deleted the ptodev/upgrade-ubuntu-mantic branch December 8, 2023 14:20
BarunKGP pushed a commit to BarunKGP/grafana-agent that referenced this pull request Feb 20, 2024
@github-actions github-actions bot added the frozen-due-to-age Locked due to a period of inactivity. Please open new issues or PRs if more discussion is needed. label Feb 21, 2024
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Feb 21, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
frozen-due-to-age Locked due to a period of inactivity. Please open new issues or PRs if more discussion is needed.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants