将Phoenix应用程序部署到Gigalixir时出现问题:“没有名为[email protected]的文件”

问题描述

我正在尝试将Hashrockets TIL Phoenix App部署到Gigalixir

这是我推入吉加利西尔后得到的:

2020-08-23T05:58:55.071975+00:00 til[gigalixir-run]: Attempting to start 'til' on host 'til-6c4c5d7854-ddpfh'
2020-08-23T05:58:55.071987+00:00 til[gigalixir-run]: Attempting health checks on port 4000
2020-08-23T05:58:55.874467+00:00 til[til-6c4c5d7854-ddpfh]: web.1  | started with pid 49
2020-08-23T05:58:57.568099+00:00 til[til-6c4c5d7854-ddpfh]: web.1  | No file named [email protected]
2020-08-23T05:58:57.976006+00:00 til[til-6c4c5d7854-ddpfh]: web.1  | exited with code 1
2020-08-23T05:58:57.976034+00:00 til[til-6c4c5d7854-ddpfh]: system | sending SIGTERM to all processes

我无法理解错误消息No file named [email protected]。我现在该怎么办?

解决方法

此问题的原因是,该项目随附的Procfile可能打算与Heroku一起使用并包含

web: MIX_ENV=prod elixir --cookie $OTP_COOKIE --name [email protected] --erl '-kernel inet_dist_listen_min 9000' --erl '-kernel inet_dist_listen_max 9000' -S mix phx.server

将文件重命名为Procfile.disabled,从而使Gigalixir使用其default Procfile解决了这个问题。