apiVersion: v1
kind: ConfigMap
metadata:
  name: rev-proxy-nginx-conf-cm
data:
  nginx.conf: |
    events {
        worker_connections  1024;
    }

    http {

    #access_log /dev/stdout;
    error_log /dev/stderr error;


    server {

        resolver 172.30.0.10 valid=60s ipv6=off;
        listen       8080;
        server_name  my_sample;
        root         /opt/app-root/src;

        location  ~* /(.*)
        {
            proxy_pass https://ibm-nginx-svc.cpd-202.svc.cluster.local/$1$is_args$args;
            proxy_set_header Host            $host;
            proxy_set_header X-Forwarded-For $remote_addr;
        }
    }
    }
