Revize 1819
Přidáno uživatelem Ondřej Fibich před více než 11 roky(ů)
freenetis/trunk/application/vendors/deb/freenetis/debianization.sh | ||
---|---|---|
# Script for debianization of FreenetIS base package
|
||
# (c) Ondrej Fibich, 2012
|
||
#
|
||
# Takes two arguments (version of package - FreenetIS).
|
||
# Takes two arguments (version of package - FreenetIS and debian version).
|
||
#
|
||
################################################################################
|
||
|
||
if [ $# -ne 1 ]; then
|
||
if [ $# -ne 2 ]; then
|
||
echo "Wrong arg count.. Terminating"
|
||
exit 1
|
||
fi
|
||
|
||
NAME=freenetis
|
||
VERSION=$1
|
||
DEBIAN=$2
|
||
|
||
# create dirs ##################################################################
|
||
mkdir deb_packages/tmp
|
||
... | ... | |
|
||
# make package
|
||
cd ..
|
||
sudo dpkg-deb -b tmp ${NAME}_${VERSION}_all.deb
|
||
sudo dpkg-deb -b tmp ${NAME}_${VERSION}+${DEBIAN}.deb
|
||
|
||
# clean-up mess ################################################################
|
||
|
freenetis/trunk/application/vendors/deb/freenetis-qos/debianization.sh | ||
---|---|---|
# Script for debianization of FreenetIS redirection and QoS package
|
||
# (c) Ondrej Fibich, 2012
|
||
#
|
||
# Takes two arguments (version of package - FreenetIS).
|
||
# Takes two arguments (version of package - FreenetIS and debian version).
|
||
#
|
||
################################################################################
|
||
|
||
if [ $# -ne 1 ]; then
|
||
if [ $# -ne 2 ]; then
|
||
echo "Wrong arg count.. Terminating"
|
||
exit 1
|
||
fi
|
||
|
||
NAME=freenetis-qos
|
||
VERSION=$1
|
||
DEBIAN=$2
|
||
|
||
# create dirs ##################################################################
|
||
mkdir deb_packages/tmp
|
||
... | ... | |
sudo chown -hR root:root *
|
||
|
||
# make package
|
||
sudo dpkg-deb -b tmp ${NAME}_${VERSION}_all.deb
|
||
sudo dpkg-deb -b tmp ${NAME}_${VERSION}+${DEBIAN}.deb
|
||
|
||
# clean-up mess ################################################################
|
||
|
freenetis/trunk/application/vendors/deb/freenetis-monitoring/debianization.sh | ||
---|---|---|
# Script for debianization of FreenetIS redirection and QoS package
|
||
# (c) Ondrej Fibich, 2012
|
||
#
|
||
# Takes two arguments (version of package - FreenetIS).
|
||
# Takes two arguments (version of package - FreenetIS and debian version).
|
||
#
|
||
################################################################################
|
||
|
||
if [ $# -ne 1 ]; then
|
||
if [ $# -ne 2 ]; then
|
||
echo "Wrong arg count.. Terminating"
|
||
exit 1
|
||
fi
|
||
|
||
NAME=freenetis-monitoring
|
||
VERSION=$1
|
||
DEBIAN=$2
|
||
|
||
# create dirs ##################################################################
|
||
mkdir deb_packages/tmp
|
||
... | ... | |
sudo chown -hR root:root *
|
||
|
||
# make package
|
||
sudo dpkg-deb -b tmp ${NAME}_${VERSION}_all.deb
|
||
sudo dpkg-deb -b tmp ${NAME}_${VERSION}+${DEBIAN}.deb
|
||
|
||
# clean-up mess ################################################################
|
||
|
freenetis/trunk/application/vendors/deb/freenetis-ssh-keys/debianization.sh | ||
---|---|---|
# Script for debianization of FreenetIS rSSH keys
|
||
# (c) Ondrej Fibich, 2012
|
||
#
|
||
# Takes two arguments (version of package - FreenetIS).
|
||
# Takes two arguments (version of package - FreenetIS and debian version).
|
||
#
|
||
################################################################################
|
||
|
||
if [ $# -ne 1 ]; then
|
||
if [ $# -ne 2 ]; then
|
||
echo "Wrong arg count.. Terminating"
|
||
exit 1
|
||
fi
|
||
|
||
NAME=freenetis-ssh-keys
|
||
VERSION=$1
|
||
DEBIAN=$2
|
||
|
||
# create dirs ##################################################################
|
||
mkdir deb_packages/tmp
|
||
... | ... | |
sudo chmod g-w tmp/etc/cron.d/freenetis-ssh-keys
|
||
|
||
# make package
|
||
sudo dpkg-deb -b tmp ${NAME}_${VERSION}_all.deb
|
||
sudo dpkg-deb -b tmp ${NAME}_${VERSION}+${DEBIAN}.deb
|
||
|
||
# clean-up mess ################################################################
|
||
|
freenetis/trunk/application/vendors/deb/debianization.sh | ||
---|---|---|
fi
|
||
|
||
NAMES=(freenetis freenetis-monitoring freenetis-redirection freenetis-ulogd freenetis-ssh-keys)
|
||
DEBIANS=(lenny squeeze wheezy)
|
||
VERSION=$1
|
||
|
||
if [ $# -eq 2 ]; then
|
||
NAMES=($2)
|
||
fi
|
||
|
||
if [ $# -eq 3 ]; then
|
||
DEBIANS=($3)
|
||
fi
|
||
|
||
# functions ####################################################################
|
||
|
||
function red_echo() {
|
||
... | ... | |
|
||
for name in ${NAMES[*]}
|
||
do
|
||
for debian in ${DEBIANS[*]}
|
||
do
|
||
deb_sh=./$name/debianization.sh
|
||
|
||
if [ -f "$deb_sh" ]; then
|
||
./$deb_sh "$VERSION"
|
||
./$deb_sh "$VERSION" "$debian"
|
||
|
||
if [ $? -eq 0 ]; then
|
||
green_echo ">>>> [$name] debianized"
|
||
green_echo ">>>> [$name+$debian] debianized"
|
||
else
|
||
red_echo ">>>> [$name] an error occured during debianization"
|
||
red_echo ">>>> [$name+$debian] an error occured during debianization"
|
||
fi
|
||
else
|
||
red_echo ">>>> [$name] not debianized (debianization utility is missing)"
|
||
red_echo ">>>> [$name+$debian] not debianized (debianization utility is missing)"
|
||
fi
|
||
done
|
||
done
|
||
|
freenetis/trunk/application/vendors/deb/freenetis-redirection/debianization.sh | ||
---|---|---|
# Script for debianization of FreenetIS redirection and QoS package
|
||
# (c) Ondrej Fibich, 2012
|
||
#
|
||
# Takes two arguments (version of package - FreenetIS).
|
||
# Takes two arguments (version of package - FreenetIS and debian version).
|
||
#
|
||
################################################################################
|
||
|
||
if [ $# -ne 1 ]; then
|
||
if [ $# -ne 2 ]; then
|
||
echo "Wrong arg count.. Terminating"
|
||
exit 1
|
||
fi
|
||
|
||
NAME=freenetis-redirection
|
||
VERSION=$1
|
||
DEBIAN=$2
|
||
|
||
# create dirs ##################################################################
|
||
mkdir deb_packages/tmp
|
||
... | ... | |
sudo chown -hR root:root *
|
||
|
||
# make package
|
||
sudo dpkg-deb -b tmp ${NAME}_${VERSION}_all.deb
|
||
sudo dpkg-deb -b tmp ${NAME}_${VERSION}+${DEBIAN}.deb
|
||
|
||
# clean-up mess ################################################################
|
||
|
Také k dispozici: Unified diff
Upravy:
- #454: Zacatek uzpusobeni skriptu pro tvorbu baliku na ruzne verze debianu