Skip to content
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

Debug configuration error #46

Closed
mstoffel-sag opened this issue Dec 15, 2021 · 9 comments
Closed

Debug configuration error #46

mstoffel-sag opened this issue Dec 15, 2021 · 9 comments

Comments

@mstoffel-sag
Copy link
Member

If I try to debug the agent I get the following warnings and errors:

cd /home/mstoffel/cumulocity-devicemanagement-agent ; /usr/bin/env /bin/python3 /home/mstoffel/.vscode-server/extensions/ms-python.python-2021.12.1559732655/pythonFiles/lib/python/debugpy/launcher 41065 -- -m c8ydm.main
/usr/lib/python3.8/runpy.py:127: RuntimeWarning: 'c8ydm.main' found in sys.modules after import of package 'c8ydm', but prior to execution of 'c8ydm.main'; this may result in unpredictable behaviour
warn(RuntimeWarning(msg))
2021-12-15 08:09:05,785 MainThread INFO root Output of SystemUtils Serial: 91764171647
Starting...
2021-12-15 08:09:05,789 MainThread INFO root Found pid file with pid 14816
2021-12-15 08:09:05,791 MainThread INFO root Checking if pid 14816 is existing...
2021-12-15 08:09:05,793 MainThread INFO root Pid 14816 does not exist
2021-12-15 08:09:05,794 MainThread INFO root Removing PID File /home/mstoffel/.cumulocity/agent.pid
2021-12-15 08:09:05,796 MainThread INFO root Serial: 91764171647
2021-12-15 08:09:05,799 MainThread INFO root No credentials found. Starting bootstrap mode.
2021-12-15 08:09:05,800 MainThread ERROR root No bootstrap credentials found. Stopping agent.

@mstoffel-sag
Copy link
Member Author

We should mention where the bootstrapping creds can be configured.

@mbay-ODW
Copy link
Collaborator

Why do they need to be configured?

@mstoffel-sag
Copy link
Member Author

Because otherwise you get the error I mentioned.

@mbay-ODW
Copy link
Collaborator

Did you delete or edit the config file?

@switschel
Copy link
Member

Please read the README: https://github.com/SoftwareAG/cumulocity-devicemanagement-agent#configuration
"The agent can be configured via the agent.ini which must be placed in

{userFolder}/.cumulocity
"

@mbay-ODW
Copy link
Collaborator

mbay-ODW commented Dec 15, 2021

@switschel maybe the [secret] part should be also added to the example config:

https://github.com/SoftwareAG/cumulocity-devicemanagement-agent#configuration

There its currently missing.

@switschel
Copy link
Member

switschel commented Dec 15, 2021

You mean the bootstrap credentials? Ok. But still, I strongly suggest using devcontainer for debugging.

@switschel
Copy link
Member

I will remove the example ini from the readme and add a reference to the file.

@switschel
Copy link
Member

Refrence to the agent.ini added.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants