Start redis after network is online (#7639)

The two lines allow systemd to start redis.service after the network is online. Only after the network is online that Redis could bind to IP address other than 127.0.0.1 during initial boot up process.

(cherry picked from commit 1c6caaaef7d69e05b526626f284bb822fc82dd9f)
This commit is contained in:
YoongHM 2020-08-11 17:30:32 +08:00 committed by Oran Agra
parent 9c7c0c511a
commit 5e0a3e2626

View File

@ -20,6 +20,8 @@ Description=Redis data structure server
Documentation=https://redis.io/documentation
#Before=your_application.service another_example_application.service
#AssertPathExists=/var/lib/redis
Wants=network-online.target
After=network-online.target
[Service]
ExecStart=/usr/local/bin/redis-server --supervised systemd --daemonize no