#!/bin/bash

cd /opt/euro-beta/data_export

if [ $2"." == "." ]
then
  echo "tar czvf $1.tgz invoices" > /tmp/backup_invoices
  tar czvf $1.tgz invoices
else
  echo "../systools/encrypt_zip $2 $1.zip invoices" > /tmp/backup_invoices   
  ../systools/encrypt_zip $2 $1.zip invoices   
fi  
