#!/bin/bash
#
# send_ulsconf
# sendet /etc/uls als etc_uls.tbz
#######################################################
#
if [[ $# -lt 2 ]]
 then
  DT="`date '+%F %T%:z'`"
else
  DT="$1 $2"
fi
#
if which xz >/dev/null 2>&1
 then
  COMPRESS=J
  EXT=txz
else
  COMPRESS=j
  EXT=tbz
fi
#
OUTFILE=/tmp/etc_uls.$EXT
#
cd /etc
tar cf$COMPRESS $OUTFILE uls
if [[ -f $OUTFILE ]]
 then
  send_server_doku ULS-Config "Inhalt des Verzeichnisses /etc/uls." $DT $OUTFILE
fi
