u
This commit is contained in:
18
.github/workflows/lo-test.yml
vendored
18
.github/workflows/lo-test.yml
vendored
@@ -22,7 +22,7 @@ jobs:
|
|||||||
DEVICE: ${{ github.event.client_payload.device || github.event.inputs.device }}
|
DEVICE: ${{ github.event.client_payload.device || github.event.inputs.device }}
|
||||||
BRANCH: ${{ github.event.client_payload.branch || github.event.inputs.branch }}
|
BRANCH: ${{ github.event.client_payload.branch || github.event.inputs.branch }}
|
||||||
TG: ${{ secrets.TELEGRAM_BOT_TOKEN }}
|
TG: ${{ secrets.TELEGRAM_BOT_TOKEN }}
|
||||||
if: github.repository_owner=='klever1988'
|
if: github.repository_owner=='stupidloud'
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
|
|
||||||
@@ -50,10 +50,10 @@ jobs:
|
|||||||
- name: Checkout
|
- name: Checkout
|
||||||
run: |
|
run: |
|
||||||
cd
|
cd
|
||||||
curl -sL https://raw.githubusercontent.com/klever1988/nanopi-openwrt/zstd-bin/zstd | sudo tee /usr/bin/zstd > /dev/null
|
curl -sL https://raw.githubusercontent.com/stupidloud/nanopi-openwrt/zstd-bin/zstd | sudo tee /usr/bin/zstd > /dev/null
|
||||||
for i in {1..20}
|
for i in {1..20}
|
||||||
do
|
do
|
||||||
curl -sL --fail https://github.com/klever1988/sshactions/releases/download/cache/lede.$DEVICE.img.zst.0$i || break
|
curl -sL --fail https://github.com/stupidloud/sshactions/releases/download/cache/lede.$DEVICE.img.zst.0$i || break
|
||||||
done | zstdmt -d -o lede.img || (truncate -s 33g lede.img && mkfs.btrfs -M lede.img)
|
done | zstdmt -d -o lede.img || (truncate -s 33g lede.img && mkfs.btrfs -M lede.img)
|
||||||
LOOP_DEVICE=$(losetup -f) && echo "LOOP_DEVICE=$LOOP_DEVICE" >> $GITHUB_ENV
|
LOOP_DEVICE=$(losetup -f) && echo "LOOP_DEVICE=$LOOP_DEVICE" >> $GITHUB_ENV
|
||||||
sudo losetup -P --direct-io $LOOP_DEVICE lede.img
|
sudo losetup -P --direct-io $LOOP_DEVICE lede.img
|
||||||
@@ -96,7 +96,7 @@ jobs:
|
|||||||
cat .config
|
cat .config
|
||||||
|
|
||||||
- name: Debug via tmate
|
- name: Debug via tmate
|
||||||
uses: klever1988/ssh2actions@main
|
uses: stupidloud/ssh2actions@main
|
||||||
if: ${{ github.event.client_payload.debug == 'true' }}
|
if: ${{ github.event.client_payload.debug == 'true' }}
|
||||||
with:
|
with:
|
||||||
mode: ssh
|
mode: ssh
|
||||||
@@ -170,7 +170,7 @@ jobs:
|
|||||||
sudo umount lede
|
sudo umount lede
|
||||||
sudo losetup -d $LOOP_DEVICE
|
sudo losetup -d $LOOP_DEVICE
|
||||||
export AUTH="Authorization: token ${{ secrets.SEC_TOKEN }}"
|
export AUTH="Authorization: token ${{ secrets.SEC_TOKEN }}"
|
||||||
export cache_path='github.com/repos/klever1988/sshactions/releases'
|
export cache_path='github.com/repos/stupidloud/sshactions/releases'
|
||||||
export cache_repo_id='39020554'
|
export cache_repo_id='39020554'
|
||||||
#zstdmt -c --adapt --long lede.img | parallel --wc --block 1.99G --pipe \
|
#zstdmt -c --adapt --long lede.img | parallel --wc --block 1.99G --pipe \
|
||||||
#'curl -s --data-binary @- -H "$AUTH" -H "Content-Type: application/octet-stream" https://uploads.$cache_path/$cache_repo_id/assets?name=lede.'$DEVICE'.img.zst.0{#} > /dev/null'
|
#'curl -s --data-binary @- -H "$AUTH" -H "Content-Type: application/octet-stream" https://uploads.$cache_path/$cache_repo_id/assets?name=lede.'$DEVICE'.img.zst.0{#} > /dev/null'
|
||||||
@@ -187,7 +187,7 @@ jobs:
|
|||||||
xargs -n1 -i curl -X DELETE -H "$AUTH" "https://api.$cache_path/assets/{}"
|
xargs -n1 -i curl -X DELETE -H "$AUTH" "https://api.$cache_path/assets/{}"
|
||||||
ls *img.zst* ib-$DEVICE.tar.xz | parallel --wc 'while true; do curl -T {} -H "$AUTH" -H "Content-Type: application/octet-stream" "https://uploads.$cache_path/$cache_repo_id/assets?name={}" && break || true; done'
|
ls *img.zst* ib-$DEVICE.tar.xz | parallel --wc 'while true; do curl -T {} -H "$AUTH" -H "Content-Type: application/octet-stream" "https://uploads.$cache_path/$cache_repo_id/assets?name={}" && break || true; done'
|
||||||
set +e
|
set +e
|
||||||
for i in {1..20}; do curl -sL --fail https://github.com/klever1988/sshactions/releases/download/cache/lede.$DEVICE.img.zst.0$i || break; done | zstdmt -d -o /dev/null
|
for i in {1..20}; do curl -sL --fail https://github.com/stupidloud/sshactions/releases/download/cache/lede.$DEVICE.img.zst.0$i || break; done | zstdmt -d -o /dev/null
|
||||||
if [ $? -eq 0 ]; then break; fi
|
if [ $? -eq 0 ]; then break; fi
|
||||||
done
|
done
|
||||||
set -e
|
set -e
|
||||||
@@ -198,7 +198,7 @@ jobs:
|
|||||||
curl -k --data chat_id="${{secrets.TELEGRAM_CHAT_ID}}" --data "text=The ${{env.DEVICE}} build ran completed at ${{job.status}}." "https://api.telegram.org/bot${{secrets.TELEGRAM_BOT_TOKEN}}/sendMessage"
|
curl -k --data chat_id="${{secrets.TELEGRAM_CHAT_ID}}" --data "text=The ${{env.DEVICE}} build ran completed at ${{job.status}}." "https://api.telegram.org/bot${{secrets.TELEGRAM_BOT_TOKEN}}/sendMessage"
|
||||||
|
|
||||||
- name: Debug via tmate
|
- name: Debug via tmate
|
||||||
uses: klever1988/ssh2actions@main
|
uses: stupidloud/ssh2actions@main
|
||||||
if: ${{ failure() && env.TG }}
|
if: ${{ failure() && env.TG }}
|
||||||
with:
|
with:
|
||||||
mode: ssh
|
mode: ssh
|
||||||
@@ -228,7 +228,7 @@ jobs:
|
|||||||
sudo apt update && sudo apt install qemu-utils
|
sudo apt update && sudo apt install qemu-utils
|
||||||
sudo sysctl vm.swappiness=0
|
sudo sysctl vm.swappiness=0
|
||||||
ulimit -SHn 65000
|
ulimit -SHn 65000
|
||||||
curl -L https://github.com/klever1988/sshactions/releases/download/cache/ib-$DEVICE.tar.xz | tar -Jxvf -
|
curl -L https://github.com/stupidloud/sshactions/releases/download/cache/ib-$DEVICE.tar.xz | tar -Jxvf -
|
||||||
mv *imagebuilder* ib && cd ib
|
mv *imagebuilder* ib && cd ib
|
||||||
. $GITHUB_WORKSPACE/scripts/merge_files.sh
|
. $GITHUB_WORKSPACE/scripts/merge_files.sh
|
||||||
mkdir -p files/local_feed && sudo mount --bind packages files/local_feed
|
mkdir -p files/local_feed && sudo mount --bind packages files/local_feed
|
||||||
@@ -275,7 +275,7 @@ jobs:
|
|||||||
sudo apt update && sudo apt install qemu-utils
|
sudo apt update && sudo apt install qemu-utils
|
||||||
sudo sysctl vm.swappiness=0
|
sudo sysctl vm.swappiness=0
|
||||||
ulimit -SHn 65000
|
ulimit -SHn 65000
|
||||||
curl -L https://github.com/klever1988/sshactions/releases/download/cache/ib-$DEVICE.tar.xz | tar -Jxvf -
|
curl -L https://github.com/stupidloud/sshactions/releases/download/cache/ib-$DEVICE.tar.xz | tar -Jxvf -
|
||||||
set -x
|
set -x
|
||||||
mv *imagebuilder* ib && cd ib
|
mv *imagebuilder* ib && cd ib
|
||||||
. $GITHUB_WORKSPACE/scripts/merge_files.sh
|
. $GITHUB_WORKSPACE/scripts/merge_files.sh
|
||||||
|
|||||||
@@ -44,7 +44,7 @@
|
|||||||
|
|
||||||
- R2S加入了 https://github.com/NateLol/luci-app-oled 支持oled状态显示
|
- R2S加入了 https://github.com/NateLol/luci-app-oled 支持oled状态显示
|
||||||
|
|
||||||

|

|
||||||
|
|
||||||
## 2020-08-04
|
## 2020-08-04
|
||||||
|
|
||||||
@@ -92,7 +92,7 @@
|
|||||||
|
|
||||||
- 今天暂停更新其他版本,只更新minimal版。内核打入Openwrt官方的鸡血补丁,NAT性能有了炸天的表现。
|
- 今天暂停更新其他版本,只更新minimal版。内核打入Openwrt官方的鸡血补丁,NAT性能有了炸天的表现。
|
||||||
|
|
||||||

|

|
||||||
|
|
||||||
## 2020-03-01
|
## 2020-03-01
|
||||||
|
|
||||||
|
|||||||
10
README.md
10
README.md
@@ -9,7 +9,7 @@
|
|||||||
[1分钟生成自己所需固件](#1分钟生成自己所需固件)
|
[1分钟生成自己所需固件](#1分钟生成自己所需固件)
|
||||||
|
|
||||||
### 下载地址:
|
### 下载地址:
|
||||||
https://github.com/klever1988/nanopi-openwrt/tags
|
https://github.com/stupidloud/nanopi-openwrt/tags
|
||||||
(img.gz档不需要解压,可以直接使用刷机工具刷入)
|
(img.gz档不需要解压,可以直接使用刷机工具刷入)
|
||||||
|
|
||||||
### 使用提示:
|
### 使用提示:
|
||||||
@@ -19,11 +19,11 @@ https://github.com/klever1988/nanopi-openwrt/tags
|
|||||||
|
|
||||||
### 终端内在线升级方法:
|
### 终端内在线升级方法:
|
||||||
```bash
|
```bash
|
||||||
wget -qO- https://github.com/klever1988/nanopi-openwrt/raw/master/scripts/autoupdate-bash.sh | bash
|
wget -qO- https://github.com/stupidloud/nanopi-openwrt/raw/master/scripts/autoupdate-bash.sh | bash
|
||||||
```
|
```
|
||||||
slim版
|
slim版
|
||||||
```bash
|
```bash
|
||||||
wget -qO- https://github.com/klever1988/nanopi-openwrt/raw/master/scripts/autoupdate-bash.sh | ver=-slim bash
|
wget -qO- https://github.com/stupidloud/nanopi-openwrt/raw/master/scripts/autoupdate-bash.sh | ver=-slim bash
|
||||||
```
|
```
|
||||||
(脚本由gary lau提供,非常感谢!)
|
(脚本由gary lau提供,非常感谢!)
|
||||||
|
|
||||||
@@ -42,10 +42,10 @@ wget -qO- https://github.com/klever1988/nanopi-openwrt/raw/master/scripts/autoup
|
|||||||
再点击Run即可获取自己所需的固件
|
再点击Run即可获取自己所需的固件
|
||||||
|
|
||||||
### 更新说明:
|
### 更新说明:
|
||||||
https://github.com/klever1988/nanopi-openwrt/blob/master/CHANGELOG.md
|
https://github.com/stupidloud/nanopi-openwrt/blob/master/CHANGELOG.md
|
||||||
|
|
||||||
#### 本固件NAT基准性能测试:
|
#### 本固件NAT基准性能测试:
|
||||||
<img src="https://raw.githubusercontent.com/klever1988/nanopi-openwrt/master/assets/NAT.jpg" width="450" />
|
<img src="https://raw.githubusercontent.com/stupidloud/nanopi-openwrt/master/assets/NAT.jpg" width="450" />
|
||||||
|
|
||||||
#### 固件源码:
|
#### 固件源码:
|
||||||
https://github.com/coolsnowwolf/lede
|
https://github.com/coolsnowwolf/lede
|
||||||
|
|||||||
@@ -26,11 +26,11 @@ arch=`uname -m`
|
|||||||
mount -t tmpfs -o remount,size=850m tmpfs /tmp
|
mount -t tmpfs -o remount,size=850m tmpfs /tmp
|
||||||
rm -rf /tmp/upg && mkdir /tmp/upg && cd /tmp/upg
|
rm -rf /tmp/upg && mkdir /tmp/upg && cd /tmp/upg
|
||||||
|
|
||||||
latest_release_tag=`get_latest_release klever1988/nanopi-openwrt`
|
latest_release_tag=`get_latest_release stupidloud/nanopi-openwrt`
|
||||||
echo -e '\e[92m准备更新到'$latest_release_tag'\e[0m'
|
echo -e '\e[92m准备更新到'$latest_release_tag'\e[0m'
|
||||||
md5sum=`wget https://ghproxy.com/https://github.com/klever1988/nanopi-openwrt/releases/download/$latest_release_tag/$board_id$ver.img.gz -O- | tee >(gzip -dc>$board_id.img) | md5sum | awk '{print $1}'`
|
md5sum=`wget https://ghproxy.com/https://github.com/stupidloud/nanopi-openwrt/releases/download/$latest_release_tag/$board_id$ver.img.gz -O- | tee >(gzip -dc>$board_id.img) | md5sum | awk '{print $1}'`
|
||||||
if [ "$md5sum" != "d41d8cd98f00b204e9800998ecf8427e" ]; then
|
if [ "$md5sum" != "d41d8cd98f00b204e9800998ecf8427e" ]; then
|
||||||
wget https://ghproxy.com/https://github.com/klever1988/nanopi-openwrt/releases/download/$latest_release_tag/$board_id$ver.img.gz.md5 -O md5sum.txt
|
wget https://ghproxy.com/https://github.com/stupidloud/nanopi-openwrt/releases/download/$latest_release_tag/$board_id$ver.img.gz.md5 -O md5sum.txt
|
||||||
echo -e '\e[92m'$latest_release_tag'固件已下载\e[0m'
|
echo -e '\e[92m'$latest_release_tag'固件已下载\e[0m'
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|||||||
@@ -12,8 +12,8 @@ proceed_command sfdisk
|
|||||||
proceed_command losetup
|
proceed_command losetup
|
||||||
proceed_command resize2fs
|
proceed_command resize2fs
|
||||||
opkg install coreutils-truncate || true
|
opkg install coreutils-truncate || true
|
||||||
wget -NP /tmp https://ghproxy.com/https://raw.githubusercontent.com/klever1988/nanopi-openwrt/zstd-bin/truncate
|
wget -NP /tmp https://ghproxy.com/https://raw.githubusercontent.com/stupidloud/nanopi-openwrt/zstd-bin/truncate
|
||||||
wget -NP /tmp https://ghproxy.com/https://raw.githubusercontent.com/klever1988/nanopi-openwrt/zstd-bin/ddnz
|
wget -NP /tmp https://ghproxy.com/https://raw.githubusercontent.com/stupidloud/nanopi-openwrt/zstd-bin/ddnz
|
||||||
chmod +x /tmp/truncate /tmp/ddnz
|
chmod +x /tmp/truncate /tmp/ddnz
|
||||||
|
|
||||||
board_id=$(cat /etc/board.json | jsonfilter -e '@["model"].id' | sed 's/friendly.*,nanopi-//;s/xunlong,orangepi-//;s/^r1s-h5$/r1s/;s/^r1$/r1s-h3/;s/^r1-plus$/r1p/;s/^r1-plus-lts$/r1p-lts/;s/default-string-default-string/x86/;s/vmware-inc-vmware7-1/x86/')
|
board_id=$(cat /etc/board.json | jsonfilter -e '@["model"].id' | sed 's/friendly.*,nanopi-//;s/xunlong,orangepi-//;s/^r1s-h5$/r1s/;s/^r1$/r1s-h3/;s/^r1-plus$/r1p/;s/^r1-plus-lts$/r1p-lts/;s/default-string-default-string/x86/;s/vmware-inc-vmware7-1/x86/')
|
||||||
@@ -22,15 +22,15 @@ arch=`uname -m`
|
|||||||
mount -t tmpfs -o remount,size=850m tmpfs /tmp
|
mount -t tmpfs -o remount,size=850m tmpfs /tmp
|
||||||
rm -rf /tmp/upg && mkdir /tmp/upg && cd /tmp/upg
|
rm -rf /tmp/upg && mkdir /tmp/upg && cd /tmp/upg
|
||||||
set +e
|
set +e
|
||||||
wget https://ghproxy.com/https://github.com/klever1988/nanopi-openwrt/releases/download/$(date +%Y-%m-%d)/$board_id$ver.img.gz -O- | gzip -dc > $board_id.img
|
wget https://ghproxy.com/https://github.com/stupidloud/nanopi-openwrt/releases/download/$(date +%Y-%m-%d)/$board_id$ver.img.gz -O- | gzip -dc > $board_id.img
|
||||||
if [ $? -eq 0 ]; then
|
if [ $? -eq 0 ]; then
|
||||||
wget https://ghproxy.com/https://github.com/klever1988/nanopi-openwrt/releases/download/$(date +%Y-%m-%d)/$board_id$ver.img.md5 -O md5sum.txt
|
wget https://ghproxy.com/https://github.com/stupidloud/nanopi-openwrt/releases/download/$(date +%Y-%m-%d)/$board_id$ver.img.md5 -O md5sum.txt
|
||||||
echo -e '\e[92m今天固件已下载,准备解压\e[0m'
|
echo -e '\e[92m今天固件已下载,准备解压\e[0m'
|
||||||
else
|
else
|
||||||
echo -e '\e[91m今天的固件还没更新,尝试下载昨天的固件\e[0m'
|
echo -e '\e[91m今天的固件还没更新,尝试下载昨天的固件\e[0m'
|
||||||
wget https://ghproxy.com/https://github.com/klever1988/nanopi-openwrt/releases/download/$(date -d "@$(( $(busybox date +%s) - 86400))" +%Y-%m-%d)/$board_id$ver.img.gz -O- | gzip -dc > $board_id.img
|
wget https://ghproxy.com/https://github.com/stupidloud/nanopi-openwrt/releases/download/$(date -d "@$(( $(busybox date +%s) - 86400))" +%Y-%m-%d)/$board_id$ver.img.gz -O- | gzip -dc > $board_id.img
|
||||||
if [ $? -eq 0 ]; then
|
if [ $? -eq 0 ]; then
|
||||||
wget https://ghproxy.com/https://github.com/klever1988/nanopi-openwrt/releases/download/$(date -d "@$(( $(busybox date +%s) - 86400))" +%Y-%m-%d)/$board_id$ver.img.md5 -O md5sum.txt
|
wget https://ghproxy.com/https://github.com/stupidloud/nanopi-openwrt/releases/download/$(date -d "@$(( $(busybox date +%s) - 86400))" +%Y-%m-%d)/$board_id$ver.img.md5 -O md5sum.txt
|
||||||
echo -e '\e[92m昨天的固件已下载,准备解压\e[0m'
|
echo -e '\e[92m昨天的固件已下载,准备解压\e[0m'
|
||||||
else
|
else
|
||||||
echo -e '\e[91m没找到最新的固件,脚本退出\e[0m'
|
echo -e '\e[91m没找到最新的固件,脚本退出\e[0m'
|
||||||
|
|||||||
@@ -30,8 +30,8 @@ rm -rf package/custom; mkdir package/custom
|
|||||||
merge_feed nas "https://github.com/linkease/nas-packages;master"
|
merge_feed nas "https://github.com/linkease/nas-packages;master"
|
||||||
merge_feed nas_luci "https://github.com/linkease/nas-packages-luci;main"
|
merge_feed nas_luci "https://github.com/linkease/nas-packages-luci;main"
|
||||||
rm -r package/feeds/nas_luci/luci-app-ddnsto
|
rm -r package/feeds/nas_luci/luci-app-ddnsto
|
||||||
merge_feed helloworld "https://github.com/klever1988/helloworld;tmp"
|
merge_feed helloworld "https://github.com/stupidloud/helloworld;tmp"
|
||||||
#merge_package https://github.com/klever1988/openwrt-mos/trunk/luci-app-mosdns
|
#merge_package https://github.com/stupidloud/openwrt-mos/trunk/luci-app-mosdns
|
||||||
merge_package https://github.com/project-lede/luci-app-godproxy
|
merge_package https://github.com/project-lede/luci-app-godproxy
|
||||||
merge_package https://github.com/sundaqiang/openwrt-packages/trunk/luci-app-wolplus
|
merge_package https://github.com/sundaqiang/openwrt-packages/trunk/luci-app-wolplus
|
||||||
merge_package https://github.com/kuoruan/openwrt-frp frp
|
merge_package https://github.com/kuoruan/openwrt-frp frp
|
||||||
|
|||||||
@@ -80,11 +80,11 @@ case $status_page in
|
|||||||
*htm)
|
*htm)
|
||||||
line_number_FV=`grep -n 'Firmware Version' $status_page | cut -d: -f 1`
|
line_number_FV=`grep -n 'Firmware Version' $status_page | cut -d: -f 1`
|
||||||
sed -i '/ver\./d' $status_page
|
sed -i '/ver\./d' $status_page
|
||||||
sed -i $line_number_FV' a <a href="https://github.com/klever1988/nanopi-openwrt" target="_blank">klever1988/nanopi-openwrt</a> '$strDate $status_page
|
sed -i $line_number_FV' a <a href="https://github.com/stupidloud/nanopi-openwrt" target="_blank">stupidloud/nanopi-openwrt</a> '$strDate $status_page
|
||||||
;;
|
;;
|
||||||
*js)
|
*js)
|
||||||
line_number_FV=`grep -m1 -n 'var fields' $status_page | cut -d: -f1`
|
line_number_FV=`grep -m1 -n 'var fields' $status_page | cut -d: -f1`
|
||||||
sed -i $line_number_FV' i var pfv = document.createElement('\''placeholder'\'');pfv.innerHTML = '\''<a href="https://github.com/klever1988/nanopi-openwrt" target="_blank">klever1988/nanopi-openwrt</a> '$strDate"';" $status_page
|
sed -i $line_number_FV' i var pfv = document.createElement('\''placeholder'\'');pfv.innerHTML = '\''<a href="https://github.com/stupidloud/nanopi-openwrt" target="_blank">stupidloud/nanopi-openwrt</a> '$strDate"';" $status_page
|
||||||
line_number_FV=`grep -n 'Firmware Version' $status_page | cut -d : -f 1`
|
line_number_FV=`grep -n 'Firmware Version' $status_page | cut -d : -f 1`
|
||||||
sed -i '/Firmware Version/d' $status_page
|
sed -i '/Firmware Version/d' $status_page
|
||||||
sed -i $line_number_FV' a _('\''Firmware Version'\''), pfv,' $status_page
|
sed -i $line_number_FV' a _('\''Firmware Version'\''), pfv,' $status_page
|
||||||
|
|||||||
Reference in New Issue
Block a user