How to issue a notification under the root in ubuntu 18.04?

Hi, my problem is that after hibernation the script in /lib/systemd/system-sleep/script do the work.
It is advisable to give notice.

I was trying to use zenity and notify-send

however, they do not work just like that.

I tried su user-c "command" to notify-send.

While trying to test the script via sudo - it works.
zenity conditionally on the absence of something.
Also tried DISPLAY=:0.0 comand - as advised for cases under cron, but it doesn't help either.

Tell me how to do this or give a link. Thank you.
March 23rd 20 at 18:57
1 answer
March 23rd 20 at 18:59
su user-c "notify-send 'notification'"

still works, was made ochepyatka

Find more questions by tags Ubuntu