NGINX container command: option
Anyone tried to initialize index page of NGINX container to populate with IP address of the container using command: and args: option, something like as below to replace Welcome message on the index page? I am not able to get it to work. Container image is crashing when the command runs.
- name: webserver
args: [" -i 's/Welcome/Welcome $(hostname -i)/g' /usr/share/nginx/html/index.html "]
The idea behind this is to display the ip address of the container to see how various backend containers behind a service responding to client requests and to visualize the load balancing.