mirror of
https://github.com/discourse/discourse.git
synced 2026-08-06 04:02:30 +08:00
Reverts #42059, which dropped the `ProblemCheck::Landlock` check. This restores the check, its spec, and re-registers it in the problem-check list. The `landlock` locale string was left in place by the drop, so no locale change is needed.
14 lines
279 B
Ruby
Vendored
14 lines
279 B
Ruby
Vendored
# frozen_string_literal: true
|
|
|
|
require "discourse/safe_exec"
|
|
|
|
class ProblemCheck::Landlock < ProblemCheck
|
|
self.priority = "high"
|
|
|
|
def call
|
|
return no_problem if !Rails.env.production?
|
|
return no_problem if Discourse::SafeExec.landlock_supported?
|
|
|
|
problem
|
|
end
|
|
end
|