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

no app in context in logs #1627

Closed
JustNoopie opened this issue Nov 10, 2021 · 2 comments
Closed

no app in context in logs #1627

JustNoopie opened this issue Nov 10, 2021 · 2 comments

Comments

@JustNoopie
Copy link

JustNoopie commented Nov 10, 2021

Hey guys,

I'm new to Nextcloud on Docker. I was previously running Nextcloud on my host system and now switching to Docker. I don't know if I have an incorrect configuration, but I mostly get errors and warnings in the Nextcloud logs without the associated app. The logs say no app in context.

For example, if I produce a faulty login, I get no app in context instead of the core app.

{"reqId":"Y7NN80sBXGnQ1FiNY2r0","level":2,"time":"2021-11-10T09:43:26+00:00","remoteAddr":"IP","user":"--","app":"no app in context","method":"POST","url":"/login","message":"Login failed: user (Remote IP: IP)","userAgent":"Mozilla/5.0 (Linux; Android 11; SM-G973F) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/95.0.4638.74 Mobile Safari/537.36","version":"22.2.0.2","id":"618b943ebf6ca"}

Im running Nextcloud with a Redis and a MySQL-Container. Except for this behavior, everything works as expected. Since I'm not sure whether this is normal behavior and I want to operate Nextcloud with fail2ban, I would like to know whether the log entries are normal.

I'm running Nextcloud like this

docker run -d \
    --name nextcloud \
    -p 172.17.0.1:8989:80 \
    --restart always \
    --link mysql:db \
    --link redis:redis \
    -v /path/to/dir:/var/www/html \
    -v /path/to/dir:/var/www/html/data \
    --env-file /path/to/dir/.env \
    nextcloud

Thanks for your help!

@joshtrichards
Copy link
Member

Hi @JustNoopie - Thanks for your report. I'm processing some older Issues. This doesn't look like a Docker image specific issue. There's nothing in the Docker image itself that would impact the context for the logging. If this is still occurring and concerns you, I suggest checking for existing/opening an issue in the Nextcloud Server repository.

I did poke around a bit and of three spots where this logging takes place in server one does appear to be missing context. There may be a reason for that or it may be an oversight. I'm not sure:

https://github.com/search?q=repo%3Anextcloud%2Fserver%20%22Login%20failed%3A%22&type=code

(the first one)

If you agree with my assessment that this isn't likely specific to the Docker image, please close this Issue. Thanks!

@JustNoopie
Copy link
Author

Hey @joshtrichards,
thanks for your answer. I think this issue solved iteself. Logs are looking fine now, the issue is closed.

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

2 participants