Docker Compose No such image: mysql/mysql-server:8.0

Hello I have a problem with docker compose, when I deploy my app I get an error :
Error response from daemon: No such image: mysql/mysql-server:8.0
I don’t understand why i have this error, pleas help me.

Here is some information that can give context: I deploy my app on a raspeberry pi 5 ubuntu server thanks to coolify, I deployed this app on my windows and it works very well.
I use sail to create the docker composebut even with a hand-made docker compound I have the same problem.

Here is some file that might help you:

RAW docker-compose.yml

services:
    laravel.test:
        build:
            context: ./vendor/laravel/sail/runtimes/8.3
            dockerfile: Dockerfile
            args:
                WWWGROUP: '${WWWGROUP}'
        image: sail-8.3/app
        extra_hosts:
            - 'host.docker.internal:host-gateway'
        ports:
            - '${APP_PORT:-80}:80'
            - '${VITE_PORT:-5173}:${VITE_PORT:-5173}'
        environment:
            WWWUSER: '${WWWUSER}'
            LARAVEL_SAIL: 1
            XDEBUG_MODE: '${SAIL_XDEBUG_MODE:-off}'
            XDEBUG_CONFIG: '${SAIL_XDEBUG_CONFIG:-client_host=host.docker.internal}'
            IGNITION_LOCAL_SITES_PATH: '${PWD}'
        volumes:
            - '.:/var/www/html'
        networks:
            - sail
        depends_on:
            - mysql
    mysql:
        image: 'mysql/mysql-server:8.0'
        ports:
            - '${FORWARD_DB_PORT:-3306}:3306'
        environment:
            MYSQL_ROOT_PASSWORD: '${DB_PASSWORD}'
            MYSQL_ROOT_HOST: '%'
            MYSQL_DATABASE: '${DB_DATABASE}'
            MYSQL_USER: '${DB_USERNAME}'
            MYSQL_PASSWORD: '${DB_PASSWORD}'
            MYSQL_ALLOW_EMPTY_PASSWORD: 1
        volumes:
            - 'sail-mysql:/var/lib/mysql'
            - './vendor/laravel/sail/database/mysql/create-testing-database.sh:/docker-entrypoint-initdb.d/10-create-testing-database.sh'
        networks:
            - sail
        healthcheck:
            test:
                - CMD
                - mysqladmin
                - ping
                - '-p${DB_PASSWORD}'
            retries: 3
            timeout: 5s
networks:
    sail:
        driver: bridge
volumes:
    sail-mysql:
        driver: local

coolifyed docker-compose.yml

services:
  laravel.test:
    build:
      context: ./vendor/laravel/sail/runtimes/8.3
      dockerfile: Dockerfile
      args:
        WWWGROUP: '${WWWGROUP}'
    image: sail-8.3/app
    extra_hosts:
      - 'host.docker.internal:host-gateway'
    ports:
      - '${APP_PORT:-80}:80'
      - '${VITE_PORT:-5173}:${VITE_PORT:-5173}'
    environment:
      WWWUSER: '${WWWUSER}'
      LARAVEL_SAIL: 1
      XDEBUG_MODE: '${SAIL_XDEBUG_MODE:-off}'
      XDEBUG_CONFIG: '${SAIL_XDEBUG_CONFIG:-client_host=host.docker.internal}'
      IGNITION_LOCAL_SITES_PATH: '${PWD}'
    volumes:
      - '/data/coolify/applications/c4k0o0w:/var/www/html'
    networks:
      sail: null
      c4k0o0w: null
    depends_on:
      - mysql
    labels:
      - coolify.managed=true
      - coolify.version=4.0.0-beta.294
      - coolify.applicationId=2
      - coolify.type=application
      - coolify.name=laravel.test-c4k0o0w-151640862985
      - coolify.pullRequestId=0
    restart: unless-stopped
    container_name: laravel.test-c4k0o0w-151640862985
  mysql:
    image: 'mysql/mysql-server:8.0'
    ports:
      - '${FORWARD_DB_PORT:-3306}:3306'
    environment:
      MYSQL_ROOT_PASSWORD: '${DB_PASSWORD}'
      MYSQL_ROOT_HOST: '%'
      MYSQL_DATABASE: '${DB_DATABASE}'
      MYSQL_USER: '${DB_USERNAME}'
      MYSQL_PASSWORD: '${DB_PASSWORD}'
      MYSQL_ALLOW_EMPTY_PASSWORD: 1
    volumes:
      - 'sail-mysql:/var/lib/mysql'
      - '/data/coolify/applications/c4k0o0w/vendor/laravel/sail/database/mysql/create-testing-database.sh:/docker-entrypoint-initdb.d/10-create-testing-database.sh'
    networks:
      sail: null
      c4k0o0w: null
    healthcheck:
      test:
        - CMD
        - mysqladmin
        - ping
        - '-p${DB_PASSWORD}'
      retries: 3
      timeout: 5s
    labels:
      - coolify.managed=true
      - coolify.version=4.0.0-beta.294
      - coolify.applicationId=2
      - coolify.type=application
      - coolify.name=mysql-c4k0o0w-151640875658
      - coolify.pullRequestId=0
    restart: unless-stopped
    container_name: mysql-c4k0o0w-151640875658
volumes:
  sail-mysql:
    driver: local
networks:
  sail: null
  c4k0o0w:
    name: c4k0o0w
    external: true

Deployement logs

[2024-Jun-08 14:17:04.208606] Starting deployment of august7337/-new--portfolio:main-c4k0o0w to localhost.
[2024-Jun-08 14:17:04.428845] Preparing container with helper image: ghcr.io/coollabsio/coolify-helper:latest.
[2024-Jun-08 14:18:52.242092] ----------------------------------------
[2024-Jun-08 14:18:52.246331] Importing August7337/New-Portfolio:main (commit sha HEAD) to /artifacts/e004skk.
[2024-Jun-08 14:19:42.214887] Pulling & building required images.
[2024-Jun-08 14:19:42.565312] Removing old containers.
[2024-Jun-08 14:19:42.699492] Starting new application.
[2024-Jun-08 15:00:50.537029] Oops something is not okay, are you okay? 😢

[2024-Jun-08 15:00:50.574208] mysql Pulling
022417830bcf Pulling fs layer
fe10b20dcdae Pulling fs layer
624f2f22548b Pulling fs layer
0eb07ea8ad2a Pulling fs layer
8b517dfb74ad Pulling fs layer
ebef84d68e30 Pulling fs layer
604975d7252e Pulling fs layer
0eb07ea8ad2a Waiting
8b517dfb74ad Waiting
ebef84d68e30 Waiting
604975d7252e Waiting
fe10b20dcdae Downloading [> ] 21.9kB/2.091MB
022417830bcf Downloading [> ] 473.3kB/46.84MB
624f2f22548b Downloading [> ] 538.9kB/114.5MB
624f2f22548b Downloading [> ] 1.08MB/114.5MB
fe10b20dcdae Downloading [=========> ] 407.8kB/2.091MB
022417830bcf Downloading [=> ] 1.42MB/46.84MB
fe10b20dcdae Downloading [============================================> ] 1.846MB/2.091MB
fe10b20dcdae Download complete
624f2f22548b Downloading [=> ] 3.226MB/114.5MB
022417830bcf Downloading [==> ] 1.899MB/46.84MB
624f2f22548b Downloading [==> ] 4.831MB/114.5MB
022417830bcf Downloading [===> ] 3.332MB/46.84MB
022417830bcf Downloading [=====> ] 4.766MB/46.84MB
624f2f22548b Downloading [===> ] 8.067MB/114.5MB
022417830bcf Downloading [======> ] 6.191MB/46.84MB
624f2f22548b Downloading [====> ] 10.21MB/114.5MB
022417830bcf Downloading [=======> ] 7.142MB/46.84MB
624f2f22548b Downloading [=====> ] 11.82MB/114.5MB
022417830bcf Downloading [=========> ] 9.042MB/46.84MB
624f2f22548b Downloading [======> ] 13.97MB/114.5MB
022417830bcf Downloading [==========> ] 9.992MB/46.84MB
624f2f22548b Downloading [=======> ] 16.14MB/114.5MB
624f2f22548b Downloading [========> ] 18.82MB/114.5MB
022417830bcf Downloading [=============> ] 12.37MB/46.84MB
624f2f22548b Downloading [========> ] 20.44MB/114.5MB
022417830bcf Downloading [==============> ] 13.81MB/46.84MB
624f2f22548b Downloading [=========> ] 21.52MB/114.5MB
022417830bcf Downloading [===============> ] 14.28MB/46.84MB
624f2f22548b Downloading [=========> ] 22.06MB/114.5MB
624f2f22548b Downloading [==========> ] 24.21MB/114.5MB
022417830bcf Downloading [================> ] 15.71MB/46.84MB
022417830bcf Downloading [==================> ] 17.14MB/46.84MB
624f2f22548b Downloading [===========> ] 26.9MB/114.5MB
022417830bcf Downloading [===================> ] 18.09MB/46.84MB
624f2f22548b Downloading [============> ] 27.98MB/114.5MB
624f2f22548b Downloading [=============> ] 30.66MB/114.5MB
022417830bcf Downloading [=====================> ] 20MB/46.84MB
624f2f22548b Downloading [==============> ] 32.27MB/114.5MB
624f2f22548b Downloading [==============> ] 33.35MB/114.5MB
022417830bcf Downloading [======================> ] 21.42MB/46.84MB
022417830bcf Downloading [========================> ] 22.85MB/46.84MB
624f2f22548b Downloading [===============> ] 36.57MB/114.5MB
022417830bcf Downloading [========================> ] 23.32MB/46.84MB
624f2f22548b Downloading [=================> ] 39.8MB/114.5MB
022417830bcf Downloading [==========================> ] 25.24MB/46.84MB
624f2f22548b Downloading [==================> ] 41.43MB/114.5MB
022417830bcf Downloading [============================> ] 26.67MB/46.84MB
624f2f22548b Downloading [===================> ] 43.56MB/114.5MB
022417830bcf Downloading [=============================> ] 27.63MB/46.84MB
624f2f22548b Downloading [===================> ] 45.16MB/114.5MB
022417830bcf Downloading [==============================> ] 28.58MB/46.84MB
624f2f22548b Downloading [====================> ] 47.29MB/114.5MB
022417830bcf Downloading [===============================> ] 29.06MB/46.84MB
624f2f22548b Downloading [=====================> ] 49.44MB/114.5MB
022417830bcf Downloading [================================> ] 30.48MB/46.84MB
624f2f22548b Downloading [======================> ] 51.03MB/114.5MB
022417830bcf Downloading [=================================> ] 31.43MB/46.84MB
624f2f22548b Downloading [======================> ] 52.1MB/114.5MB
022417830bcf Downloading [==================================> ] 31.91MB/46.84MB
624f2f22548b Downloading [=======================> ] 53.18MB/114.5MB
624f2f22548b Downloading [========================> ] 55.34MB/114.5MB
022417830bcf Downloading [===================================> ] 33.33MB/46.84MB
624f2f22548b Downloading [========================> ] 56.95MB/114.5MB
022417830bcf Downloading [====================================> ] 34.28MB/46.84MB
624f2f22548b Downloading [=========================> ] 58.02MB/114.5MB
624f2f22548b Downloading [==========================> ] 60.7MB/114.5MB
022417830bcf Downloading [======================================> ] 35.72MB/46.84MB
022417830bcf Downloading [=======================================> ] 36.67MB/46.84MB
624f2f22548b Downloading [===========================> ] 62.85MB/114.5MB
022417830bcf Downloading [========================================> ] 37.62MB/46.84MB
624f2f22548b Downloading [============================> ] 64.99MB/114.5MB
624f2f22548b Downloading [=============================> ] 66.61MB/114.5MB
022417830bcf Downloading [=========================================> ] 38.57MB/46.84MB
022417830bcf Downloading [=========================================> ] 39.04MB/46.84MB
624f2f22548b Downloading [=============================> ] 68.22MB/114.5MB
624f2f22548b Downloading [===============================> ] 71.44MB/114.5MB
022417830bcf Downloading [===========================================> ] 40.47MB/46.84MB
624f2f22548b Downloading [================================> ] 73.59MB/114.5MB
022417830bcf Downloading [============================================> ] 41.41MB/46.84MB
624f2f22548b Downloading [=================================> ] 75.74MB/114.5MB
022417830bcf Downloading [=============================================> ] 42.37MB/46.84MB
624f2f22548b Downloading [=================================> ] 77.87MB/114.5MB
022417830bcf Downloading [==============================================> ] 43.32MB/46.84MB
624f2f22548b Downloading [==================================> ] 80.02MB/114.5MB
022417830bcf Downloading [===============================================> ] 44.26MB/46.84MB
624f2f22548b Downloading [===================================> ] 82.17MB/114.5MB
022417830bcf Downloading [================================================> ] 45.21MB/46.84MB
624f2f22548b Downloading [====================================> ] 84.31MB/114.5MB
022417830bcf Downloading [=================================================> ] 46.16MB/46.84MB
624f2f22548b Downloading [=====================================> ] 86.46MB/114.5MB
022417830bcf Verifying Checksum
022417830bcf Download complete
624f2f22548b Downloading [======================================> ] 89.14MB/114.5MB
624f2f22548b Downloading [=======================================> ] 91.29MB/114.5MB
624f2f22548b Downloading [=========================================> ] 93.98MB/114.5MB
624f2f22548b Downloading [==========================================> ] 96.66MB/114.5MB
624f2f22548b Downloading [===========================================> ] 99.34MB/114.5MB
624f2f22548b Downloading [============================================> ] 102MB/114.5MB
624f2f22548b Downloading [=============================================> ] 104.7MB/114.5MB
624f2f22548b Downloading [==============================================> ] 107.4MB/114.5MB
624f2f22548b Downloading [================================================> ] 110.6MB/114.5MB
624f2f22548b Downloading [=================================================> ] 113.3MB/114.5MB
624f2f22548b Verifying Checksum
624f2f22548b Download complete
0eb07ea8ad2a Downloading [==================================================>] 694B/694B
0eb07ea8ad2a Verifying Checksum
0eb07ea8ad2a Download complete
ebef84d68e30 Downloading [==================> ] 1.369kB/3.785kB
ebef84d68e30 Downloading [==================================================>] 3.785kB/3.785kB
ebef84d68e30 Download complete
8b517dfb74ad Downloading [==================================================>] 274B/274B
8b517dfb74ad Verifying Checksum
8b517dfb74ad Download complete
604975d7252e Downloading [===============================================> ] 721B/765B
604975d7252e Downloading [==================================================>] 765B/765B
604975d7252e Verifying Checksum
604975d7252e Download complete
022417830bcf Extracting [> ] 491.5kB/46.84MB
022417830bcf Extracting [======> ] 6.39MB/46.84MB
022417830bcf Extracting [=======> ] 7.373MB/46.84MB
022417830bcf Extracting [===========> ] 10.81MB/46.84MB
022417830bcf Extracting [==================> ] 17.2MB/46.84MB
022417830bcf Extracting [==========================> ] 24.58MB/46.84MB
022417830bcf Extracting [================================> ] 30.47MB/46.84MB
022417830bcf Extracting [====================================> ] 34.41MB/46.84MB
022417830bcf Extracting [=======================================> ] 37.36MB/46.84MB
022417830bcf Extracting [=============================================> ] 42.27MB/46.84MB
022417830bcf Extracting [===============================================> ] 44.73MB/46.84MB
022417830bcf Extracting [================================================> ] 45.22MB/46.84MB
022417830bcf Extracting [==================================================>] 46.84MB/46.84MB
022417830bcf Pull complete
fe10b20dcdae Extracting [> ] 32.77kB/2.091MB
fe10b20dcdae Extracting [=====> ] 229.4kB/2.091MB
fe10b20dcdae Extracting [==================================================>] 2.091MB/2.091MB
fe10b20dcdae Extracting [==================================================>] 2.091MB/2.091MB
fe10b20dcdae Pull complete
624f2f22548b Extracting [> ] 557.1kB/114.5MB
624f2f22548b Extracting [> ] 1.671MB/114.5MB
624f2f22548b Extracting [=> ] 3.342MB/114.5MB
624f2f22548b Extracting [==> ] 5.014MB/114.5MB
624f2f22548b Extracting [==> ] 6.685MB/114.5MB
624f2f22548b Extracting [===> ] 8.356MB/114.5MB
624f2f22548b Extracting [====> ] 9.47MB/114.5MB
624f2f22548b Extracting [====> ] 11.14MB/114.5MB
624f2f22548b Extracting [======> ] 13.93MB/114.5MB
624f2f22548b Extracting [=======> ] 17.83MB/114.5MB
624f2f22548b Extracting [========> ] 20.61MB/114.5MB
624f2f22548b Extracting [============> ] 28.97MB/114.5MB
624f2f22548b Extracting [===============> ] 36.21MB/114.5MB
624f2f22548b Extracting [================> ] 38.44MB/114.5MB
624f2f22548b Extracting [==================> ] 41.78MB/114.5MB
624f2f22548b Extracting [==================> ] 42.34MB/114.5MB
624f2f22548b Extracting [==================> ] 43.45MB/114.5MB
624f2f22548b Extracting [===================> ] 44.01MB/114.5MB
624f2f22548b Extracting [===================> ] 44.56MB/114.5MB
624f2f22548b Extracting [===================> ] 45.12MB/114.5MB
624f2f22548b Extracting [===================> ] 45.68MB/114.5MB
624f2f22548b Extracting [====================> ] 46.79MB/114.5MB
624f2f22548b Extracting [====================> ] 47.35MB/114.5MB
624f2f22548b Extracting [====================> ] 47.91MB/114.5MB
624f2f22548b Extracting [=====================> ] 48.46MB/114.5MB
624f2f22548b Extracting [=====================> ] 49.02MB/114.5MB
624f2f22548b Extracting [=====================> ] 49.58MB/114.5MB
624f2f22548b Extracting [=====================> ] 50.14MB/114.5MB
624f2f22548b Extracting [======================> ] 50.69MB/114.5MB
624f2f22548b Extracting [======================> ] 51.25MB/114.5MB
624f2f22548b Extracting [======================> ] 51.81MB/114.5MB
624f2f22548b Extracting [======================> ] 52.36MB/114.5MB
624f2f22548b Extracting [=======================> ] 52.92MB/114.5MB
624f2f22548b Extracting [=======================> ] 53.48MB/114.5MB
624f2f22548b Extracting [=======================> ] 54.03MB/114.5MB
624f2f22548b Extracting [=======================> ] 54.59MB/114.5MB
624f2f22548b Extracting [========================> ] 55.15MB/114.5MB
624f2f22548b Extracting [========================> ] 56.26MB/114.5MB
624f2f22548b Extracting [===========================> ] 62.95MB/114.5MB
624f2f22548b Extracting [==============================> ] 70.19MB/114.5MB
624f2f22548b Extracting [===============================> ] 71.86MB/114.5MB
624f2f22548b Extracting [================================> ] 73.53MB/114.5MB
624f2f22548b Extracting [================================> ] 74.65MB/114.5MB
624f2f22548b Extracting [================================> ] 75.2MB/114.5MB
624f2f22548b Extracting [==================================> ] 77.99MB/114.5MB
624f2f22548b Extracting [===================================> ] 80.22MB/114.5MB
624f2f22548b Extracting [=====================================> ] 85.79MB/114.5MB
624f2f22548b Extracting [=========================================> ] 95.81MB/114.5MB
624f2f22548b Extracting [============================================> ] 103.1MB/114.5MB
624f2f22548b Extracting [===============================================> ] 108.6MB/114.5MB
624f2f22548b Extracting [================================================> ] 111.4MB/114.5MB
624f2f22548b Extracting [==================================================>] 114.5MB/114.5MB
624f2f22548b Pull complete
0eb07ea8ad2a Extracting [==================================================>] 694B/694B
0eb07ea8ad2a Extracting [==================================================>] 694B/694B
0eb07ea8ad2a Pull complete
8b517dfb74ad Extracting [==================================================>] 274B/274B
8b517dfb74ad Extracting [==================================================>] 274B/274B
8b517dfb74ad Pull complete
ebef84d68e30 Extracting [==================================================>] 3.785kB/3.785kB
ebef84d68e30 Extracting [==================================================>] 3.785kB/3.785kB
ebef84d68e30 Pull complete
604975d7252e Extracting [==================================================>] 765B/765B
604975d7252e Extracting [==================================================>] 765B/765B
604975d7252e Pull complete
mysql Pulled
Network e004skk_sail Creating
Network e004skk_sail Created
Volume "e004skk_sail-mysql" Creating
Volume "e004skk_sail-mysql" Created
Container mysql-c4k0o0w-141941643611 Creating
Error response from daemon: No such image: mysql/mysql-server:8.0

Thx

Have you tried to siply use docker compose up -d without any helper or deployment tool after you had the compose file? The error could be an issue with the tools you are using, not strictly related to Compose or Docker.

I just tried and I still have the same error

What is the Docker version and docker compose version?

Maybe the problem is with the architecture. I guess that rpi 5 have arm cpu (I’m not an rpi user). In some cases the architecture were not correctly detected so the container could not start. It started on my macOS which has arm cpu and docker pull shouldn’t have worked it the container can’t run, and wrong architetcure usually gives a different error message, but I have no better idea yet. That would explain why it worked on Windows which is more often with amd64 cpu. You could try adding

platform: linux/arm64

to the myssql service in compse.

Also make sure that nothing deleted the image in the meantime. Try running

docker image inspect mysql/mysql-server:8.0
1 Like

thank you very much, thanks to you, I found the problem, it comes from a coolify script (automated cleanup) which every 10 minutes deletes the docker images which are not in use.

For those with the same bug, follow these steps:

  • stop coolify containers
  • pull the docker image
  • reboot the server
  • directly run the docker image
  • and now you can deploy your app

Thank you for information.