#!/bin/bash

## Setting variables with explanations.

#
# Don't touch the user's keyring, have our own instead
#Esto es donde se almacenaran las claves de seguridad,
#se recomienda un directorio aparte pero en la ubicación de mirror
#mas adelante lo haremos

#export GNUPGHOME=/media/repositorio/mirrorkeyring

# Arch= -a # Architecture. For Ubuntu can be i386, powerpc or amd64.
# sparc, only starts in dapper, it is only the later models of sparc
#Arquitectura de nuestro PC.. amd64, i386, etc

arch=i386

# Minimum Ubuntu system requires main, restricted
# Section= -s # Section (One of the following - main/restricted/universe/multiverse). # You can add extra file with $Section/debian-installer. ex: main/debian-installer,universe/debian-installer,multiverse/debian-installer,restricted/debian-installer
#Todas las versiones de los paquetes main(principal), restricted(privativos)
#multiverse(otros proyectos)universe(hecho por la comunidad).
#Si quieres solo el main por cuestiones de espacio borras el resto y dejas main y asi...
#puedes agregar backports si tu repositorio lo contiene

section=main,restricted,universe,multiverse

# Release= -d # Release of the system (Dapper, Edgy, Feisty, Gutsy, Hardy, jaunty), and the -updates and -security ( -backports can be added if desired) #Version de distro ubuntu dapper,gutsy, hardy etc... solo sustituye el nombre

release=precise,precise-security,precise-updates,precise-backports,precise-proposed

# Server= -h # Server name, minus the protocol and the path at the end # CHANGE "*" to equal the mirror you want to create your mirror from. au. in Australia ca. in Canada. # This can be found in your own /etc/apt/sources.list file, assuming you have Ubuntu installed.
#aqui coloca SOLO la direccion de dominio y si es local el repositorio la ip
#ejemplo server=192.168.27.25

server=ftp.sld.cu

# Dir= -r # Path from the main server, so http://my.web.server/$dir, Server dependant
#Aqui si se coloca los directorios q contiene el pool de la distro

inPath=/ubuntu

# Proto= -e # Protocol to use for transfer (http, ftp, hftp, rsync) # Choose one - http is most usual the service, and the service must be avaialbe on the server you point at.
#protocolo de conexion si es ftp,http etc..

proto=http

# Outpath=              # Directory to store the mirror in
# Make this a full path to where you want to mirror the material.
#Aqui la ruta de la carpeta que creamos en un principio

outPath=/data/www/ftp/repositorios/ubuntu

# The --nosource option only downloads debs and not deb-src's
# The --progress option shows files as they are downloaded
# --source \ in the place of --no-source \ if you want sources also.
# --nocleanup Do not clean up the local mirror after mirroring is complete. Use this option to keep older repository
# Start script
#No tocar...
debmirror --ignore-release-gpg\
      -a $arch \
          --no-source \
          -s $section \
          -h $server \
          -d $release \
          -r $inPath \
          --progress \
          -e $proto \
          $outPath


#### End script to automate building of Ubuntu mirror ####

Salu2.

--
Juan Carlos Hernández Gallardo
Administrador de Red
Nodo Finanzas Ciego de Ávila
Email: jchernan...@ca.mfp.gov.cu
Telef: 0133-224712

______________________________________________________________________
Lista de correos del Grupo de Usuarios de Tecnologías Libres de Cuba.
Gutl-l@jovenclub.cu
http://listas.jovenclub.cu/cgi-bin/mailman/listinfo/gutl-l

Responder a