Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade to heroku-24 stack #642

Merged
merged 1 commit into from
Sep 27, 2024
Merged

Upgrade to heroku-24 stack #642

merged 1 commit into from
Sep 27, 2024

Conversation

paulcretu
Copy link
Member

@paulcretu paulcretu commented Sep 27, 2024

Upgrading to heroku-24 stack

Git is no longer available at runtime:

We made some tools that are typically only required during the build (such as GCC, Make, Git and system Python) available only at build time, rather than at app run time too.

This seems to cause problems with some mix tasks (e.g. when running mix ecto.migrate during release phase:

** (ErlangError) Erlang error: :enoent
    (elixir 1.15.6) lib/system.ex:1092: System.cmd("git", ["--git-dir=.git", "config", "remote.origin.url"], [cd: "/app/deps/zappa"])
    (mix 1.15.6) lib/mix/scm/git.ex:265: Mix.SCM.Git.get_rev_info/0
    (mix 1.15.6) lib/mix/scm/git.ex:75: anonymous fn/2 in Mix.SCM.Git.lock_status/1
    (elixir 1.15.6) lib/file.ex:1624: File.cd!/2
    (mix 1.15.6) lib/mix/dep.ex:432: Mix.Dep.check_lock/1
    (elixir 1.15.6) lib/enum.ex:1693: Enum."-map/2-lists^map/1-1-"/2
    (elixir 1.15.6) lib/enum.ex:1693: Enum."-map/2-lists^map/1-1-"/2
    (mix 1.15.6) lib/mix/tasks/deps.loadpaths.ex:75: Mix.Tasks.Deps.Loadpaths.deps_check/2

It may be worth investigating why mix ecto.migrate needs to run git, but for now the simplest solution is to manually make sure git is installed using heroku-buildpack-apt, which uses the Aptfile to specify what to install.

@paulcretu paulcretu requested review from skanderm and a team as code owners September 27, 2024 22:22
@paulcretu paulcretu temporarily deployed to orcasite-pr-642 September 27, 2024 22:24 Inactive
@paulcretu paulcretu merged commit 42d1558 into main Sep 27, 2024
8 checks passed
@paulcretu paulcretu deleted the upgrade-stack-heroku-24 branch September 27, 2024 22:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant