Skip to content

Commit

Permalink
fix: Only run migration on AWS and use the correct command (#666)
Browse files Browse the repository at this point in the history
  • Loading branch information
filipecabaco authored Sep 12, 2023
1 parent 87e7260 commit aec740e
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
2 changes: 1 addition & 1 deletion mix.exs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ defmodule Realtime.MixProject do
def project do
[
app: :realtime,
version: "2.22.8",
version: "2.22.9",
elixir: "~> 1.14.0",
elixirc_paths: elixirc_paths(Mix.env()),
start_permanent: Mix.env() == :prod,
Expand Down
7 changes: 6 additions & 1 deletion tailscale/wrapper.sh
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,10 @@ if [ "${ENABLE_TAILSCALE-}" = true ]; then
fi

echo "Starting Realtime"
sudo -E -u nobody /app/bin/eval Realtime.Release.migrate

if [ "$AWS_EXECUTION_ENV" = "AWS_ECS_FARGATE" ]; then
echo "Running migrations"
sudo -E -u nobody /app/bin/migrate
fi

sudo -E -u nobody /app/bin/server

0 comments on commit aec740e

Please sign in to comment.