#!/bin/bash
#This is a jenkins script
export remote_command="/usr/bin/ssh -i /var/lib/jenkins/.ssh/id_rsa ubuntu@era.eha.io "

$remote_command "cd /opt/infrastructure/docker/images/era/era && /usr/bin/sudo git pull origin master" &&\
$remote_command "/usr/bin/sudo docker build -t era /opt/infrastructure/docker/images/era"


#!/bin/bash
#This is a jenkins script

cd /opt/infrastructure/docker/images/era/era && /usr/bin/sudo git pull origin master &&\
/usr/bin/sudo docker build -t era /opt/infrastructure/docker/images/era &&\
/usr/bin/sudo docker save era /tmp/era.tar &&\
aws s3 cp /tmp/era.tar s3://eha-docker-repo/era.tar &&\
rm /tmp/era.tar


Update to build era on jenkins
Update to build era on jenkins
