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

MFTF Configuration Issue #1038

Open
mjogi-rave opened this issue Jan 8, 2024 · 5 comments
Open

MFTF Configuration Issue #1038

mjogi-rave opened this issue Jan 8, 2024 · 5 comments

Comments

@mjogi-rave
Copy link

Description
I have installed Magento 2.4.6-p3 using docker steps under folder /var/www/html/magento246p3/ and I want to use MFTF feature in docker, but bin/mftf build:project command is creating .env and .credential file under /var/www/html/dev/tests/acceptance/, but this file is not creating under this given path.

Also bin/mftf doctor command is not working

Here are my docker container details
docker-ps

Steps To Reproduce

  1. Run command : bin/mftf build:project
  2. Run command : bin/mftf doctor

bin/mftf build:project
mftf-build-project

Alternative MFTF checked below command, but it not worked for me

bin/mftf doctor
This command is not able to use .env and .credential file
mftf-doctor

I switched to src folder /var/www/html/magento246p3/src and run below command
vendor/bin/mftf doctor
Output:
image

I have attached my docker and mftf file for refernce.
docker-files.zip

Expected Result

  1. .env and .credential file should create under /var/www/html/magento246p3/src/dev/tests/acceptance/
  2. bin/mftf doctor should execute successfully

Actual Result

  1. These files are not creating under this given path /var/www/html/magento246p3/src/dev/tests/acceptance/.
  2. bin/mftf doctor gives error
@JesperHerrloff
Copy link

The given path is /var/www/html/dev/tests/acceptance as this is the path in the docker.
You could add a bind mount for the files in dev/tests if needed.

  • ./src/dev/tests:/var/www/html/dev/tests:cached

And restart the docker. So should the tests directory be synced.

when running vendor/bin/mftf locally it has probably no connection with the selenium container if not opened ports.

@mjogi-rave
Copy link
Author

mjogi-rave commented Jan 12, 2024

The given path is /var/www/html/dev/tests/acceptance as this is the path in the docker. You could add a bind mount for the files in dev/tests if needed.

  • ./src/dev/tests:/var/www/html/dev/tests:cached

And restart the docker. So should the tests directory be synced.

when running vendor/bin/mftf locally it has probably no connection with the selenium container if not opened ports.

Thanks @JesperHerrloff it is worked.

After running bin/mftf build:project successfully. I could not run bin/mftf doctor command. Here is error:
image

Note: Frontend and backend url working file in browser

Thanks

@JesperHerrloff
Copy link

Did you enable the path to commands.php in nginx.conf in your project folder?

Example below.

location ~* ^/dev/tests/acceptance/utils($|/) { root $MAGE_ROOT; location ~ ^/dev/tests/acceptance/utils/command.php { fastcgi_pass fastcgi_backend; fastcgi_index index.php; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; include fastcgi_params; } }

@mjogi-rave
Copy link
Author

Yes, I have added these line of code inside src/nginx.conf file

nginx conf

@mjogi-rave
Copy link
Author

I have fixed other errors. Now I am facing only one error related to Magento CLI.
See:
image

Magento CLI step is not working.

Thanks

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

No branches or pull requests

2 participants