It's because your zabbix, is running in a contained environment.
According to the page you linked,
You will create and have a container in docker for zabbix mysql, nginx, zabbix server, agent and javagateway.. #Container #1 and #Container #2 mysql and java agent container will be created. Instructions, In #Container #3, creates zabbix server and links to mysql to javagateway, #Container #4 creates nginx container and links mysql and zabbix server to it, and #container #5, creating zabbix agent, and also linking zabbix server to mysql.
Your linking (--linking) all these containers so they can communicate with one another. (mysql, zabbix server, javagateway, nginx, and zabbix agent)
The config's tutorial, allows these containers to communicate with the mysql database.. (--link Depreciated)
Without this linking, they won't be able to talk to one another and would be isolated to there own lan / network.
Think of --link like putting containers on the same network or a direct link to one another so they can communicate with each other.
This is why you cannot connect or use the AAPanel mysql, as your containers have no way of knowing how to get to the aapanel's network, (127.0.0.1/24 / 192.168.1.29/24 ETC.) and your linking to the Mysql created in docker.
Since your docker containers are on a isolated network created by the docker host. ( example: 172.17.0.1) they will only be able to communicate within the contained docker environments network. You can achieve what you want by changing your code up a bit to use your docker host.
To use your internal IP address or connect to the special DNS name host.docker.internal which will resolve to the internal IP address used by the host.
Add --add-host=host.docker.internal:host-gateway
to your Docker command to enable this feature.
The --add-host flag adds an entry to the container’s /etc/hosts file. The value shown above maps host.docker.internal to the container’s host gateway, which matches the real localhost value. You could replace host.docker.internal with your own string if you prefer.
Connecting to the Host Network
Docker provides a host network which lets containers share your host’s networking stack. This approach means localhost inside a container resolves to the physical host, instead of the container itself.
Containers are launched with the host network by adding the --network=host flag:
docker run -d --network=host my-container:latest
Now your container can reference localhost or 127.0.0.1 directly.
Hope this helps out...