Setup mirror of Openwrt package repository

Suppose we need a local package repository, 15.05-rc3 branch of  newif

 

# Create local repository directory

mkdir -p /mirror/openwrt

 

# Goto repository directory

cd /mirror/openwrt

 

# download packages with wget

wget -m –no-parent -e robots=off  http://downloads.openwrt.org/chaos_calmer/15.05-rc3/ramips/mt7620/packages/

 

# config http server, here lighttpd

# add alias in configure:  alias.url = (“download.openwrt.org”=>”/mirror/openwrt/downloads.openwrt.org/”)

# restart http server

/etc/init.d/lighttpd restart

 

# Modify OPKG-Configuration in luci web site

# src/gz chaos_calmer_base http://localip/downloads.openwrt.org/…”

#…