Apple Sillicon/M1 Mysql error, Wordpress-mariadb 연결
도커를 학습하면서 mysql 컨테이너를 다운받아 워드 프레스에 연결하려는데, 다음과 같은 에러가 났다.
1 | # docker run -d \ |
라고 명령어를 쳤고,
받은 에러는
Unable to find image ‘mysql:latest’ locally
latest: Pulling from library/mysql
docker: no matching manifest for linux/arm64/v8 in the manifest list entries.
See ‘docker run –help’.
즉, linux/arm64/v8 이 manifest 에 없다 뭐 그런 이야기인거 같은데 애플 실리콘 m1칩을 쓰면서 여러가지 산전수전을 많이 겪어서 stackoverflow에서 여러가지를 찾다가 찾는글이다.
어찌되었든 결론적으로 mysql 대신에 마리아db를 쓰라는건데,
https://docs.docker.com/docker-for-mac/apple-m1/
M1칩에 관한 docker docs에 보면 위와 같은 이슈가 있으니, mysql 대신에 mariadb이미지를 쓰라고 되어있다.
Not all images are available for ARM64. You can add
--platform linux/amd64
to run an Intel image under emulation.In particular, the mysql image is not available for ARM64. You can work around this issue by using a mariadb image.
1 | # docker run -d \ |
위의 명령어로 mariadb를 다운받고 실행시켜 준다.
1 | # docker run -d \ |
위의 명령어로 wordpress를 다운받고 실행시켜 준다.
그 다음, docker ps 명령어로 확인해보면,
1 | # docker ps |
위의 결과를 보면 PORTS에서 0.0.0.0:49157 -> 80으로 호스트의 port 49157로 접근을 하면, 80으로 포트포워딩을 해준다고 나와있다.
확인해 보기 위해서 위의 주소로 들어가면

이렇게 워드 프레스 초기 설정화면이 뜨는것을 확인 할 수 있다.