Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F85824869
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Authored By
Unknown
Size
1 KB
Referenced Files
None
Subscribers
None
View Options
diff --git a/lib/pleroma/workers/reachability_worker.ex b/lib/pleroma/workers/reachability_worker.ex
index 3a11dfe2a..d9f764322 100644
--- a/lib/pleroma/workers/reachability_worker.ex
+++ b/lib/pleroma/workers/reachability_worker.ex
@@ -1,31 +1,31 @@
# Pleroma: A lightweight social networking server
# Copyright © 2017-2022 Pleroma Authors <https://pleroma.social/>
# SPDX-License-Identifier: AGPL-3.0-only
defmodule Pleroma.Workers.ReachabilityWorker do
use Oban.Worker,
queue: :background,
max_attempts: 3,
unique: [period: :infinity, states: [:available, :scheduled]]
alias Pleroma.HTTP
alias Pleroma.Instances
@impl true
def perform(%Oban.Job{args: %{"domain" => domain}}) do
- case HTTP.get("https://#{domain}/.well-known/nodeinfo") do
+ case HTTP.get("https://#{domain}/") do
{:ok, %{status: status}} when status in 200..299 ->
Instances.set_reachable("https://#{domain}")
:ok
{:ok, %{status: _status}} ->
{:error, :unreachable}
{:error, _} = error ->
error
end
end
@impl true
def timeout(_job), do: :timer.seconds(5)
end
File Metadata
Details
Attached
Mime Type
text/x-diff
Expires
Thu, Oct 29, 7:38 PM (1 d, 22 h)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
1798580
Default Alt Text
(1 KB)
Attached To
Mode
rPUBE pleroma-upstream
Attached
Detach File
Event Timeline