Version '5.7.26*' for 'mysql-server' was not found in ubuntu:bionic-20190612
It seems there is an issue with the mysql-server current version in the docker file because building an image give the following error.
E: Version '5.7.26*' for 'mysql-server' was not found
I have found on the official website that 5.7.26 is not available to download rather 5.7.28 is available. So, I have changed the version to MYSQL_VERSION=5.7.28 it worked flawlessly.
Docker host: CentOS 7 Docker version: 19.03.5
[user@hostname]$ docker info
Client:
Debug Mode: false
Server:
Containers: 11
Running: 0
Paused: 0
Stopped: 11
Images: 78
Server Version: 19.03.5
Storage Driver: devicemapper
Pool Name: docker-259:1-1668633-pool
Pool Blocksize: 65.54kB
Base Device Size: 10.74GB
Backing Filesystem: xfs
Udev Sync Supported: true
Data file: /dev/loop0
Metadata file: /dev/loop1
Data loop file: /var/lib/docker/devicemapper/devicemapper/data
Metadata loop file: /var/lib/docker/devicemapper/devicemapper/metadata
Data Space Used: 3.706GB
Data Space Total: 107.4GB
Data Space Available: 9.403GB
Metadata Space Used: 24.09MB
Metadata Space Total: 2.147GB
Metadata Space Available: 2.123GB
Thin Pool Minimum Free Space: 10.74GB
Deferred Removal Enabled: true
Deferred Deletion Enabled: true
Deferred Deleted Device Count: 0
Library Version: 1.02.158-RHEL7 (2019-05-13)
Logging Driver: json-file
Cgroup Driver: cgroupfs
Plugins:
Volume: local
Network: bridge host ipvlan macvlan null overlay
Log: awslogs fluentd gcplogs gelf journald json-file local logentries splunk syslog
Swarm: inactive
Runtimes: runc
Default Runtime: runc
Init Binary: docker-init
containerd version: b34a5c8af56e510852c35414db4c1f4fa6172339
runc version: 3e425f80a8c931f88e6d94a8c831b9d5aa481657
init version: fec3683
Security Options:
seccomp
Profile: default
Kernel Version: 3.10.0-1062.7.1.el7.x86_64
Operating System: CentOS Linux 7 (Core)
OSType: linux
Architecture: x86_64
CPUs: 2
Total Memory: 1.758GiB
Name: hostname
ID: 6DJA:WYXO:337B:WV53:Y7BX:VGYO:M3MP:ZRAL:N3AA:SLKG:MWSV:O4EB
Docker Root Dir: /var/lib/docker
Debug Mode: false
Registry: https://index.docker.io/v1/
Labels:
Experimental: false
Insecure Registries:
127.0.0.0/8
Live Restore Enabled: false
Just change the third command in Dockerfile
ENV MYSQL_USER=mysql \
MYSQL_VERSION=8.0 \
MYSQL_DATA_DIR=/var/lib/mysql \
MYSQL_RUN_DIR=/run/mysqld \
MYSQL_LOG_DIR=/var/log/mysql
This is basically using the 8.0 version of mysql
@KriAga I have changed the same command to 5.7.28 back then to make it work as 5.7.26 was not available to download at that time. Also, I did try the change which you have suggested but it doesn't work either unfortunately.
Currently, I have tried to build again with 5.7.28 but it failed because now it's not available to download.
So, I think whoever is going to build the image from Dockerfile first needs to verify the currently available version to download. Then change the value of MYSQL_VERSION version accordingly.