alexcheng1982 / docker-magento2

Docker image for Magento Open Source 2
MIT License
382 stars 256 forks source link

Unable to see sample application #16

Closed AjmalMalik closed 6 years ago

AjmalMalik commented 6 years ago

I have followed the steps as mention on Mac 10.13.3.

When I run docker-compose up -d I get following Starting dockermagento2_db_1 ... done Starting dockermagento2_web_1 ... Starting dockermagento2_web_1 ... done

My host file has an entry as below: local.magento localhost

I am able to see sample data in db but when I try to access local.magento in safari I get Safari cannot find the server local.magento.

Any help will be much appreciated.

alexcheng1982 commented 6 years ago

If you run docker ps, can you see those containers are running?

After you changed the hosts file, have you run sudo killall -HUP mDNSResponder to flush the DNS, as shown in this page ( https://www.imore.com/how-edit-your-macs-hosts-file-and-why-you-would-want)?

On Tue, Feb 13, 2018 at 2:53 PM, AjmalMalik notifications@github.com wrote:

I have followed the steps as mention on Mac 10.13.3.

When I run docker-compose up -d I get following Starting dockermagento2_db_1 ... done Starting dockermagento2_web_1 ... Starting dockermagento2_web_1 ... done

My host file has an entry as below: local.magento localhost

I am able to see sample data in db but when I try to access local.magento in safari I get Safari cannot find the server local.magento.

Any help will be much appreciated.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/alexcheng1982/docker-magento2/issues/16, or mute the thread https://github.com/notifications/unsubscribe-auth/ABHgEEBsWTRO0IC-kfNixyuNHbJ6zMEhks5tUOscgaJpZM4SDGhA .

-- Regards Alex Cheng

AjmalMalik commented 6 years ago

Thank you Alex for coming back to me.

Yes, I did check last night, the containers were running and I did flush DNS cache. Below is how it is looking on docker ps this morning:

CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES 63eef7c497b8 alexcheng/magneto "/sbin/my_init" 9 hours ago Up 4 minutes 0.0.0.0:80->80/tcp dockermagento2_web_1 7b345ce1413d phpmyadmin/phpmyadmin "/run.sh phpmyadmin" 9 hours ago Up 4 minutes 0.0.0.0:8580->80/tcp dockermagento2_phpmyadmin_1 34be5ad4ee69 mysql:5.6.23 "/entrypoint.sh mysq…" 9 hours ago Up 4 minutes 3306/tcp dockermagento2_db_1

Any other thing that you could think that may have caused this.

alexcheng1982 commented 6 years ago

Try add following entry:

127.0.0.1 local.magento

On Tue, Feb 13, 2018 at 11:05 PM, AjmalMalik notifications@github.com wrote:

Thank you Alex for coming back to me.

Yes, I did check last night, the containers were running and I did flush DNS cache. Below is how it is looking on docker ps this morning:

CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES 63eef7c497b8 alexcheng/magneto "/sbin/my_init" 9 hours ago Up 4 minutes 0.0.0.0:80->80/tcp dockermagento2_web_1 7b345ce1413d phpmyadmin/phpmyadmin "/run.sh phpmyadmin" 9 hours ago Up 4 minutes 0.0.0.0:8580->80/tcp dockermagento2_phpmyadmin_1 34be5ad4ee69 mysql:5.6.23 "/entrypoint.sh mysq…" 9 hours ago Up 4 minutes 3306/tcp dockermagento2_db_1

Any other thing that you could think that may have caused this.

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/alexcheng1982/docker-magento2/issues/16#issuecomment-365214686, or mute the thread https://github.com/notifications/unsubscribe-auth/ABHgEGd1cIE9SVF6HxyQkI5vFux-NaLPks5tUV5vgaJpZM4SDGhA .

-- Regards Alex Cheng

AjmalMalik commented 6 years ago

It worked. I had to replace 127.0.0.1 localhost with what you have said above 127.0.0.1 local.magento.

Thank you so much for your help and putting together docker-magento for all of us.

Regards, Ajmal.

matthewJPham commented 6 years ago

Hello Alex, I get the same problem. I use Docker Toolbox on Win7. After installing completely i guess so, I can access phpmyadmin. However, the browser displayes error message that "can’t establish a connection to the server at local.magento" when I try to access sample app via either 127.0.0.1 or http://local.magento. I have configured the host file already. Please help me to solve it.