#!/bin/bash

##
#
# Vaisala software source code file
#
# Copyright (c) Vaisala Oyj 2014, 2015. All rights reserved.
#
##

. $(dirname $0)/backup-init

log "INFO" "Removing old backups started."

# Delete backups older than 180 days
find "$BACKUP_DIR" -type f -mtime +180 -exec rm -v {} \; 2>> "$LOG_FILE"

log "INFO" "Removing old backups finished."
