March 4, 20179 yr In my Docker container I would like to send notifications using built-in webGui notification system. To do this I'm making a POST request to "http://tower/webGui/include/Notify.php", but the problem is I need to include the "csrf_token" variable with every request. Is there a way to retrieve that variable from inside of the container so it doesn't need to be manually entered using env variables?
March 4, 20179 yr 1 hour ago, Krzaku said: In my Docker container I would like to send notifications using built-in webGui notification system. To do this I'm making a POST request to "http://tower/webGui/include/Notify.php", but the problem is I need to include the "csrf_token" variable with every request. Is there a way to retrieve that variable from inside of the container so it doesn't need to be manually entered using env variables? You're going to be better off mapping the folder /usr/local/emhttp/plugins/dynamix/scripts inside the container, and then calling the notify script manually Your container won't be able to determine the csrf_token, and the value changes with every reboot, so an environment variable won't work either.
March 4, 20179 yr Author Mapping this single folder would not work, would it? It requires some other scripts and configs, and also requires a php interpreter to be installed in the container.
March 5, 20179 yr You can get the csrf from the var.ini file on tapatalk at the moment so can't give you the exact folder thoughSent from my SM-T560NU using Tapatalk
March 7, 20179 yr Author I decided to not include notifications in my script as I don't think it's a good idea to pass the root password to Docker containers via env variables. Thanks for your help anyway. Edited March 7, 20179 yr by Krzaku
Archived
This topic is now archived and is closed to further replies.