ERROR: no matching manifest for linux/arm64/v8 in the manifest list entries

Mac笔记本m1芯片,使用docker 创建mysql的时候容易出现这个错误,解决方法:
添加 platform: linux/x86_64

version: '3.7'
services:
    database:
        image: 'mysql:5.7'
        environment:
            MYSQL_ROOT_PASSWORD: password
            MYSQL_DATABASE: teebblog
        ports:
            # To allow the host machine to access the ports below, modify the lines below.
            # For example, to allow the host to connect to port 3306 on the container, you would change
            # "3306" to "3306:3306". Where the first port is exposed to the host and the second is the container port.
            # See https://docs.docker.com/compose/compose-file/#ports for more information.
            - '8888:3306'
        platform: linux/x86_64

©著作权归作者所有,转载或内容合作请联系作者
平台声明:文章内容(如有图片或视频亦包括在内)由作者上传并发布,文章内容仅代表作者本人观点,简书系信息发布平台,仅提供信息存储服务。

推荐阅读更多精彩内容