Update image used in CI-tests from ubuntu:18.04 to ubuntu:22.04 to avoid deprecation problems #2526
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Ubuntu 18.04 is being deprecated in GitHub Actions since 8/8/2022 and will be fully unsupported by 4/1/2023.
To generate awareness, there are a couple of brown-out-periods where all CI-tests using that image will fail.
This merge-request will avoid any more possible failing CI-tests because of usage of a deprecated image.
Extra commits
1. Update Aws\Test\CloudFront\SignerTest::testBadPrivateKeyPath()
The message thrown by OpenSSL changed from version 1.x (used in ubuntu 18.04) to version 3.x (used in ubuntu 22.04).
I only modified the test to capture this new error message. Since both outputs are rather cryptic, I think we can improve the developer experience when
Signer::__construct()
throws a proper message to signal the provided keyfile is incorrect, and appended, the original error-message from OpenSSL.I did not modify this now to restrict changes only related to the test-image.
2. Add more output-logging when Tests\Crypto\Polyfill\AesGcmTest::testCompat() fails
This tests is rather flaky and randomly fails. Previously it only showed the result of both encryptions, which does not allow reproduction of the error.
I've added a failure-message which shows the input used, so we can reproduce the test-case the next time this flaky test fails again.
I'm aware this is not strictly related to the test-image-update, so I can split this off to a seperate PR, but as the change has no impact on the actual code or changes any tested codepaths, I thought it was acceptable to add this to this PR.
Postscript
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.