Create user and database in MySQL 8

This post is actually more like a snippet (maybe I need just to make section for that here). But idea is that a lot of blogs just make a lot of unnecessary water around. So below is short answer how to creare database and user which has permissions to that MySQL database.

    CREATE DATABASE $DB_NAME;
    CREATE USER '$DB_USER'@'127.0.0.1' IDENTIFIED BY '$DB_PASSWORD';
    FLUSH PRIVILEGES;
    GRANT ALL PRIVILEGES ON $DB_NAME.* TO '$DB_USER'@'127.0.0.1';
    FLUSH PRIVILEGES;