shopwareArchive / shopware-docker

A docker setup ready for shopware development
74 stars 37 forks source link

Init script failed #42

Closed MarcoFaul closed 5 years ago

MarcoFaul commented 5 years ago

Steps down: Built docker containers ssh into docker called ./psh.phar init script Step 2 Failed:

`(2/2) Starting

./sw.phar install:release -r latest -i ./shopware --db-host mysql --db-user app --db-password app --db-name shopware --shop-host localhost:8083

  [RuntimeException]                                          
  Could not find / create //.local/share/sw-cli-tools/assets  

Execution aborted, a subcommand failed!`

Thanks in advance!

teiling88 commented 5 years ago

image It works on my machine. I think you have a previous error which is leading in this issue. Can you please post the complete output from ./psh.phar docker:start ./psh.phar docker:ssh and ./psh.phar init ?

MarcoFaul commented 5 years ago

docker:start image

docker:ssh image

psh.phar init image

teiling88 commented 5 years ago

In my docker container the directory path ~/.local/share/sw-cli-tools/assets/ exists. Can you please check that on your system?

MarcoFaul commented 5 years ago

I newly rebuilt my containers and there is no such directory ~/.local

teiling88 commented 5 years ago

It exists in my container which I rebuild completely.

What kind of OS and docker version are you using?

MarcoFaul commented 5 years ago

first thank you for your help.

MacOS Mojave (10.14.5) and Latest - Docker 2.0.0.3

teiling88 commented 5 years ago

Is it possible for you to create this directories? I never tested this docker setup with MacOs.

MarcoFaul commented 5 years ago

I tried that before. Permissions denied even with admin rights.

wolkenheim commented 5 years ago

The problem is basically caused by the fact Docker and MacOs host try to access the same files and folders. And the Docker user has not sufficient rights to mkdir, hence the RuntimeError. The setup of the whole installation is quite complex so it took me a while but I was able to successfully run the installation by simply executing the sw.phar as root in the docker container.

This being said: instead of ./psh.phar docker:sshuse docker exec -it shopware-docker_app_server_1 bash to log into your shopware container as root and the installation should work.

colinmurphy commented 5 years ago

Thanks @shopfreelancer 👍

I can confirm I had the same issue on Mac and your solution worked for me :) I am running MacOS Mojave 10.14.5 with Docker version 2.1.0.1

teiling88 commented 5 years ago

Thanks for your feedback. Therefore I will close this issue!