Deploy application with Edelive FAILED with exit status 255

I have set config in file ./deliver/config

APP=“myproject”

BUILD_HOST=“MY_HOST”
BUILD_USER=“deploy”
BUILD_AT="/home/deploy/app_build"

PRODUCTION_HOSTS=“MY_HOST”
PRODUCTION_USER=“deploy”
DELIVER_TO="/home/deploy/app_release"

When I try to run command in my local machine:
mix edeliver build release

I get error:
A remote command failed on:

deploy@localhost

Output of the command is shown above and the command executed
on that host is printed below for debugging purposes:

FAILED with exit status 255:

set -e
if [ ! -d /home/deploy/app_build ]
then
  mkdir -p /home/deploy/app_build
  cd /home/deploy/app_build
  git init &> /dev/null
  git config receive.denyCurrentBranch ignore
else
  cd /home/deploy/app_build
  git config receive.denyCurrentBranch ignore
fi
1 Like

Do you use ssh keys for authentication into the server?

1 Like

Yes. I do.
Also I use next versions:
{:edeliver, “~> 1.4.3”},
{:distillery, “~> 1.4”}

1 Like

If you are using EC2 in AWS, then this should solve your problem

If you’re using Amazon EC2 hosts, you’ll most likely authenticate with your remote hosts by passing along a *.pem file when you establish your SSH connection.

While edeliver doesn’t explicitly support this kind of authentication, adding a Host/IndentityFile entry in your ~/.ssh/config file for each of your remote hosts will authorize edeliver to communicate with these hosts:

Host ec2-foo.compute-1.amazonaws.com
  IdentityFile ~/my_identity_file.pem

Host ec2-bar.compute-1.amazonaws.com
  IdentityFile ~/my_identity_file.pem

Here is more about SSH part.

1 Like

I have already created this file

1 Like

And if you run as deploy user those commands in terminal on server everything works fine?

1 Like

deploy user is role on server. I don’t run command
mix edeliver build release
in terminal on server
I use this guide

1 Like

Did you find the problem? I had the same error following the DigitalOcean tutorial