当有2个先前发行的ditillery elixir phoenix

时间:2018-08-21 08:43:17

标签: elixir distillery

酒厂2.0版

Elixir 1.7.1

OTP 21.0

首先,执行正常发行并使用混合发行进行部署。它在prod / rel / app_name / releases / 1.0.1-08f6b0c中创建了一个构建版本

  • 应用程序正常工作

现在更改某些内容,然后再次使用混合发行--upgrade创建发行

它在prod / rel / app_name / releases / 1.0.1-a4011918中创建了一个新版本

,然后升级为

/opt/app-name/bin/app-name upgrade 1.0.1-a4011918
  • 应用程序已升级。

现在再次进行新更改以创建升级版本。版本1.0.1-a6cf7267。

现在尝试升级,它将给出一个错误。

详细的ansible日志 “无法找到release-evercam_media的代码路径”,“ 1.0.1-08f6b0c!”

ansible +做手册

"Could not locate code path for release-evercam_media\",\"1.0.1-08f6b0c!"
Description of issue

预期:应升级新发行版本。但是失败并找到了第一个发布代码?是一个问题,有两个连续的发行版本,只能是最后一个吗?

我的配置文件很简单

# Import all plugins from `rel/plugins`
# They can then be used by adding `plugin MyPlugin` to
# either an environment, or release definition, where
# `MyPlugin` is the name of the plugin module.
~w(rel plugins *.exs)
|> Path.join()
|> Path.wildcard()
|> Enum.map(&Code.eval_file(&1))

use Mix.Releases.Config,
    # This sets the default release built by `mix release`
    default_release: :default,
    # This sets the default environment used by `mix release`
    default_environment: Mix.env()

# For a full list of config options for both releases
# and environments, visit https://hexdocs.pm/distillery/configuration.html


# You may define one or more environments in this file,
# an environment's settings will override those of a release
# when building in that environment, this combination of release
# and environment configuration is called a profile

environment :dev do
  # If you are running Phoenix, you should make sure that
  # server: true is set and the code reloader is disabled,
  # even in dev mode.
  # It is recommended that you build with MIX_ENV=prod and pass
  # the --env flag to Distillery explicitly if you want to use
  # dev mode.
  set dev_mode: true
  set include_erts: false
  set cookie: :"Ht*Sd&uNNB]}}E;a~a/?&n~uogVhz>@|{,5`sX(>xK{A`@M,kj`0dF{s~`ry?XdJ"
end

environment :prod do
  set include_erts: true
  set include_src: false
  set cookie: :"Qf*;>$8`bG)vnRLU[AS(HLh9:]Qd:f)]%,`!Vfl^@Nek>OeeFRtl|&chJmdb{Ml("
end

# You may define one or more releases in this file.
# If you have not set a default release, or selected one
# when running `mix release`, the first release in the file
# will be used by default

release :evercam_media do
  set version: current_version(:evercam_media)
  set applications: [
    :runtime_tools
  ]
end

问题是:为什么在第3个版本中寻找第一个版本文件夹,为什么要从第2个版本进行升级。我还尝试了在升级版本发布之前先创建appup并进行升级,但都没有用。

0 个答案:

没有答案