LaraDocker使用过程中遇到的问题记录

LaraDock 无法启动Mysql 解决方法

其实这个问题已经存在很久了,每次都要去官方issue里面去翻,索性直接记录在雷竞技最新版下载中,方便日后查找

解决方法

docker-compose.yml mysql服务下添加user: "1000:50"

添加后的mysql部分如下:

### MySQL Container #########################################
     mysql:
       user: "1000:50"
       build:
         context: ./mysql
         args:
           - MYSQL_VERSION=${MYSQL_VERSION}
       environment:
         - MYSQL_DATABASE=${MYSQL_DATABASE}
         - MYSQL_USER=${MYSQL_USER}
         - MYSQL_PASSWORD=${MYSQL_PASSWORD}
         - MYSQL_ROOT_PASSWORD=${MYSQL_ROOT_PASSWORD}
         - TZ=${WORKSPACE_TIMEZONE}
       volumes:
         - ${DATA_SAVE_PATH}/mysql:/var/lib/mysql
         - ${MYSQL_ENTRYPOINT_INITDB}:/docker-entrypoint-initdb.d
       ports:
         - "${MYSQL_PORT}:3306"
       networks:
         - backend

参考资料

laradoc_mysql container fails to start: '/var/lib/mysql/is_writable' (Errcode: 13 - Permission denied)