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

Log to file #283

Open
lonix1 opened this issue Jul 15, 2023 · 1 comment
Open

Log to file #283

lonix1 opened this issue Jul 15, 2023 · 1 comment
Labels
enhancement New feature or request

Comments

@lonix1
Copy link

lonix1 commented Jul 15, 2023

BACKGROUND

Rustdesk seems to log to stdout only, and thus to docker's built-in "json driver". The logs can be access like so:

  • $ docker logs -t $CONTAINER_NAME
  • sudo tail -f /var/lib/docker/containers/$CONTAINER_ID/$CONTAINER_ID-json.log

PROBLEM

When the container is recycled, the logs are lost. The workaround is to use another logging tool, but that is unnecessary complexity, especially for small deployments.

Also, in general, the logs are not in a friendly format - it's much simpler, especially in small deployments, to simply have the log in a file that can be easily manipulated. Not everyone uses large complex logging apps and servers, etc.

SOLUTION

Many apps have an option to log to file as well. It would be nice if the log could be sent to a file instead of (or in addition to) stdout. If enabled, it could be written to /var/lib/rustdesk/app.log by default.

Personally, I would mount it as /var/log/rustdesk.log:/var/log/rustdesk.log so that I could have it on the host, use logrotate on it, add it to backups etc.

ALTERNATIVES

An unnecessarily complicated environment that includes log aggregation and monitoring, and who knows what else. For small servers that is overkill and hard to manage.

Additional context

Thank you for considering it!

@lonix1 lonix1 added the enhancement New feature or request label Jul 15, 2023
@paspo
Copy link
Contributor

paspo commented Apr 20, 2024

#371

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

No branches or pull requests

2 participants