Hi Folks!
I'm trying to install confluence, using mysql in a docker containerized environment.
I've never installed confluence before and I'm still quite green when it comes to building with docker.
Host OS is Ubuntu 18.04.02. All versions of software are latest as of this writing.
So far I have the following images:
atlassian/confluence-server
mysql
I know I need to add the JDBC driver to confluence to use the database, so I've set up a Dockerfile so I can build a custom image:
FROM atlassian/confluence-server
COPY mysql-connector-java-5.1.47.jar /opt/atlassian/confluence/confluence/WEB-INF/lib
I can successfully create the new image and have verified that the connector is in the right place when I run a container from it.
Now I'm trying to write a docker-compose.yml to start these, get them connected and make sure they're always on. This I am VERY unsure about. I think it should work but I'm writing this question, aren't I? 
Please trust that I have whitespacing correct - I can't seem to paste this into a codeblock.
version: '3'
services:
confl-mysql:
image: mysql
restart: always
networks:
- confluencenet
volumes:
- /data/mysql:/var/lib/mysql
environment:
- MYSQL_RANDOM_ROOT_PASSWORD=yes
- MYSQL_DATABASE=confluence
- MYSQL_USER=confluence
- MYSQL_PASSWORD=confluence
command: [mysqld, --character-set-server=utf8, --collation-server=utf8_bin, --default-storage-engine=INNODB, --max_allowed_packet=256M, --innodb_log_file_size=2GB, --transaction-isolation=READ-COMMITTED,
--binlog_format=row]
confluence:
image: confluence-mysql-driver
restart: always
networks:
- confluencenet
volumes:
- /data/confluence:/var/atlassian/application-data/confluence
- /data/mysql:/var/lib/mysql
ports:
- 8090:8090
- 8091:8091
networks:
confluencenet: {}
Both containers start when I perform 'docker-compose up' and I can hit the confluence page, but when it comes time to set up the database I can't for the life of me figure out how to connect to the mysql.

I've tried with 'localhost', 'mysql', the container name 'confl-mysql_1' all with no success:
Can't reach database server or port
SQLState - 08S01
com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: Communications link failure The last packet sent successfully to the server was 0 milliseconds ago. The driver has not received any packets from the server.
I'd greatly appreciate any support or guidance to help get this working!
Thanks!