I'm running the latest build of the Docker Apple Silicon Preview. I created the tutorial container/images and it works fine. When I went to create a custom YAML file and run docker-compose I get the following error when pulling mysql:
ERROR: no matching manifest for linux/arm64/v8 in the manifest list entries
Here is a snippet from my YAMl file:
version: '3'
services:
# Database
db:
image: mysql-server:5.7
volumes:
- db_data:/var/lib/mysql
restart: always
environment:
MYSQL_ROOT_PASSWORD: pass
MYSQL_DATABASE: wp
MYSQL_USER: wp
MYSQL_PASSWORD: wp
networks:
- wpsite
I've tried :latest and :8 which result in the same error. It pulls phpmyadmin and wordpress fine.
Well, technically it will not solve your issue (running MySQL on ARM), but for the time being, you could add platform
to your service like:
services:
db:
platform: linux/x86_64
image: mysql:5.7
...
Alternatively, consider using MariaDB, which should work as a drop-in replacement like e.g. this:
services:
db:
image: mariadb:10.5.8
...
Both ways work for me on M1 with the Docker Preview
same problem for m1 mac just run this command
docker pull --platform linux/x86_64 mysql
From this answer, I added this to my local docker-compose.override.yml
services:
mysql:
platform: linux/amd64
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With