Skip to content

Commit

Permalink
omada relase 5.15.8.2
Browse files Browse the repository at this point in the history
  • Loading branch information
GeoffWilliams committed Feb 2, 2025
1 parent f99b731 commit 2c055c7
Show file tree
Hide file tree
Showing 5 changed files with 35 additions and 9 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ To build the image yourself:
1. Read the [pi-gen docs](./docs/pi-gen.md) to setup your build environment
2. Clone the repo
3. Switch to branch `omada`
4. Adjust (or disable...) proxy configuration in `config`. It seems necessary to build with an apt proxy to prevent timeouts
4. Setup your `sources.list` lines in `config` (eg to point to a nexus). Local caching seems required to avoid timeout
4. Run `build-docker.sh`
5. Burn the `full` image that the script generates with [Balena Etcher](https://etcher.balena.io/) or similar, then put SD card in pi and power on
6. For publising, rename the image file to include the version, eg:`omadapi-5.13.22-0.zip`
Expand Down
1 change: 1 addition & 0 deletions build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -224,6 +224,7 @@ export PUBKEY_SSH_FIRST_USER

export CLEAN
export APT_PROXY
export APT_SOURCES

export STAGE
export STAGE_DIR
Expand Down
15 changes: 13 additions & 2 deletions config
Original file line number Diff line number Diff line change
Expand Up @@ -12,5 +12,16 @@ ENABLE_SSH=1
STAGE_LIST="stage0 stage1 stage2 stageomada"
# this is my home apt cache - get lots of failing builds without a cache...
# im running squid-deb-proxy
APT_PROXY=http://squid.lan.asio:8000
DISABLE_FIRST_BOOT_USER_RENAME=1
DISABLE_FIRST_BOOT_USER_RENAME=1
APT_SOURCES="
deb http://nexus.ps.asio:8081/repository/debian_bookworm bookworm main non-free-firmware
deb-src http://httpredir.debian.org/debian/ bookworm main non-free-firmware

deb http://nexus.ps.asio:8081/repository/debian_bookworm_security bookworm-security main non-free-firmware
deb-src http://security.debian.org/debian-security bookworm-security main non-free-firmware

# bookworm-updates, to get updates before a point release is made;
# see https://www.debian.org/doc/manuals/debian-reference/ch02.en.html # _updates_and_backports
deb http://nexus.ps.asio:8081/repository/debian_bookworm_updates bookworm-updates main non-free-firmware
deb-src http://httpredir.debian.org/debian/ bookworm-updates main non-free-firmware
"
17 changes: 13 additions & 4 deletions stage0/00-configure-apt/00-run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,21 @@ sed -i "s/RELEASE/${RELEASE}/g" "${ROOTFS_DIR}/etc/apt/sources.list"
sed -i "s/RELEASE/${RELEASE}/g" "${ROOTFS_DIR}/etc/apt/sources.list.d/raspi.list"

if [ -n "$APT_PROXY" ]; then
install -m 644 files/51cache "${ROOTFS_DIR}/etc/apt/apt.conf.d/51cache"
sed "${ROOTFS_DIR}/etc/apt/apt.conf.d/51cache" -i -e "s|APT_PROXY|${APT_PROXY}|"
else
rm -f "${ROOTFS_DIR}/etc/apt/apt.conf.d/51cache"
echo "support for APT_PROXY was removed. Update your build"
exit 1
fi

if [ -n "$APT_SOURCES" ]; then
# cleaned up in stageomada
mv "${ROOTFS_DIR}/etc/apt/sources.list" "${ROOTFS_DIR}/etc/apt/sources.list.final"
echo "$APT_SOURCES" > "${ROOTFS_DIR}/etc/apt/sources.list"
echo "using APT_SOURCES"
cat "${ROOTFS_DIR}/etc/apt/sources.list"
fi

echo "apt sources.list for this build:"
cat "${ROOTFS_DIR}/etc/apt/sources.list"

cat files/raspberrypi.gpg.key | gpg --dearmor > "${STAGE_WORK_DIR}/raspberrypi-archive-stable.gpg"
install -m 644 "${STAGE_WORK_DIR}/raspberrypi-archive-stable.gpg" "${ROOTFS_DIR}/etc/apt/trusted.gpg.d/"
on_chroot <<- \EOF
Expand Down
9 changes: 7 additions & 2 deletions stageomada/10-omada/00-run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@ sed -i 's/^#CONF_MAXSWAP=2048/CONF_MAXSWAP=16384/' ${ROOTFS_DIR}/etc/dphys-swapf
# check for updates here! https://www.tp-link.com/en/support/download/omada-software-controller/
# Upstream sometimes change the filename supplied to wget after clicking the link so force saving
# with a consistent output file to prevent apt error: unsupported file ... given on commandline
OMADA_VERSION="5.14.26.1"
OMADA_VERSION="5.15.8.2"
wget -O ${ROOTFS_DIR}/packages/Omada_SDN_Controller_v${OMADA_VERSION}_linux_x64.deb \
https://static.tp-link.com/upload/software/2024/202407/20240710/Omada_SDN_Controller_v5.14.26.1_linux_x64.deb
https://static.tp-link.com/upload/software/2025/202501/20250109/Omada_SDN_Controller_v5.15.8.2_linux_x64.deb

# own debian package for jsvc
JSVC_VERSION=1.3.4
Expand Down Expand Up @@ -47,4 +47,9 @@ mv ${ROOTFS_DIR}/opt/tplink/EAPController/bin/control.sh ${ROOTFS_DIR}/opt/tplin
install -m 644 files/motd "${ROOTFS_DIR}/etc/motd"
install -m 755 files/control.sh "${ROOTFS_DIR}/opt/tplink/EAPController/bin/control.sh"

# Restore system defaults from stage0/00-configure-apt/00-run.sh
if [ -n "$APT_SOURCES" ]; then
mv "${ROOTFS_DIR}/etc/apt/sources.list.final" "${ROOTFS_DIR}/etc/apt/sources.list"
fi

# omada self enables on boot so were done

0 comments on commit 2c055c7

Please sign in to comment.