arvatoSCM / dockerize-magento2

Composer package for dockerizing Magento 2
Apache License 2.0
112 stars 56 forks source link

Error when trying to run bin/console exec sampledata:deploy #30

Open jking6884 opened 7 years ago

jking6884 commented 7 years ago

image

jking6884 commented 7 years ago

I resolved this by forcing to download magento 2.2.1. However, I got a new error regarding the doctrine instantiator.

It seems that all of these problems are relating to the Php version. I haven't yet tried to update the php version in the Dockerfile you provide in this project to 7.1 before running bin/console install.

Perhaps that will work? Or will it cause other issues downstream?

brandontamm commented 7 years ago

@jking6884 - composer require zendframework/zend-code:3.1.0

Magento is using a caret for their zend-code dependency which requires the latest non-breaking version of zend-code..well..it breaks magento so that makes no sense but this will resolve your issue.

mdemirbilek commented 6 years ago

@brandontamm Thanks for your suggestion. But how will I use this line? I'm getting same error as @jking6884 has got. :(

0m3r commented 6 years ago

2018-01-16 16-44-40

➜  magento2 bin/console exec sampledata:deploy
Your requirements could not be resolved to an installable set of packages.

  Problem 1
    - doctrine/instantiator 1.1.0 requires php ^7.1 -> your PHP version (7.0.15) does not satisfy that requirement.
    - doctrine/instantiator 1.1.0 requires php ^7.1 -> your PHP version (7.0.15) does not satisfy that requirement.
    - doctrine/instantiator 1.1.0 requires php ^7.1 -> your PHP version (7.0.15) does not satisfy that requirement.
    - Installation request for doctrine/instantiator (locked at 1.1.0) -> satisfiable by doctrine/instantiator[1.1.0].

Installation failed, reverting ./composer.json to its original content.
There is an error during sample data deployment. Composer file will be reverted.

magento 2.2.2

PHP-FPM 7.0

https://hub.docker.com/r/arvato/magento2-php/~/dockerfile/ http://devdocs.magento.com/guides/v2.2/install-gde/system-requirements-tech.html

brandontamm commented 6 years ago

Magento and some modules loaded together via composer have compatibility issues with php versioning and which modules. Have to dig through JSON until you find the chain of culprit or culprits to find the needle in the haystack...a real pain for php development during upgrades.

On Jan 16, 2018, at 7:52 AM, 0m3r notifications@github.com wrote:

➜ magento2 bin/console exec sampledata:deploy Your requirements could not be resolved to an installable set of packages.

Problem 1

  • doctrine/instantiator 1.1.0 requires php ^7.1 -> your PHP version (7.0.15) does not satisfy that requirement.
  • doctrine/instantiator 1.1.0 requires php ^7.1 -> your PHP version (7.0.15) does not satisfy that requirement.
  • doctrine/instantiator 1.1.0 requires php ^7.1 -> your PHP version (7.0.15) does not satisfy that requirement.
  • Installation request for doctrine/instantiator (locked at 1.1.0) -> satisfiable by doctrine/instantiator[1.1.0].

Installation failed, reverting ./composer.json to its original content. There is an error during sample data deployment. Composer file will be reverted. magento 2.2.2

PHP-FPM 7.0

https://hub.docker.com/r/arvato/magento2-php/~/dockerfile/ http://devdocs.magento.com/guides/v2.2/install-gde/system-requirements-tech.html

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub, or mute the thread.

victorw999 commented 6 years ago

Can't deploy sample data. Stuck here: image

I've tried with: Magento 2.2.2, 2.1.11, 2.0.17

But the Dockerfile is PHP-FPM 7.0 https://github.com/arvatoSCM/dockerize-magento2/blob/develop/config/php/image/Dockerfile

How to get a Dockerfile that have PHP 7.1? I am not advanced enough to properly modify Dockerfile.

Changing 7.0 to 7.1 on these below didn't help:

~/magento2/config/php/image/Dockerfile 
~/magento2/vendor/arvatoscm/dockeriz-mageno2/config/php/image/Dockerfile 
brandontamm commented 6 years ago

Magento has massive composer-versioning issues within it's dependencies and can be made worse by upgrading PHP versions.. You'll have to dig through magento depencies and also dependencies of dependencies to get 2.

Trial and error until you get it all figured out :)

0m3r commented 6 years ago

Try to run composer update

docker ps 
docker exec -u 0 -ti "dockerizemagento2_php_1" bash

# curl --silent --show-error https://getcomposer.org/installer | php
# php composer.php update 
# exit

bin/console exec setup:upgrade

bin/console exec sampledata:deploy