0

path to my host directory the directory name is snorttest

The above image contains the host directory which contains a directory called snorttest

docker container directory

The above image contains my docker container directory path which is /etc/snort/etc which i am trying to bindmount to my host directory.

I am trying to get the content of docker containers /etc/snort/etc to my host directories /etc/snorttest/etc/snort directory. But when I am running the below command which is $docker run -d -t -v /etc/snorttest/etc/snort:/etc/snort/etc snort5:latest /bin/bash

nothing is reflecting in my host directories etc/snort folder( I want the contents of docker containers /etc/snort folders to my host directory).

kunal h
  • 9
  • 3
  • Bind mounts only go in the other direction: at container startup time, the contents of the host directory always hide and replace the image content. Maybe `docker cp` will help you copy the original configuration file out of the container. – David Maze Dec 20 '22 at 14:39

0 Answers0