【HAM】MMDVM盒子更新代理
编辑
4
2025-10-27
最近沉迷折腾MMDVM盒子,因为一些众所周知的原因,github上面有一帮狗贼,在项目中加入了大量的中文关键词以宣传一些反动言论,严重污染了开源世界,导致github的访问存在一定的阻碍。pi-star作为一个开源项目,其中也大量用到了github仓库。
曾经BI7JTA做过gitee的同步仓库,但是最后一次同步已经是2年前了,现在(2025年)不建议继续使用BI7JTA的脚本。
操作步骤
允许读写
ssh连接pi-star,或者在web上,admin>expert>ssh_access,登录账号密码默认 pi-star raspiberry。
使用命令允许写入系统:
rpi-rw现在,就可以修改系统中的配置了。
手动停止服务
我们可以通过systemctl,手动停止pi-star相关的服务项。防止在修改过程中对服务造成一定的影响。
## 停止服务
sudo systemctl stop pistar-watchdog.timer
sudo systemctl stop pistar-watchdog.service
sudo systemctl stop mmdvmhost.timer
sudo systemctl stop mmdvmhost.service
sudo systemctl stop nextiondriver.service修改配置
使用sed -i 命令可以很轻松的直接替换文件的内容
sudo sed -i "s#https://github.com/AndyTaylorTweet/Pi-Star_v4_Binaries_Bin.git#https://gh-proxy.com/https://github.com/AndyTaylorTweet/Pi-Star_v4_Binaries_Bin.git#g" /usr/local/bin/.git/config
sudo sed -i "s#https://github.com/AndyTaylorTweet/Pi-Star_Binaries_sbin.git#https://gh-proxy.com/https://github.com/AndyTaylorTweet/Pi-Star_Binaries_sbin.git#g" /usr/local/sbin/.git/config
sudo sed -i "s#https://github.com/AndyTaylorTweet/Pi-Star_DV_Dash.git#https://gh-proxy.com/https://github.com/AndyTaylorTweet/Pi-Star_DV_Dash.git#g" /var/www/dashboard/.git/config重启服务
我们可以通过systemctl,手动重启pi-star相关的服务项。
sudo systemctl start pistar-watchdog.timer
sudo systemctl start pistar-watchdog.service
sudo systemctl start nextiondriver.service
sudo systemctl start mmdvmhost.timer
sudo systemctl start mmdvmhost.service更新pi-star
使用官方命令,进行一次pi-star更新
sudo pistar-update获得以下效果就是成功:
[INFO] Stopping Services...
[✓] Done
[INFO] Updating OS...
Hit:1 http://raspbian.raspberrypi.org/raspbian bullseye InRelease
Hit:2 http://archive.debian.org/debian bullseye-backports InRelease
Hit:3 https://archive.raspberrypi.org/debian bullseye InRelease
Reading package lists... Done
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Calculating upgrade... Done
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
[✓] Done
Checking nginx config
[INFO] Updating DV Binaries...
[✓] No updates for /usr/local/bin (Branch: master) available
[✓] Done
[INFO] Updating Pi-Star Binaries...
[✓] No updates for /usr/local/sbin (Branch: master) available
[✓] Done
[INFO] Updating Hostfiles...
[✓] Done
[INFO] Updating Dashboard...
[✓] No updates for /var/www/dashboard (Branch: master) available
[✓] Done
[INFO] Updating PiStar-Firewall...
[✓] Done
[INFO] Starting Services...
[✓] Done
[✓] Updates complete, syncing disk cache before making the disk Read-Only
[INFO] Finished附录·解决 bullseye-backports Release 404 Not Found
由于 bullseye-backports 仓库已经停止使用了,在软件源中, 是没有任何内容的。但是我们可以手动切换到LTS源,进行更新。虽然没什么用,但是没有404的报错总归舒服一点。
文件地址:/etc/apt/sources.list.d/bullseye-backports.list 使用你喜欢的编辑器,修改一下内部的内容。
需要把deb http://httpredir.debian.org/debian bullseye-backports main contrib non-free 这一行注释掉,方便出了问题改回来
文件内容如下
##cat /etc/apt/sources.list.d/bullseye-backports.list
# deb http://httpredir.debian.org/debian bullseye-backports main contrib non-free
deb http://archive.debian.org/debian/ bullseye-backports main contrib non-free修改后,使用apt命令更新软件源,最终效果如下:
pi-star@pi-star(rw):~$ sudo apt update
Hit:1 http://raspbian.raspberrypi.org/raspbian bullseye InRelease
Hit:2 https://archive.raspberrypi.org/debian bullseye InRelease
Hit:3 http://archive.debian.org/debian bullseye-backports InRelease
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
All packages are up to date.- 0
- 0
-
赞助
支付宝
微信
-
分享