Skip to content

Commit

Permalink
chore: check if ssl started for migrations
Browse files Browse the repository at this point in the history
  • Loading branch information
abc3 committed Jul 25, 2023
1 parent b354ff7 commit 2f9f6a5
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.2.19
0.2.20
8 changes: 4 additions & 4 deletions lib/supavisor/release.ex
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ defmodule Supavisor.Release do
@app :supavisor

def migrate do
load_app()
ensure_ssl_started()

for repo <- repos() do
{:ok, _, _} =
Expand All @@ -18,7 +18,7 @@ defmodule Supavisor.Release do
end

def rollback(repo, version) do
load_app()
ensure_ssl_started()

{:ok, _, _} =
Ecto.Migrator.with_repo(
Expand All @@ -31,7 +31,7 @@ defmodule Supavisor.Release do
Application.fetch_env!(@app, :ecto_repos)
end

defp load_app do
Application.load(@app)
defp ensure_ssl_started do
Application.ensure_all_started(:ssl)
end
end

0 comments on commit 2f9f6a5

Please sign in to comment.