New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
mount custom files on docker #289
Comments
Hi @supremepot! Thanks for opening this issue. First, what did you try? What error(s) do you get? The documentation of the repository is pretty straight-forward on that subject:
If the issue is that you do not know how to mount files in Docker, this is not the right place to ask, but one of the ways is by using the
Instead of mounting a custom dictionary however, you'd need to mount your target file. Does that make sense? |
yeah I've tried with the -v parameter, but I get this : unable to load credentials dictionary: could not read credentials dictionary file at "/tmp/dictionaries/credentials.json": open /tmp/dictionaries/credentials.json: no such file or directory I've tried too to open the directory, but I found nothing, and the same happens with the custom target list i have macOs, maybe there Is a different "procedure" to do it? |
But what you want isn't to load a crendentials dictionary. Also if you don't have a file in It works just the same on MacOS as on Linux, so no worries that is not the issue. |
ok, so the fact is that i can't find the path |
I tried installing ubuntu for view the path of /tmp , but even with the path access, and the file loaded I get this error: |
It seems that the file did not load and the binary tried to interpret the path as an address range with a net mask. // LoadTargets parses the file containing hosts to targets, if the targets are
// just set to a file name.
func (s *Scanner) LoadTargets() error {
if len(s.targets) != 1 {
return nil
}
path := s.targets[0]
_, err := fs.Stat(path)
if err != nil {
return nil
}
file, err := fs.Open(path)
if err != nil {
return fmt.Errorf("unable to open targets file %q: %v", path, err)
}
defer file.Close()
bytes, err := ioutil.ReadAll(file)
if err != nil {
return fmt.Errorf("unable to read targets file %q: %v", path, err)
}
s.targets = strings.Split(string(bytes), "\n")
s.term.Debugf("Successfylly parsed targets file with %d entries", len(s.targets))
return nil
} It seems that when running Can you show me the contents of your file and the command line you ran? Thanks |
the file contain ip like this: 37.148.15.106 and for mount the file I've tried 2 times with this: docker run -t -v /my/folder/with/target:/tmp/target and then this docker run -t -v /tmp:/tmp/ ullaakut/cameradar -t tmp/target |
@Ullaakut |
Can it be due to line endings like it was for this previous question? Specific comment in question with the potential solution for both of your issues: #287 (comment) |
I can't mount my custom ip range file on docker, how can I do?
The text was updated successfully, but these errors were encountered: