Docker container application not accessible on the host at http://localhost:9393

Viewed 14

I need to make sure create volume for container, set environment variable CSVSERVER_BORDER to have value 'Orange' and make application accessible on http://localhost:9393.

the command I used:

docker run -d -p 80:9393 -e CSVSERVER_BORDER='Orange' -v /root/solution/inputFile:/csvserver/inputdata imageid

Where /root/solution/inputFile is my local directory

1 Answers

The command should be:

docker run -d -p 9393:80 -e CSVSERVER_BORDER='Orange' \
  -v /root/solution/inputFile:/csvserver/inputdata \
  imageid

the change is in the ports section: -p <host_port>:<container_port>

Related