Update /etc/my.cnf
[client]
port=3306
default-character-set=utf8mb4
[mysql]
default-character-set=utf8mb4
[mysqld]
character-set-server=utf8mb4
collation-server=utf8mb4_bin
Set the database to:
ALTER SCHEMA `<DATABASE>` DEFAULT COLLATE utf8mb4_bin ;
Check output of the below which should now mention utf8mb4:
show variables like '%colla%';
Run a test intert with a character such as: ć
Also helpful in getting the database to store UTF8 was the following article by Atlassian. While they set up as utf8 which supports 3 bytes per character, we want utf8mb4 which supports 4 bytes per character. So while you probably want utf8, what you actually want to set is utf8mb4 more info.