First of all, I have two containers on docker, one is springboot jar, the other is redis, ip and port are 172.17.0.2 6379. The following is my redis configuration for application.yml
Execute this order
After $ dockerrun-p8080: 8080-namexa-01-linkredis-6379: xa-02xa01, etc/hosts in jar containers look like this.
Why is my springboot project still not linked to the redis database?
Well, I did it again because there is cache in some places, so this can still be ping