Admin Area > Logs page assumes all log files are local, breaking in HA / containerized
Summary
Exposed when investigating https://gitlab.com/charts/gitlab/issues/863
The Admin Area > Logs page assumes that all log files are accessible from the local filesystem. This is not an accurate assumption in HA / containerized environment.
Steps to reproduce
Configure HA nodes (split roles for Sidekiq / Unicorn), or cloud native GitLab containers (uses separate containers). Ensure multiple Unicorn instances.
What is the current bug behavior?
Sidekiq: sidekiq.log, repocheck.log
- Sidekiq runs on a separate node/container
- Sidekiq does not share a filesystem with the Unicorn/Rails node/container
- No Unicorn instance can not access these logs
Unicorn: application.log, production.log, integrations_json.log
- Multiple nodes/containers
- One log each
- You will see different results based upon which node you reach
Intentionally "broken" repository
Admin Area > Logs, repocheck.log
What is the expected correct behavior?
This UI should present with viable content, or possibly point to appropriate documentation on how to access logs.
Related code
- https://gitlab.com/gitlab-org/gitlab-ce/blob/master/lib/gitlab/logger.rb
- https://gitlab.com/gitlab-org/gitlab-ce/blob/master/lib/gitlab/repository_check_logger.rb
- https://gitlab.com/gitlab-org/gitlab-ce/blob/master/app/views/admin/application_settings/_repository_check.html.haml
- https://gitlab.com/gitlab-org/gitlab-ce/blob/master/app/controllers/admin/logs_controller.rb

