Warning: Trying to access array offset on value of type bool in /var/www/html/sysadminsdecuba/wp-content/themes/mh-magazine-lite/includes/mh-custom-functions.php on line 144
Warning: Attempt to read property "post_title" on null in /var/www/html/sysadminsdecuba/wp-content/themes/mh-magazine-lite/includes/mh-custom-functions.php on line 144
Buenas a todos los lectores hoy les quiero compartir a todos un ejemplo de un script de debmirror optimizado en parte para no descargar todas las cosas de un repositorio, les dejo una copia del mismo y usen ustedes su propia imaginación.
#!/bin/sh
# Matamos el mirror si ya está corriendo
killall debmirror
ARQUITECTURA=armhf
METODO=http
RAMAS=wheezy
HOST_PRINCIPAL=mirrordirector.raspbian.org
HOST_RPI=raspberrypi.collabora.com
HOST_RAS=archive.raspberrypi.org
DIR_REPOS=/home/armandof/repos
DIR_PRINCIPAL=/home/armandof/repos/raspbian
DIR_RPI=/home/armandof/repos/raspberrypi-rpi
DIR_RAS=/home/armandof/repos/raspberrypi-main
WORD=`grep Errors /tmp/raspbian.log`
echo «=====================================================»
echo «Actualizando los repositorios de RASPBIAN»
echo «=====================================================»
echo «»
echo «== REPOSITORIO PRINCIPAL ==»
echo «»
debmirror \
–arch=${ARQUITECTURA} \
–section=main,contrib,non-free,rpi \
–host=${HOST_PRINCIPAL} \
–root=/raspbian \
–dist=${RAMAS} \
–progress \
–method=${METODO} \
–ignore-release-gpg \
–ignore-small-errors \
–exclude-deb-section=’^debug$’ \
–exclude=’help-.*\.deb$’ \
–include=’help-es.*\.deb$’ \
–include=’help-en.*\.deb$’ \
–exclude-deb-section=doc \
–exclude-deb-section=electronics \
–exclude-deb-section=games \
–exclude-deb-section=hamradio \
–exclude-deb-section=kde \
–exclude-deb-section=gnome \
–exclude-deb-section=misc \
–exclude-deb-section=graphics \
–exclude-deb-section=math \
–exclude-deb-section=science \
–exclude-deb-section=sound \
–exclude-deb-section=tex \
–exclude-deb-section=text \
–exclude-deb-section=video \
–exclude-deb-section=xfce \
–exclude-deb-section=editors \
–nosource \
–diff=none \
–postcleanup \
–proxy=http://192.168.0.1:3128/ \
${DIR_PRINCIPAL}
echo «»
echo «== REPOSITORIO RPI ==»
echo «»
debmirror \
–arch=${ARQUITECTURA} \
–section=rpi \
–host=${HOST_RPI} \
–dist=${RAMAS} \
–progress \
–method=${METODO} \
–ignore-release-gpg \
–nosource \
–diff=none \
–postcleanup \
${DIR_RPI}
echo «»
echo «== REPOSITORIO RAS ==»
echo «»
debmirror \
–arch=${ARQUITECTURA} \
–section=main \
–host=${HOST_RAS} \
–root=/debian \
–dist=${RAMAS} \
–progress \
–method=${METODO} \
–ignore-release-gpg \
–nosource \
–diff=none \
–postcleanup \
${DIR_RAS}
echo «»
if [ -n «$WORD» ]
then
/home/armandof/repos/actrepos.txt > /tmp/raspbian.log
else
echo «Mirror sin problemas :)» >> /tmp/raspbian.log
cd ${DIR_REPOS}
du -hsc * –exclude=*.txt > raspbian.txt
chown -R nobody:nogroup raspbian.txt
chmod -R 644 raspbian.txt
cd ${DIR_PRINCIPAL}
chown -R nobody:nogroup *
chmod -R 755 *
cd ${DIR_RPI}
chown -R nobody:nogroup *
chmod -R 755 *
cd ${DIR_RAS}
chown -R nobody:nogroup *
chmod -R 755 *
fi
Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:70.0) Gecko/20100101 Firefox/70.0
hace unos años uso debmirror para actualizar mis repos, recien trate de usarlo en debian buster y encuentro que obligatoriamente me quiere descargar (binary-all) como puedo declarar en mi script que no me descarge esto, ya probe con las opciones exclude y exclude-fiel sin resultadospositivos.