Nginx fails to start for readonly filesystem
i am trying to configure nginx but by default it creates some directories at location /var/lib/nginx , /etc/nginx
i am looking for nginx to create these directories at a different location eg /tmp other than /var/lib , as /tmp is mounted as a different volume in the setup which i have currently where the filesystem is set to be readonly and when the filesystem is set to be readonly nginx fails with the error unable to mkdir()
How can i configure nginx to do so ?
i am able to add locations for access , error , body , fastcgi , scgi and uwsgi
Here is my conf file
which has been modified to