Saturday, March 5, 2022

Deploy MySQL 8 in Podman

 in This Tutorial you will Learn " How To Run Deploy MySQL 8 in Podman

MySQL is an open-source relational database management system.
Podman is an OCI-compliant container runtime that works without a daemon.
_________________________________________________________________________________________
Server - Os:  Rocky Linux 8.5  64Bit      |    IP -192.168.1.20        |     Hostname - www.primaryhost.com
_________________________________________________________________________________________
cat /etc/system-release ; sestatus ; hostname ; hostname -I ; dnf groupinstall "Development Tools" -y
podman pull mysql:8  Or podman pull mysql:5.7
podman images
mkdir ~/mysql_data ;  cd mysql_data
podman run -d \
--name mysql-8 \
-p 3306:3306 \
-v ~/mysql_data:/var/lib/mysql \
-e MYSQL_ROOT_PASSWORD='StrongPass123' \
-e MYSQL_USER=dbuser \
-e MYSQL_PASSWORD='dbuserpass' \
-e MYSQL_DATABASE=testdb \
mysql:8
podman ps
podman exec -it mysql-8 /bin/bash
mysql -uroot -p'StrongPass123'
show databases;
exit
_________________________________________________________________________________________



No comments:

Post a Comment