[Fix] Fix etcd backup pod crashlooping

This PS will fix the etcd backup pod crashlooping because of the
backup file name not getting passed correctly to tar

Change-Id: I782055f8c97160cb3697f2ccb7ef340091ad7491
Signed-off-by: Sreejith Punnapuzha <Sreejith.Punnapuzha@outlook.com>
This commit is contained in:
Sreejith Punnapuzha 2019-05-23 10:02:26 -05:00
parent 4737c06edb
commit 3b9e25a06e
1 changed files with 1 additions and 1 deletions

View File

@ -22,7 +22,7 @@ BACKUP_FILE_NAME={{ .Values.service.name | quote }}
SKIP_BACKUP=0
etcdbackup() {
etcdctl snapshot save $BACKUP_DIR/$(BACKUP_FILE_NAME)-backup-$(date +"%m-%d-%Y-%H-%M-%S").db >> $BACKUP_LOG
etcdctl snapshot save $BACKUP_DIR/$BACKUP_FILE_NAME-backup-$(date +"%m-%d-%Y-%H-%M-%S").db >> $BACKUP_LOG
BACKUP_RETURN_CODE=$?
if [[ $BACKUP_RETURN_CODE != 0 ]]; then
echo "There was an error backing up the databases. Return code was $BACKUP_RETURN_CODE."