ansible-elixir-stack icon indicating copy to clipboard operation
ansible-elixir-stack copied to clipboard

Staging Configuration Help

Open dmin7b5 opened this issue 9 years ago • 2 comments

I've got production working great, pulling from my master branch and placed under projects on the server like so: /home/deployer/projects/appname_web

I would also like to have staging under projects as well: /home/deployer/projects/appname_web_staging

Unfortunately I'm getting a error on the "create release" task (see below).

I've changed the following in the staging branch files:

/config/prod.exs url: [host: "staging.appname.com", port: 80]

playbooks/vars/main.yml

app_name: appname_web_staging repo_url: "[email protected]:company/appname.git" git_ref: staging app_port: 3002 domains: ["staging.appname.com"] enable_mail_alerts: False

Here is the top part of the error I'm getting when deploying:

TASK [HashNuke.elixir-stack : create release] ********************************** task path: /usr/local/etc/ansible/roles/HashNuke.elixir-stack/tasks/release.yml:13

fatal: [IPADDRESS]: FAILED! => {"changed": true, "cmd": ["bash", "-lc", "SERVER=1 mix release"], "delta": "0:01:05.441843", "end": "2016-02-13 17:33:05.265316", "failed": true, "invocation": {"module_args": {"_raw_params": "bash -lc 'SERVER=1 mix release'", "_uses_shell": false, "chdir": "/home/deployer/projects/appname_web_staging", "creates": null, "executable": null, "removes": null, "warn": true}, "module_name": "command"}, "rc": 1, "start": "2016-02-13 17:31:59.823473", "stderr": "lib/conform/schema.ex:17: warning: redefining @doc attribute previously set at line 10\nlib/conform/translate.ex:16: warning: redefining @doc attribute previously set at line 9", "stdout": "==> connection\nCompiled lib/connection.ex\nGenerated connection app\n==> poolboy (compile)\n==> decimal\nCompiled lib/decimal.ex\nGenerated decimal app\nWARN: Missing plugins: [rebar3_hex]\n==> neotoma (compile)\n==> rebar3_hex (compile)\n==> poison\nCompiled lib/poison.ex\n

dmin7b5 avatar Feb 14 '16 19:02 dmin7b5

@dmin7b5 Hello Jeff, it looks like an error with conform config. Nevertheless, I'll look into it today while refactoring some of the code too.

HashNuke avatar Feb 15 '16 08:02 HashNuke

“app_name” should be as otp app i.e “app_name: appname_web_staging" should work for “AppnameWebStaging”. please look into https://github.com/HashNuke/ansible-elixir-stack/blob/master/docs/configuration.md

You can change the otp app name which i would not recommend or spin another droplet for staging.

murtza avatar Mar 03 '16 21:03 murtza