Windows scripts

# exportDB.cmd
for /f "tokens=2" %%i in ('date /t') do set date=%%i
set timestemp=%date:~6,4%-%date:~3,2%-%date:~0,2%
d:\ORANT\BIN\exp80.exe system/manager file="e:\%timestemp%.dmp" full="y"

# add_at_job_windows_nt.cmd
at 20:00 /every:Mo,Di,Mi,Do,Fr,Sa "\\fs\scripte\windows\exportFullDatabase.cmd"

Hylafax CAPI

#!/bin/bash

# preconfigure (do we need this?)
debconf-set-selections <<\EOF
postfix postfix/mailname string fax
postfix postfix/main_mailer_type select Internet Site
EOF

# install hylafax
apt-get install -y capi4hylafax hylafax-server

#
# default configuration
#
# configure capi
sed -i 's|#run_capi4hylafax=1|run_capi4hylafax=1|g' /etc/default/capi4hylafax
sed -i 's|USE_FAXGETTY=yes|USE_FAXGETTY=no|g' /etc/default/hylafax
echo "SendFaxCmd: /usr/bin/c2faxsend" >> /etc/hylafax/config

# optional
echo "@192.168.0.[0-9]+$" >> /etc/hylafax/hosts.hfaxd

# disable AutoCoverPa

ICC profile (color management)

# install icc profile
apt-get install -y icc-profiles
wget http://download.adobe.com/pub/adobe/iccprofiles/win/AdobeICCProfilesCS4Win_end-user.zip -P /tmp
unzip /tmp/AdobeICCProfilesCS4Win_end-user.zip -d /tmp/
cp "/tmp/Adobe ICC Profiles (end-user)/RGB/AdobeRGB1998.icc" /usr/share/color/icc/

# convert image (test)
convert IMAGE_IN.jpg -profile /usr/share/color/icc/AdobeRGB1998.icc -profile /usr/share/color/icc/sRGB.icm IMAGE_OUT.jpg

# Links
http://www.imagemagick.org/Usage/formats/#color_profile

Build fglrx

#!/bin/bash

# download
#wget --no-check-certificate https://www2.ati.com/drivers/linux/ati-driver-installer-9-1-x86.x86_64.run -P /root/ati
#wget --no-check-certificate https://www2.ati.com/drivers/linux/ati-driver-installer-9.2-x86.x86_64.run -P /root/ati
# --extract
#chmod 777 /root/ati/ati-driver-installer-9-1-x86.x86_64.run

# install envirement
#apt-get install -f -y
apt-get install -y build-essential cdbs fakeroot dh-make debhelper debconf libstdc++5 dkms linux-headers-$(uname -r)
depmod -a

modprobe -r fglrx
rm /lib/modules/2.6.27-11-generic/updates/dkms/fglrx.ko

Asterisk auto-dial out with Java (asterisk-java)

# configure manager
/etc/asterisk/manager.conf
[general]
enabled = yes
port = 5038
bindaddr = 0.0.0.0

[manager]
secret=pa55w0rd
permit=0.0.0.0/0.0.0.0
read=system,call,log,verbose,agent,command,user
write=system,call,log,verbose,agent,command,user

# create extension
/etc/asterisk/extensions.conf
[directdial]
exten => 1,1,Dial(CAPI/ISDN1/${customernum}/b)

# reload asterisk
/etc/init.d/asterisk restart

# download java class
wget http://maven.reucon.com/public-snapshot/org/asteriskjava/asterisk-java/1.0.0-SNAPSHOT/asterisk-java-1.0.0-20090303.204542-422.jar

# HelloMa

Magento domU

# set domU parameter
[ -z $DOMAIN_NAME ] && DOMAIN_NAME=magento
[ -z $DOMAIN_MAC ] && DOMAIN_MAC=00:EE:EE:EE:EE:EE
[ -z $DOMAIN_RAM ] && DOMAIN_RAM=4Gb
[ -z $DOMAIN_HDD ] && DOMAIN_HDD=16Gb

# create domU (Local)
http://www.panticz.de/DomU-Debian-Squeeze

# create domU (Hoster)
http://www.panticz.de/Hetzner

# install magento
http://www.panticz.de/install_magento

#
# OPTIONAL
#
# create separate www patition
lvcreate --name ${DOMAIN_NAME}-www --size 128G vg0
mkfs.ext3 /dev/vg0/${DOMAIN_NAME}-www

vi /etc/xen/${DOMAIN_NAME}
(add)
'phy:/dev/vg0/mrwww-www,sda3,w',

#

Install fcpci (AVM Fritz Card PCI kernel module)

#!/bin/bash

# install capiutils
apt-get install -y capiutils
sed -i 's|#fcpci|fcpci|g' /etc/isdn/capi.conf

# install kernel module for AVM Fritz card PCI or compile: http://www.panticz.de/ubuntu_compile_fcpci
apt-get install wget
wget http://dl.dropbox.com/u/4170695/www/fcpci.tar.bz2 -P /tmp
tar xjf /tmp/fcpci.tar.bz2 -C /tmp/
/tmp/fcpci/install.sh
reboot

apt-get install -y asterisk asterisk-chan-capi
# do we need this?