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

Add support for Elasticsearch 7.16 and 7.17 #358

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from

Conversation

phoenix-bjoern
Copy link

Description

The images for Elasticsearch are outdated and versions are unsupported by recent Adobe Commerce / Magento releases (https://experienceleague.adobe.com/docs/commerce-operations/installation-guide/system-requirements.html). The PR adds support for Elasticsearch 7.16 and 7.17 to match system requirements.

Fixed Issues

The upstream images switched their base image from centos:8 to ubuntu:20.04. Furthermore the log4j vulnerability has been fixed in ES 7.16 (https://www.elastic.co/de/blog/new-elasticsearch-and-logstash-releases-upgrade-apache-log4j2). Hence the patching of the log4j class is not required and the Dockerfile can be simplified.

Manual testing scenarios

Build for both new Elastcisearch version can be tested by:

  1. docker build -f images/elasticsearch/7.16/Dockerfile images/elasticsearch/7.16
  2. docker build -f images/elasticsearch/7.17/Dockerfile images/elasticsearch/7.17

Release notes

  • Added support for Elasticsearch 7.16 and 7.17

@magento-cloud-ft-jenkins-svc

Functional Acceptance Test Results

❌  One or more functional acceptance tests have failed.

PHP 7.2

  • ✅  Elasticsearch72Cest
  • ✅  Services72Cest
  • ❌  Acceptance72Cest

PHP 7.3

  • ✅  ServicesCest
  • ✅  Elasticsearch73Cest
  • ✅  Acceptance73Cest

PHP 7.4

  • ✅  Elasticsearch74Cest
  • ✅  Acceptance74Cest

PHP 8.1

  • ✅  DeveloperCest
  • ✅  ElasticsearchCest
  • ✅  MailHogCest
  • ✅  OpensearchCest
  • ✅  AcceptanceCest

Output for failed tests is below. If many tests have failed only the first 5 will be included. If you need additional information please reach out to the Magento Cloud team for more details.

This comment was generated by Jenkins job magento-cloud-docker/functional build 160.

@magento-cloud-ft-jenkins-svc

PHP 7.2 Acceptance72Cest Output

Codeception PHP Testing Framework v4.2.2 https://helpukrainewin.org
Powered by PHPUnit 8.5.32 by Sebastian Bergmann and contributors.

Acceptance Tests (2) ---------------------------------------
Acceptance72Cest: Test production mode
Signature: Magento\CloudDocker\Test\Functional\Acceptance\Acceptance72Cest:testProductionMode
Test: src/Test/Functional/Acceptance/Acceptance72Cest.php:testProductionMode
Scenario --
 I cleanup work dir 
 I is cache work dir exists "2.3.2"
 I clone template to work dir "2.3.2"
 I create auth json 
 I create artifacts dir 
 I create artifact current tested code "docker","1.3.1"
 I add artifacts repo to composer 
 I add dependency to composer "magento/magento-c...","1.3.1"
 I add ece tools git repo to composer 
 I get dependency version "magento/ece-tools"
 I add dependency to composer "magento/e...","dev-devel..."
 I get dependency version "magento/magento-cloud-components"
 I get dependency version "magento/magento-cloud-patches"
 I get dependency version "magento/quality-patches"
 I composer update 
 I assert true true,"Composer update failed"
 I cache work dir "2.3.2"
sh: rsync: not found
 I generate docker compose "--mode=production"
 I assert true true,"Command build:compose failed"
 I replace images with custom 
 I start environment 
 I run docker compose command "run build cloud-build"
 I run docker compose command "run deploy cloud-deploy"
 I run docker compose command "run deploy cloud-post-deploy"
 I am on page "/"
 I see "Home page"
 I run docker compose command "ps"
 I stop environment 
 I remove work dir 
 FAIL 

Acceptance72Cest: Test custom host
Signature: Magento\CloudDocker\Test\Functional\Acceptance\Acceptance72Cest:testCustomHost
Test: src/Test/Functional/Acceptance/Acceptance72Cest.php:testCustomHost
Scenario --
 I cleanup work dir 
 I is cache work dir exists "2.3.2"
 I clone template to work dir "2.3.2"
 I create auth json 
 I create artifacts dir 
 I create artifact current tested code "docker","1.3.1"
 I add artifacts repo to composer 
 I add dependency to composer "magento/magento-c...","1.3.1"
 I add ece tools git repo to composer 
 I get dependency version "magento/ece-tools"
 I add dependency to composer "magento/e...","dev-devel..."
 I get dependency version "magento/magento-cloud-components"
 I get dependency version "magento/magento-cloud-patches"
 I get dependency version "magento/quality-patches"
 I composer update 
 I assert true true,"Composer update failed"
 I cache work dir "2.3.2"
sh: rsync: not found
 I update base url "http://magento2.test/"
 I generate docker compose "--mode=production --host=mag..."
 I assert true true,"Command build:compose failed"
 I replace images with custom 
 I start environment 
 I run docker compose command "run build cloud-build"
 I assert true false,"Build phase failed"
 I run docker compose command "ps"
 I stop environment 
 I remove work dir 
 FAIL 

------------------------------------------------------------
28x DEPRECATION: Passing a command as string when creating a "Symfony\Component\Process\Process" instance is deprecated since Symfony 4.2, pass it as an array of its arguments instead, or use the "Process::fromShellCommandline()" constructor if you need features provided by the shell. /app/vendor/symfony/process/Process.php:147
8x DEPRECATION: The Robo\Common\ProcessUtils::escapeArgument() method is a copy of a method that was deprecated by Symfony 3.3 and removed in Symfony 4; it will be removed in Robo 2.0. /app/vendor/consolidation/robo/src/Common/ProcessUtils.php:39


Time: 18.09 minutes, Memory: 18.00 MB

There were 2 failures:

---------
1) Acceptance72Cest: Test production mode
 Test  src/Test/Functional/Acceptance/Acceptance72Cest.php:testProductionMode
 Step  See "Home page"
 Fail  Failed asserting that  on page /
-->  Autoload error We can't read some files that are required to run the Magento application. This usually means file permissions are set incorrectly. 
--> contains "Home page".

Scenario Steps:

 29. $I->removeWorkDir() at src/Test/Functional/Acceptance/AbstractCest.php:72
 28. $I->stopEnvironment() at src/Test/Functional/Acceptance/AbstractCest.php:71
 27. $I->runDockerComposeCommand("ps") at src/Test/Functional/Acceptance/AbstractCest.php:70
 26. $I->see("Home page") at src/Test/Functional/Acceptance/AcceptanceCest.php:35
 25. $I->amOnPage("/") at src/Test/Functional/Acceptance/AcceptanceCest.php:34
 24. $I->runDockerComposeCommand("run deploy cloud-post...") at src/Test/Functional/Acceptance/AcceptanceCest.php:33

Artifacts:

Html: /app/tests/functional/_output/Magento.CloudDocker.Test.Functional.Acceptance.Acceptance72Cest.testProductionMode.fail.html
Response: /app/tests/functional/_output/Magento.CloudDocker.Test.Functional.Acceptance.Acceptance72Cest.testProductionMode.fail.html

---------
2) Acceptance72Cest: Test custom host
 Test  src/Test/Functional/Acceptance/Acceptance72Cest.php:testCustomHost
 Step  Assert true false,"Build phase failed"
 Fail  Build phase failed
Failed asserting that false is true.

Scenario Steps:

 27. $I->removeWorkDir() at src/Test/Functional/Acceptance/AbstractCest.php:72
 26. $I->stopEnvironment() at src/Test/Functional/Acceptance/AbstractCest.php:71
 25. $I->runDockerComposeCommand("ps") at src/Test/Functional/Acceptance/AbstractCest.php:70
 24. $I->assertTrue(false,"Build phase failed") at src/Test/Functional/Acceptance/AcceptanceCest.php:54
 23. $I->runDockerComposeCommand("run build cloud-build") at src/Test/Functional/Acceptance/AcceptanceCest.php:54
 22. $I->startEnvironment() at src/Test/Functional/Acceptance/AcceptanceCest.php:53


FAILURES!
Tests: 2, Assertions: 6, Failures: 2.
- XML report generated in file:///app/tests/functional/_output/junit.xml

This comment was generated by Jenkins job magento-cloud-docker/functional build 160.

@BaDos BaDos self-assigned this Feb 10, 2023
@m2-community-project m2-community-project bot moved this from Ready for Review to Review in Progress in Pull Request Progress Feb 10, 2023
@BaDos
Copy link
Contributor

BaDos commented Feb 10, 2023

@phoenix-bjoern thank you for your PR
I will process this PR soon

@BaDos
Copy link
Contributor

BaDos commented Feb 13, 2023

@magento import pr to magento-commerce/magento-cloud-docker

@m2-github-services
Copy link

@BaDos the Pull Request is successfully imported.

@phoenix-bjoern
Copy link
Author

@BaDos any update on processing the PR.

@phoenix-bjoern
Copy link
Author

@BaDos any update here?

@BaDos BaDos removed their assignment Mar 2, 2024
@m2-community-project m2-community-project bot moved this from Review in Progress to Ready for Review in Pull Request Progress Mar 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Pull Request Progress
Ready for Review
Development

Successfully merging this pull request may close these issues.

None yet

4 participants