-
Notifications
You must be signed in to change notification settings - Fork 478
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
Mongo connector in docker loading manager error #436
Comments
Hi, Now elastic_doc_manager is in another project. I use mongo-connector with docker, and he works fine. Thomas. |
I have added this command, when I exec docker with bash and use mongo connector with elastic-doc-manager it works fine, bur when I use docker run when entrypoint is mongo-connector I get exception that cannot find elastic-doc-manager. I have mongo-connector > 2 so I don't point python file. I tried run docker with privilaged=TRUE but it doesn't work |
My dockerfile is like that maybe it helps to find bug in my docker ` RUN git clone https://github.com/mongodb-labs/elastic2-doc-manager WORKDIR /opt/mongo-connector ENTRYPOINT ["mongo-connector", "-m localhost:27017", "-t localhost:9200", "-d elastic2_doc_manager", "-v"] |
ok, I think your problem come from your ENTRYPOINT : try with this : |
It wroks excellent, thank you, I thought that i tried this solution but it turns out that I forgot to try 👍 |
Hi,
I have trouble with mongo-connector in docker. I made Dockerfile where entrypoint is mongo-connector with proper params like
mongo-connector -m localhost:27017 -t localhost:9200 -d elastic_doc_manager. When I run dokcer i get error, that cannot load elastic_doc_amanger:
`Fatal Exception
Traceback (most recent call last):
File "/usr/local/lib/python3.4/dist-packages/mongo_connector/connector.py", line 803, in import_dm_by_name
module = import(full_name, fromlist=(name,))
ImportError: No module named 'mongo_connector.doc_managers. elastic_doc_manager'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/local/lib/python3.4/dist-packages/mongo_connector/util.py", line 85, in wrapped
func(_args, *_kwargs)
File "/usr/local/lib/python3.4/dist-packages/mongo_connector/connector.py", line 1037, in main
conf.parse_args()
File "/usr/local/lib/python3.4/dist-packages/mongo_connector/config.py", line 118, in parse_args
option, dict((k, values.get(k)) for k in option.cli_names))
File "/usr/local/lib/python3.4/dist-packages/mongo_connector/connector.py", line 820, in apply_doc_managers
module = import_dm_by_name(dm['docManager'])
File "/usr/local/lib/python3.4/dist-packages/mongo_connector/connector.py", line 810, in import_dm_by_name
"Could not import %s." % full_name)
mongo_connector.errors.InvalidConfiguration: Could not import mongo_connector.doc_managers. elastic_doc_manager.
Traceback (most recent call last):
File "/usr/local/lib/python3.4/dist-packages/mongo_connector/connector.py", line 803, in import_dm_by_name
module = import(full_name, fromlist=(name,))
ImportError: No module named 'mongo_connector.doc_managers. elastic_doc_manager'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/local/bin/mongo-connector", line 9, in
load_entry_point('mongo-connector==2.2.dev0', 'console_scripts', 'mongo-connector')()
File "/usr/local/lib/python3.4/dist-packages/mongo_connector/util.py", line 85, in wrapped
func(_args, *_kwargs)
File "/usr/local/lib/python3.4/dist-packages/mongo_connector/connector.py", line 1037, in main
conf.parse_args()
File "/usr/local/lib/python3.4/dist-packages/mongo_connector/config.py", line 118, in parse_args
option, dict((k, values.get(k)) for k in option.cli_names))
File "/usr/local/lib/python3.4/dist-packages/mongo_connector/connector.py", line 820, in apply_doc_managers
module = import_dm_by_name(dm['docManager'])
File "/usr/local/lib/python3.4/dist-packages/mongo_connector/connector.py", line 810, in import_dm_by_name
"Could not import %s." % full_name)
mongo_connector.errors.InvalidConfiguration: Could not import mongo_connector.doc_managers. elastic_doc_manager.`
But when I execute this docker with entry point (--entrypoint bash) and run command like earlier everything works fine.
The text was updated successfully, but these errors were encountered: