An application depends on mongodb. The application and mongodb both start on boot as services.
app.service containts next line:
Unfortunately, the application fails (with connection to database error), I guess, because the mongodb needs some time to startup and be ready to connections (if I start the app later, everything is ok).
It looks like
[Service] section of
mongod.service) will solve the problem if mongodb sends apropriate notification to systemd. But I did not find any documentation about it.
The queston is, how to autostart the application, after mongodb will be ready for incoming connections.