projects
/
akkoma
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
pagination fix for service users filters
[akkoma]
/
lib
/
mix
/
pleroma.ex
diff --git
a/lib/mix/pleroma.ex
b/lib/mix/pleroma.ex
index ea99234405ed77582be617cd629d703d95ae5147..3ad6edbfbb659d5830d4abb2ce83d0e82b038b16 100644
(file)
--- a/
lib/mix/pleroma.ex
+++ b/
lib/mix/pleroma.ex
@@
-1,18
+1,30
@@
# Pleroma: A lightweight social networking server
# Pleroma: A lightweight social networking server
-# Copyright © 2017-20
19
Pleroma Authors <https://pleroma.social/>
+# Copyright © 2017-20
20
Pleroma Authors <https://pleroma.social/>
# SPDX-License-Identifier: AGPL-3.0-only
defmodule Mix.Pleroma do
@doc "Common functions to be reused in mix tasks"
# SPDX-License-Identifier: AGPL-3.0-only
defmodule Mix.Pleroma do
@doc "Common functions to be reused in mix tasks"
- def start_pleroma
(change_logger_level \\ true)
do
+ def start_pleroma do
Application.put_env(:phoenix, :serve_endpoints, false, persistent: true)
Application.put_env(:phoenix, :serve_endpoints, false, persistent: true)
- if Pleroma.Config.get(:env) != :test and change_logger_level do
- require Logger
- Logger.configure(level: :debug)
+ if Pleroma.Config.get(:env) != :test do
+ Application.put_env(:logger, :console, level: :debug)
end
{:ok, _} = Application.ensure_all_started(:pleroma)
end
{:ok, _} = Application.ensure_all_started(:pleroma)
+
+ if Pleroma.Config.get(:env) not in [:test, :benchmark] do
+ pleroma_rebooted?()
+ end
+ end
+
+ defp pleroma_rebooted? do
+ if Restarter.Pleroma.rebooted?() do
+ :ok
+ else
+ Process.sleep(10)
+ pleroma_rebooted?()
+ end
end
def load_pleroma do
end
def load_pleroma do