why phpmyadmin does not log-in in laravel with docker?

  docker, laravel, mysql

help me friends. I noob in docker…excuse for my English

I’m trying login in phpmyadmin + laravel + docker, but I couldn’t do it. I’m confused.
The docker image that is used in many tutoriasl was remove from docker. I’m using the follow image:

link https://hub.docker.com/_/phpmyadmin

enter image description here

docker-compose.yml

version: '3.8'
services:
    laravel.test:
        build:
            context: ./vendor/laravel/sail/runtimes/8.0
            dockerfile: Dockerfile
            args:
                WWWGROUP: '${WWWGROUP}'
        image: sail-8.0/app
        ports:
            - '${APP_PORT:-80}:80'
        environment:
            WWWUSER: '${WWWUSER}'
            LARAVEL_SAIL: 1
        volumes:
            - '.:/var/www/html'
        networks:
            - sail
        depends_on:
            - mysql
    mysql:
        image: 'mysql:8.0'
        ports:
            - '${FORWARD_DB_PORT:-3306}:3306'
        environment:
            MYSQL_ROOT_PASSWORD: 123456
            MYSQL_DATABASE: fastfood-api
            MYSQL_USER: root
            MYSQL_PASSWORD: 123456
        volumes:
            - 'sailmysql:/var/lib/mysql'
        networks:
            - sail
    phpmyadmin:
        image: 'phpmyadmin'
        container_name: pma
        environment:
            PMA_HOST: mysql
            PMA_PASSWORD: 123456
            PMA_ARBITRARY: 1
        restart: always
        ports:
            - 8081:80
networks:
    sail:
        driver: bridge
volumes:
    sailmysql:
        driver: local
    sailredis:
        driver: local

from workbeanch, it get connection

Source: Docker Questions

LEAVE A COMMENT