fabric icon indicating copy to clipboard operation
fabric copied to clipboard

Upgrade ubuntu from 20.04 to 24.04 LTS version

Open C0rWin opened this issue 1 year ago • 1 comments

Moving container images from using Ubuntu 20.04 to Ubuntu 24.04, this is to reduce amount of vulnerabilities reported with 20.04 version, effectively from this

    i New version 1.13.0 available (installed version is 1.11.0) at https://github.com/docker/scout-cli
          ✓ SBOM of image already cached, 218 packages indexed

  Target               │  hyperledger/fabric-peer:latest  │    1C     1H     1M    10L
    digest             │  260a5496cc95                    │
  Base image           │  ubuntu:20.04                    │    0C     0H     1M    10L
  Refreshed base image │  ubuntu:20.04                    │    0C     0H     1M    10L
                       │                                  │
  Updated base image   │  ubuntu:24.04                    │    0C     0H     1M     3L
                       │                                  │                         -7

to this

    i New version 1.13.0 available (installed version is 1.11.0) at https://github.com/docker/scout-cli
          ✓ SBOM of image already cached, 213 packages indexed

    i Base image was auto-detected. To get more accurate results, build images with max-mode provenance attestations.
      Review docs.docker.com ↗ for more information.

  Target             │  hyperledger/fabric-peer:latest  │    0C     0H     1M     3L
    digest           │  bd06340d98f4                    │
  Base image         │  ubuntu:24.04                    │    0C     0H     1M     3L
  Updated base image │  ubuntu:24.10                    │    0C     0H     0M     0L
                     │                                  │                  -1     -3

C0rWin avatar Aug 27 '24 19:08 C0rWin

--- FAIL: TestBlockPullerBadBlocks (10.17s)
    --- FAIL: TestBlockPullerBadBlocks/wrong_number (10.02s)
        deliver_test.go:1193: PullBlock did not complete within time
2024-08-27 19:43:17.184 UTC 133f INFO [grpc] Infof -> [transport] [client-transport 0xc00021e248] Closing: connection error: desc = "error reading from server: EOF"

doesn't seem related to my change, re-running UT job again.

C0rWin avatar Aug 27 '24 21:08 C0rWin

Github is still using 22.04 for ubuntu-latest, and is still calling 24.04 'beta' for some reason - https://github.com/actions/runner-images?tab=readme-ov-file#available-images. How do you feel about using 22.04 for a more incremental step up?

Not an issue for fabric, but for fabric-ca since it uses CGO updating to a version later than the ultimate server runs causes issues. For this reason I like to keep fabric-ca a little more behind. But I'd be comfortable with 22.04 across all the repositories.

denyeart avatar Sep 10 '24 15:09 denyeart

Github is still using 22.04 for ubuntu-latest, and is still calling 24.04 'beta' for some reason - https://github.com/actions/runner-images?tab=readme-ov-file#available-images. How do you feel about using 22.04 for a more incremental step up?

Not an issue for fabric, but for fabric-ca since it uses CGO updating to a version later than the ultimate server runs causes issues. For this reason I like to keep fabric-ca a little more behind. But I'd be comfortable with 22.04 across all the repositories.

I am just fine to use 22.04 also, just feeling more secure to going with the most recent LTS. But I am ok, let's start with 22.04 and then plan switching to 24.04 later on.

C0rWin avatar Sep 11 '24 11:09 C0rWin

@denyeart, per your suggestion, changed to 22.04.

C0rWin avatar Sep 15 '24 21:09 C0rWin

Thanks @C0rWin , I think we should also update in each of the github workflows under .github/workflows, right?

denyeart avatar Sep 16 '24 12:09 denyeart

Thanks @C0rWin , I think we should also update in each of the github workflows under .github/workflows, right?

I've done a separate PR - https://github.com/hyperledger/fabric/pull/4986

denyeart avatar Sep 17 '24 03:09 denyeart

Thanks @C0rWin , I think we should also update in each of the github workflows under .github/workflows, right?

yeap

C0rWin avatar Sep 17 '24 12:09 C0rWin

@C0rWin I can also move -latest to 24.04, let me know

ryjones avatar Sep 17 '24 13:09 ryjones

Talked to Ry, we're just going to use fabric-ubuntu-22.04 for the time being.

denyeart avatar Sep 17 '24 19:09 denyeart

In the Makefile 22.04 is correct, merged.

denyeart avatar Sep 17 '24 19:09 denyeart