├── .github
├── ISSUE_TEMPLATE
│ └── bugreport.yml
└── workflows
│ ├── ActionTrigger.yml
│ ├── RaspberryPi3.yml
│ ├── RaspberryPi4.yml
│ ├── RaspberryPi5.yml
│ ├── Rockchip.yml
│ ├── x86_64.yml
│ └── x86_64Lite.yml
├── LICENSE
├── README.md
├── assets
├── images
│ ├── action1.jpg
│ ├── appstore.png
│ ├── infinityfreedom-theme-main.png
│ ├── infinityfreedom-theme.png
│ ├── network.png
│ ├── openwrt.png
│ └── service.png
├── network.png
├── openwrt.png
└── service.png
├── configs
├── Driver.config
├── RPi3B.config
├── RPi4.config
├── RPi5.config
├── Rockchip.config
├── luci
│ ├── Lite.config
│ └── Standard.config
└── x86_64.config
├── configure.sh
├── openwrt-env
└── package.sh
/.github/ISSUE_TEMPLATE/bugreport.yml:
--------------------------------------------------------------------------------
1 | name: 问题描述[Bug]
2 | description: 反馈问题模板
3 | body:
4 | - type: textarea
5 | id: description
6 | attributes:
7 | label: 问题描述
8 | description: 详细叙述问题
9 | validations:
10 | required: true
11 | - type: checkboxes
12 | id: duplicate_issue
13 | attributes:
14 | label: 重复 issue
15 | description: 是否搜索了 issues
16 | options:
17 | - label: 没有类似的 issue
18 | required: true
19 | - type: checkboxes
20 | id: search_browser
21 | attributes:
22 | label: 浏览器搜索
23 | description: 是否在浏览器搜索了相关的问题
24 | options:
25 | - label: 未找到类似的问题
26 | required: true
27 | - type: dropdown
28 | id: Model
29 | attributes:
30 | label: "设备型号"
31 | description: "使用的设备型号"
32 | multiple: true
33 | options:
34 | - RaspberryPi3
35 | - RaspberryPi4
36 | - RaspberryPi5
37 | - x86_64
38 | - R68S
39 | - NanoPi R2S
40 | - NanoPi R4S
41 | - NanoPi R5C
42 | - NanoPi R5S
43 | - OrangePi R1 Plus
44 | validations:
45 | required: true
46 | - type: input
47 | id: firmware_name
48 | attributes:
49 | label: 固件版本
50 | description: 使用的固件名称(例如:openwrt-x86-64-generic-ext4-combined-efi.img.gz)
51 | validations:
52 | required: true
53 | - type: textarea
54 | id: details_log
55 | attributes:
56 | label: 详细日志
57 | description: 系统运行日志
58 | validations:
59 | required: true
--------------------------------------------------------------------------------
/.github/workflows/ActionTrigger.yml:
--------------------------------------------------------------------------------
1 | name: ActionTrigger
2 |
3 | env:
4 | REPO_URL: https://github.com/coolsnowwolf/lede
5 | REPO_BRANCH: master
6 | UPLOAD_RELEASE: true
7 |
8 | on:
9 | workflow_dispatch:
10 | schedule:
11 | - cron: '0 16 */7 * *'
12 |
13 | jobs:
14 | check:
15 | runs-on: ubuntu-latest
16 |
17 | steps:
18 | - name: Checkout
19 | uses: actions/checkout@v4
20 |
21 | - name: AutoTrigger
22 | uses: bigbugcc/ActionBot@main
23 |
24 | - name: Delete workflow runs
25 | uses: bigbugcc/delete-workflow-runs@main
26 | with:
27 | keep_minimum_runs: 1
28 |
29 | - name: Remove old Releases
30 | uses: dev-drprasad/delete-older-releases@v0.2.0
31 | if: env.UPLOAD_RELEASE == 'true' && !cancelled()
32 | with:
33 | keep_latest: 18
34 | delete_tags: true
35 | env:
36 | GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
--------------------------------------------------------------------------------
/.github/workflows/RaspberryPi3.yml:
--------------------------------------------------------------------------------
1 | name: Raspberry Pi3B+
2 |
3 | on:
4 | repository_dispatch:
5 | workflow_dispatch:
6 |
7 | env:
8 | OPNAME: 'Raspberry Pi3B+'
9 | REPO_URL: https://github.com/coolsnowwolf/lede
10 | REPO_BRANCH: master
11 | FEEDS_CONF: feeds.conf.default
12 | EXTERNAL_FILE: configs/luci/Standard.config
13 | CONFIG_FILE: configs/RPi3B.config
14 | SYS_CONF_SH: configure.sh
15 | PACKS: package.sh
16 | EXTEND_DRIVER: true
17 | UPLOAD_BIN_DIR: false
18 | UPLOAD_FIRMWARE: true
19 | UPLOAD_RELEASE: true
20 | TZ: Asia/Shanghai
21 |
22 | jobs:
23 | build:
24 | runs-on: ubuntu-22.04
25 |
26 | steps:
27 | - name: Checkout
28 | uses: actions/checkout@v4
29 |
30 | - name: Initialization environment
31 | env:
32 | DEBIAN_FRONTEND: noninteractive
33 | run: |
34 | sudo rm -rf /etc/apt/sources.list.d/*
35 | sudo -E apt-get -qq update
36 | sudo -E apt-get -qq install $(curl -fsSL https://raw.githubusercontent.com/bigbugcc/openwrts/master/openwrt-env)
37 | sudo -E apt-get -qq autoremove --purge
38 | sudo -E apt-get -qq clean
39 | sudo timedatectl set-timezone "$TZ"
40 | sudo mkdir -p /mnt/workdir
41 | sudo chown $USER:$GROUPS /mnt/workdir
42 |
43 | - name: Clone source code
44 | working-directory: /mnt/workdir
45 | run: |
46 | df -hT $PWD
47 | git clone --depth 1 $REPO_URL -b $REPO_BRANCH openwrt
48 | ln -sf /mnt/workdir/openwrt $GITHUB_WORKSPACE/openwrt
49 |
50 | - name: Cache
51 | uses: stupidloud/cachewrtbuild@main
52 | with:
53 | ccache: 'true'
54 | mixkey: 'rpi3'
55 | prefix: 'openwrt'
56 |
57 | - name: Load custom feeds
58 | run: |
59 | [ -e $FEEDS_CONF ] && mv $FEEDS_CONF openwrt/feeds.conf.default
60 | chmod +x $SYS_CONF_SH
61 | cd openwrt
62 | $GITHUB_WORKSPACE/$SYS_CONF_SH
63 |
64 | - name: Update feeds
65 | run: cd openwrt && ./scripts/feeds update -a
66 |
67 | - name: Install feeds
68 | run: cd openwrt && ./scripts/feeds install -a
69 |
70 | - name: Load custom configuration
71 | run: |
72 | [ -e files ] && mv files openwrt/files
73 | [ -e $CONFIG_FILE ] && mv $CONFIG_FILE openwrt/.config
74 | chmod +x $PACKS
75 | cd openwrt
76 | $GITHUB_WORKSPACE/$PACKS
77 |
78 | - name: Extend Driver
79 | if: env.EXTEND_DRIVER == 'true'
80 | run: |
81 | cat configs/Driver.config >> openwrt/.config
82 |
83 | - name: Modify configuration
84 | run: |
85 | cat $EXTERNAL_FILE >> openwrt/.config
86 | cd openwrt && make defconfig
87 | sed -i '/CONFIG_DEFAULT_luci/'d .config
88 | cat .config
89 |
90 | - name: Download package
91 | id: package
92 | run: |
93 | cd openwrt
94 | make download -j$(nproc)
95 | find dl -size -1024c -exec ls -l {} \;
96 | find dl -size -1024c -exec rm -f {} \;
97 |
98 | - name: Compile the firmware
99 | id: compile
100 | run: |
101 | cd openwrt
102 | echo -e "$(nproc) thread compile"
103 | make -j$(nproc) V=s || make -j4 V=s
104 | echo "status=success" >> $GITHUB_OUTPUT
105 | grep '^CONFIG_TARGET.*DEVICE.*=y' .config | sed -r 's/.*DEVICE_(.*)=y/\1/' > DEVICE_NAME
106 | [ -s DEVICE_NAME ] && echo "DEVICE_NAME=_$(cat DEVICE_NAME)" >> $GITHUB_ENV
107 | echo "FILE_DATE=_$(date +"%Y%m%d%H%M")" >> $GITHUB_ENV
108 |
109 | - name: Check space usage
110 | if: (!cancelled())
111 | run: df -hT
112 |
113 | - name: Upload bin directory
114 | uses: actions/upload-artifact@main
115 | if: steps.compile.outputs.status == 'success' && env.UPLOAD_BIN_DIR == 'true'
116 | with:
117 | name: OpenWrt_bin${{ env.DEVICE_NAME }}${{ env.FILE_DATE }}
118 | path: openwrt/bin
119 |
120 | - name: Organize files
121 | id: organize
122 | if: steps.compile.outputs.status == 'success' && env.UPLOAD_FIRMWARE == 'true' && !cancelled()
123 | run: |
124 | cd openwrt/bin/targets/*/*
125 | rm -rf packages
126 | echo "FIRMWARE=$PWD" >> $GITHUB_ENV
127 | echo "status=success" >> $GITHUB_OUTPUT
128 |
129 | - name: Upload firmware directory
130 | uses: actions/upload-artifact@main
131 | if: steps.organize.outputs.status == 'success' && !cancelled()
132 | with:
133 | name: OpenWrt_firmware${{ env.DEVICE_NAME }}${{ env.FILE_DATE }}
134 | path: ${{ env.FIRMWARE }}
135 |
136 | - name: Generate release tag
137 | id: tag
138 | if: steps.compile.outputs.status == 'success' && env.UPLOAD_RELEASE == 'true' && !cancelled()
139 | run: |
140 | echo "== Time:$(date +'%Y-%m-%d %H:%M:%S') =="
141 | echo "release_tag=$(date +"%Y.%m.%d-%H%M%S")" >> $GITHUB_OUTPUT
142 | touch release.txt
143 | echo "status=success" >> $GITHUB_OUTPUT
144 |
145 | - name: Generate release body
146 | if: steps.compile.outputs.status == 'success' && !cancelled()
147 | run: |
148 | echo "" >> release.txt
149 |
150 | - name: Upload firmware to release
151 | uses: softprops/action-gh-release@v1
152 | if: steps.tag.outputs.status == 'success' && !cancelled()
153 | env:
154 | GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
155 | with:
156 | name: ${{ env.OPNAME }}
157 | tag_name: ${{ steps.tag.outputs.release_tag }}
158 | body_path: release.txt
159 | files: ${{ env.FIRMWARE }}/*
--------------------------------------------------------------------------------
/.github/workflows/RaspberryPi4.yml:
--------------------------------------------------------------------------------
1 | name: Raspberry Pi4
2 |
3 | on:
4 | repository_dispatch:
5 | workflow_dispatch:
6 |
7 | env:
8 | OPNAME: 'Raspberry Pi4'
9 | REPO_URL: https://github.com/coolsnowwolf/lede
10 | REPO_BRANCH: master
11 | FEEDS_CONF: feeds.conf.default
12 | EXTERNAL_FILE: configs/luci/Standard.config
13 | CONFIG_FILE: configs/RPi4.config
14 | SYS_CONF_SH: configure.sh
15 | PACKS: package.sh
16 | EXTEND_DRIVER: true
17 | UPLOAD_BIN_DIR: false
18 | UPLOAD_FIRMWARE: true
19 | UPLOAD_RELEASE: true
20 | TZ: Asia/Shanghai
21 |
22 | jobs:
23 | build:
24 | runs-on: ubuntu-22.04
25 |
26 | steps:
27 | - name: Checkout
28 | uses: actions/checkout@v4
29 |
30 | - name: Initialization environment
31 | env:
32 | DEBIAN_FRONTEND: noninteractive
33 | run: |
34 | sudo rm -rf /etc/apt/sources.list.d/*
35 | sudo -E apt-get -qq update
36 | sudo -E apt-get -qq install $(curl -fsSL https://raw.githubusercontent.com/bigbugcc/openwrts/master/openwrt-env)
37 | sudo -E apt-get -qq autoremove --purge
38 | sudo -E apt-get -qq clean
39 | sudo timedatectl set-timezone "$TZ"
40 | sudo mkdir -p /mnt/workdir
41 | sudo chown $USER:$GROUPS /mnt/workdir
42 |
43 | - name: Clone source code
44 | working-directory: /mnt/workdir
45 | run: |
46 | df -hT $PWD
47 | git clone --depth 1 $REPO_URL -b $REPO_BRANCH openwrt
48 | ln -sf /mnt/workdir/openwrt $GITHUB_WORKSPACE/openwrt
49 |
50 | - name: Cache
51 | uses: stupidloud/cachewrtbuild@main
52 | with:
53 | ccache: 'true'
54 | mixkey: 'rpi4'
55 | prefix: 'openwrt'
56 |
57 | - name: Load custom feeds
58 | run: |
59 | [ -e $FEEDS_CONF ] && mv $FEEDS_CONF openwrt/feeds.conf.default
60 | chmod +x $SYS_CONF_SH
61 | cd openwrt
62 | $GITHUB_WORKSPACE/$SYS_CONF_SH
63 |
64 | - name: Update feeds
65 | run: cd openwrt && ./scripts/feeds update -a
66 |
67 | - name: Install feeds
68 | run: cd openwrt && ./scripts/feeds install -a
69 |
70 | - name: Load custom configuration
71 | run: |
72 | [ -e files ] && mv files openwrt/files
73 | [ -e $CONFIG_FILE ] && mv $CONFIG_FILE openwrt/.config
74 | chmod +x $PACKS
75 | cd openwrt
76 | $GITHUB_WORKSPACE/$PACKS
77 |
78 | - name: Extend Driver
79 | if: env.EXTEND_DRIVER == 'true'
80 | run: |
81 | cat configs/Driver.config >> openwrt/.config
82 |
83 | - name: Modify configuration
84 | run: |
85 | cat $EXTERNAL_FILE >> openwrt/.config
86 | cd openwrt && make defconfig
87 | sed -i '/CONFIG_DEFAULT_luci/'d .config
88 | cat .config
89 |
90 | - name: Download package
91 | id: package
92 | run: |
93 | cd openwrt
94 | make download -j$(nproc)
95 | find dl -size -1024c -exec ls -l {} \;
96 | find dl -size -1024c -exec rm -f {} \;
97 |
98 | - name: Compile the firmware
99 | id: compile
100 | run: |
101 | cd openwrt
102 | echo -e "$(nproc) thread compile"
103 | make -j$(nproc) V=s || make -j4 V=s
104 | echo "status=success" >> $GITHUB_OUTPUT
105 | grep '^CONFIG_TARGET.*DEVICE.*=y' .config | sed -r 's/.*DEVICE_(.*)=y/\1/' > DEVICE_NAME
106 | [ -s DEVICE_NAME ] && echo "DEVICE_NAME=_$(cat DEVICE_NAME)" >> $GITHUB_ENV
107 | echo "FILE_DATE=_$(date +"%Y%m%d%H%M")" >> $GITHUB_ENV
108 |
109 | - name: Check space usage
110 | if: (!cancelled())
111 | run: df -hT
112 |
113 | - name: Upload bin directory
114 | uses: actions/upload-artifact@main
115 | if: steps.compile.outputs.status == 'success' && env.UPLOAD_BIN_DIR == 'true'
116 | with:
117 | name: OpenWrt_bin${{ env.DEVICE_NAME }}${{ env.FILE_DATE }}
118 | path: openwrt/bin
119 |
120 | - name: Organize files
121 | id: organize
122 | if: steps.compile.outputs.status == 'success' && env.UPLOAD_FIRMWARE == 'true' && !cancelled()
123 | run: |
124 | cd openwrt/bin/targets/*/*
125 | rm -rf packages
126 | echo "FIRMWARE=$PWD" >> $GITHUB_ENV
127 | echo "status=success" >> $GITHUB_OUTPUT
128 |
129 | - name: Upload firmware directory
130 | uses: actions/upload-artifact@main
131 | if: steps.organize.outputs.status == 'success' && !cancelled()
132 | with:
133 | name: OpenWrt_firmware${{ env.DEVICE_NAME }}${{ env.FILE_DATE }}
134 | path: ${{ env.FIRMWARE }}
135 |
136 | - name: Generate release tag
137 | id: tag
138 | if: steps.compile.outputs.status == 'success' && env.UPLOAD_RELEASE == 'true' && !cancelled()
139 | run: |
140 | echo "== Time:$(date +'%Y-%m-%d %H:%M:%S') =="
141 | echo "release_tag=$(date +"%Y.%m.%d-%H%M%S")" >> $GITHUB_OUTPUT
142 | touch release.txt
143 | echo "status=success" >> $GITHUB_OUTPUT
144 |
145 | - name: Generate release body
146 | if: steps.compile.outputs.status == 'success' && !cancelled()
147 | run: |
148 | echo "" >> release.txt
149 |
150 | - name: Upload firmware to release
151 | uses: softprops/action-gh-release@v1
152 | if: steps.tag.outputs.status == 'success' && !cancelled()
153 | env:
154 | GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
155 | with:
156 | name: ${{ env.OPNAME }}
157 | tag_name: ${{ steps.tag.outputs.release_tag }}
158 | body_path: release.txt
159 | files: ${{ env.FIRMWARE }}/*
160 |
--------------------------------------------------------------------------------
/.github/workflows/RaspberryPi5.yml:
--------------------------------------------------------------------------------
1 | name: Raspberry Pi5
2 |
3 | on:
4 | repository_dispatch:
5 | workflow_dispatch:
6 |
7 | env:
8 | OPNAME: 'Raspberry Pi5'
9 | REPO_URL: https://github.com/coolsnowwolf/lede
10 | REPO_BRANCH: master
11 | FEEDS_CONF: feeds.conf.default
12 | EXTERNAL_FILE: configs/luci/Standard.config
13 | CONFIG_FILE: configs/RPi5.config
14 | SYS_CONF_SH: configure.sh
15 | PACKS: package.sh
16 | EXTEND_DRIVER: true
17 | UPLOAD_BIN_DIR: false
18 | UPLOAD_FIRMWARE: true
19 | UPLOAD_RELEASE: true
20 | TZ: Asia/Shanghai
21 |
22 | jobs:
23 | build:
24 | runs-on: ubuntu-22.04
25 |
26 | steps:
27 | - name: Checkout
28 | uses: actions/checkout@v4
29 |
30 | - name: Initialization environment
31 | env:
32 | DEBIAN_FRONTEND: noninteractive
33 | run: |
34 | sudo rm -rf /etc/apt/sources.list.d/*
35 | sudo -E apt-get -qq update
36 | sudo -E apt-get -qq install $(curl -fsSL https://raw.githubusercontent.com/bigbugcc/openwrts/master/openwrt-env)
37 | sudo -E apt-get -qq autoremove --purge
38 | sudo -E apt-get -qq clean
39 | sudo timedatectl set-timezone "$TZ"
40 | sudo mkdir -p /mnt/workdir
41 | sudo chown $USER:$GROUPS /mnt/workdir
42 |
43 | - name: Clone source code
44 | working-directory: /mnt/workdir
45 | run: |
46 | df -hT $PWD
47 | git clone --depth 1 $REPO_URL -b $REPO_BRANCH openwrt
48 | ln -sf /mnt/workdir/openwrt $GITHUB_WORKSPACE/openwrt
49 |
50 | - name: Cache
51 | uses: stupidloud/cachewrtbuild@main
52 | with:
53 | ccache: 'true'
54 | mixkey: 'rpi5'
55 | prefix: 'openwrt'
56 |
57 | - name: Load custom feeds
58 | run: |
59 | [ -e $FEEDS_CONF ] && mv $FEEDS_CONF openwrt/feeds.conf.default
60 | chmod +x $SYS_CONF_SH
61 | cd openwrt
62 | $GITHUB_WORKSPACE/$SYS_CONF_SH
63 |
64 | - name: Update feeds
65 | run: cd openwrt && ./scripts/feeds update -a
66 |
67 | - name: Install feeds
68 | run: cd openwrt && ./scripts/feeds install -a
69 |
70 | - name: Load custom configuration
71 | run: |
72 | [ -e files ] && mv files openwrt/files
73 | [ -e $CONFIG_FILE ] && mv $CONFIG_FILE openwrt/.config
74 | chmod +x $PACKS
75 | cd openwrt
76 | $GITHUB_WORKSPACE/$PACKS
77 |
78 | - name: Extend Driver
79 | if: env.EXTEND_DRIVER == 'true'
80 | run: |
81 | cat configs/Driver.config >> openwrt/.config
82 |
83 | - name: Modify configuration
84 | run: |
85 | cat $EXTERNAL_FILE >> openwrt/.config
86 | cd openwrt && make defconfig
87 | sed -i '/CONFIG_DEFAULT_luci/'d .config
88 | cat .config
89 |
90 | - name: Download package
91 | id: package
92 | run: |
93 | cd openwrt
94 | make download -j$(nproc)
95 | find dl -size -1024c -exec ls -l {} \;
96 | find dl -size -1024c -exec rm -f {} \;
97 |
98 | - name: Compile the firmware
99 | id: compile
100 | run: |
101 | cd openwrt
102 | echo -e "$(nproc) thread compile"
103 | make -j$(nproc) V=s || make -j4 V=s
104 | echo "status=success" >> $GITHUB_OUTPUT
105 | grep '^CONFIG_TARGET.*DEVICE.*=y' .config | sed -r 's/.*DEVICE_(.*)=y/\1/' > DEVICE_NAME
106 | [ -s DEVICE_NAME ] && echo "DEVICE_NAME=_$(cat DEVICE_NAME)" >> $GITHUB_ENV
107 | echo "FILE_DATE=_$(date +"%Y%m%d%H%M")" >> $GITHUB_ENV
108 |
109 | - name: Check space usage
110 | if: (!cancelled())
111 | run: df -hT
112 |
113 | - name: Upload bin directory
114 | uses: actions/upload-artifact@main
115 | if: steps.compile.outputs.status == 'success' && env.UPLOAD_BIN_DIR == 'true'
116 | with:
117 | name: OpenWrt_bin${{ env.DEVICE_NAME }}${{ env.FILE_DATE }}
118 | path: openwrt/bin
119 |
120 | - name: Organize files
121 | id: organize
122 | if: steps.compile.outputs.status == 'success' && env.UPLOAD_FIRMWARE == 'true' && !cancelled()
123 | run: |
124 | cd openwrt/bin/targets/*/*
125 | rm -rf packages
126 | echo "FIRMWARE=$PWD" >> $GITHUB_ENV
127 | echo "status=success" >> $GITHUB_OUTPUT
128 |
129 | - name: Upload firmware directory
130 | uses: actions/upload-artifact@main
131 | if: steps.organize.outputs.status == 'success' && !cancelled()
132 | with:
133 | name: OpenWrt_firmware${{ env.DEVICE_NAME }}${{ env.FILE_DATE }}
134 | path: ${{ env.FIRMWARE }}
135 |
136 | - name: Generate release tag
137 | id: tag
138 | if: steps.compile.outputs.status == 'success' && env.UPLOAD_RELEASE == 'true' && !cancelled()
139 | run: |
140 | echo "== Time:$(date +'%Y-%m-%d %H:%M:%S') =="
141 | echo "release_tag=$(date +"%Y.%m.%d-%H%M%S")" >> $GITHUB_OUTPUT
142 | touch release.txt
143 | echo "status=success" >> $GITHUB_OUTPUT
144 |
145 | - name: Generate release body
146 | if: steps.compile.outputs.status == 'success' && !cancelled()
147 | run: |
148 | echo "" >> release.txt
149 |
150 | - name: Upload firmware to release
151 | uses: softprops/action-gh-release@v1
152 | if: steps.tag.outputs.status == 'success' && !cancelled()
153 | env:
154 | GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
155 | with:
156 | name: ${{ env.OPNAME }}
157 | tag_name: ${{ steps.tag.outputs.release_tag }}
158 | body_path: release.txt
159 | files: ${{ env.FIRMWARE }}/*
--------------------------------------------------------------------------------
/.github/workflows/Rockchip.yml:
--------------------------------------------------------------------------------
1 | name: Rockchip
2 |
3 | on:
4 | repository_dispatch:
5 | workflow_dispatch:
6 |
7 | env:
8 | OPNAME: 'R68S、R2S、R4S、R5C、R5S、OPiR1Plus'
9 | REPO_URL: https://github.com/coolsnowwolf/lede
10 | REPO_BRANCH: master
11 | FEEDS_CONF: feeds.conf.default
12 | EXTERNAL_FILE: configs/luci/Standard.config
13 | CONFIG_FILE: configs/Rockchip.config
14 | SYS_CONF_SH: configure.sh
15 | PACKS: package.sh
16 | EXTEND_DRIVER: true
17 | UPLOAD_BIN_DIR: false
18 | UPLOAD_FIRMWARE: true
19 | UPLOAD_RELEASE: true
20 | TZ: Asia/Shanghai
21 |
22 | jobs:
23 | build:
24 | runs-on: ubuntu-22.04
25 |
26 | steps:
27 | - name: Checkout
28 | uses: actions/checkout@v4
29 |
30 | - name: Initialization environment
31 | env:
32 | DEBIAN_FRONTEND: noninteractive
33 | run: |
34 | sudo rm -rf /etc/apt/sources.list.d/*
35 | sudo -E apt-get -qq update
36 | sudo -E apt-get -qq install $(curl -fsSL https://raw.githubusercontent.com/bigbugcc/openwrts/master/openwrt-env)
37 | sudo -E apt-get -qq autoremove --purge
38 | sudo -E apt-get -qq clean
39 | sudo timedatectl set-timezone "$TZ"
40 | sudo mkdir -p /mnt/workdir
41 | sudo chown $USER:$GROUPS /mnt/workdir
42 |
43 | - name: Clone source code
44 | working-directory: /mnt/workdir
45 | run: |
46 | df -hT $PWD
47 | git clone --depth 1 $REPO_URL -b $REPO_BRANCH openwrt
48 | ln -sf /mnt/workdir/openwrt $GITHUB_WORKSPACE/openwrt
49 |
50 | - name: Cache
51 | uses: stupidloud/cachewrtbuild@main
52 | with:
53 | ccache: 'true'
54 | mixkey: 'armv8'
55 | prefix: 'openwrt'
56 |
57 | - name: Load custom feeds
58 | run: |
59 | [ -e $FEEDS_CONF ] && mv $FEEDS_CONF openwrt/feeds.conf.default
60 | chmod +x $SYS_CONF_SH
61 | cd openwrt
62 | $GITHUB_WORKSPACE/$SYS_CONF_SH
63 |
64 | - name: Update feeds
65 | run: cd openwrt && ./scripts/feeds update -a
66 |
67 | - name: Install feeds
68 | run: cd openwrt && ./scripts/feeds install -a
69 |
70 | - name: Load custom configuration
71 | run: |
72 | [ -e files ] && mv files openwrt/files
73 | [ -e $CONFIG_FILE ] && mv $CONFIG_FILE openwrt/.config
74 | chmod +x $PACKS
75 | cd openwrt
76 | $GITHUB_WORKSPACE/$PACKS
77 |
78 | - name: Extend Driver
79 | if: env.EXTEND_DRIVER == 'true'
80 | run: |
81 | cat configs/Driver.config >> openwrt/.config
82 |
83 | - name: Modify configuration
84 | run: |
85 | cat $EXTERNAL_FILE >> openwrt/.config
86 | cd openwrt && make defconfig
87 | sed -i '/CONFIG_DEFAULT_luci/'d .config
88 | cat .config
89 |
90 | - name: Download package
91 | id: package
92 | run: |
93 | cd openwrt
94 | make download -j$(nproc)
95 | find dl -size -1024c -exec ls -l {} \;
96 | find dl -size -1024c -exec rm -f {} \;
97 |
98 | - name: Compile the firmware
99 | id: compile
100 | run: |
101 | cd openwrt
102 | echo -e "$(nproc) thread compile"
103 | make -j$(nproc) V=s || make -j4 V=s
104 | echo "status=success" >> $GITHUB_OUTPUT
105 | echo "DEVICE_NAME=R2S-R4S-OPiR1Plus" >> $GITHUB_ENV
106 | echo "FILE_DATE=_$(date +"%Y%m%d%H%M")" >> $GITHUB_ENV
107 |
108 | - name: Check space usage
109 | if: (!cancelled())
110 | run: df -hT
111 |
112 | - name: Upload bin directory
113 | uses: actions/upload-artifact@main
114 | if: steps.compile.outputs.status == 'success' && env.UPLOAD_BIN_DIR == 'true'
115 | with:
116 | name: OpenWrt_bin${{ env.DEVICE_NAME }}${{ env.FILE_DATE }}
117 | path: openwrt/bin
118 |
119 | - name: Organize files
120 | id: organize
121 | if: steps.compile.outputs.status == 'success' && env.UPLOAD_FIRMWARE == 'true' && !cancelled()
122 | run: |
123 | cd openwrt/bin/targets/*/*
124 | rm -rf packages
125 | echo "FIRMWARE=$PWD" >> $GITHUB_ENV
126 | echo "status=success" >> $GITHUB_OUTPUT
127 |
128 | - name: Upload firmware directory
129 | uses: actions/upload-artifact@main
130 | if: steps.organize.outputs.status == 'success' && !cancelled()
131 | with:
132 | name: OpenWrt_firmware${{ env.DEVICE_NAME }}${{ env.FILE_DATE }}
133 | path: ${{ env.FIRMWARE }}
134 |
135 | - name: Generate release tag
136 | id: tag
137 | if: steps.compile.outputs.status == 'success' && env.UPLOAD_RELEASE == 'true' && !cancelled()
138 | run: |
139 | echo "== Time:$(date +'%Y-%m-%d %H:%M:%S') =="
140 | echo "release_tag=$(date +"%Y.%m.%d-%H%M%S")" >> $GITHUB_OUTPUT
141 | touch release.txt
142 | echo "status=success" >> $GITHUB_OUTPUT
143 |
144 | - name: Generate release body
145 | if: steps.compile.outputs.status == 'success' && !cancelled()
146 | run: |
147 | echo "" >> release.txt
148 | echo "- FastRhino R68S" >> release.txt
149 | echo "- FriendlyARM NanoPi R2S | R4S | R5C | R5S " >> release.txt
150 | echo "- Xunlong Orange Pi R1 Plus" >> release.txt
151 |
152 | - name: Upload firmware to release
153 | uses: softprops/action-gh-release@v1
154 | if: steps.tag.outputs.status == 'success' && !cancelled()
155 | env:
156 | GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
157 | with:
158 | name: ${{ env.OPNAME }}
159 | tag_name: ${{ steps.tag.outputs.release_tag }}
160 | body_path: release.txt
161 | files: ${{ env.FIRMWARE }}/*
162 |
--------------------------------------------------------------------------------
/.github/workflows/x86_64.yml:
--------------------------------------------------------------------------------
1 | name: x86_64
2 |
3 | on:
4 | repository_dispatch:
5 | workflow_dispatch:
6 |
7 | env:
8 | OPNAME: 'x86_64'
9 | REPO_URL: https://github.com/coolsnowwolf/lede
10 | REPO_BRANCH: master
11 | FEEDS_CONF: feeds.conf.default
12 | EXTERNAL_FILE: configs/luci/Standard.config
13 | CONFIG_FILE: configs/x86_64.config
14 | SYS_CONF_SH: configure.sh
15 | PACKS: package.sh
16 | EXTEND_DRIVER: true
17 | UPLOAD_BIN_DIR: false
18 | UPLOAD_FIRMWARE: true
19 | UPLOAD_RELEASE: true
20 | TZ: Asia/Shanghai
21 |
22 | jobs:
23 | build:
24 | runs-on: ubuntu-22.04
25 |
26 | steps:
27 | - name: Checkout
28 | uses: actions/checkout@v4
29 |
30 | - name: Initialization environment
31 | env:
32 | DEBIAN_FRONTEND: noninteractive
33 | run: |
34 | sudo rm -rf /etc/apt/sources.list.d/*
35 | sudo -E apt-get -qq update
36 | sudo -E apt-get -qq install $(curl -fsSL https://raw.githubusercontent.com/bigbugcc/openwrts/master/openwrt-env)
37 | sudo -E apt-get -qq autoremove --purge
38 | sudo -E apt-get -qq clean
39 | sudo timedatectl set-timezone "$TZ"
40 | sudo mkdir -p /mnt/workdir
41 | sudo chown $USER:$GROUPS /mnt/workdir
42 |
43 | - name: Clone source code
44 | working-directory: /mnt/workdir
45 | run: |
46 | df -hT $PWD
47 | git clone --depth 1 $REPO_URL -b $REPO_BRANCH openwrt
48 | ln -sf /mnt/workdir/openwrt $GITHUB_WORKSPACE/openwrt
49 |
50 | - name: Cache
51 | uses: stupidloud/cachewrtbuild@main
52 | with:
53 | ccache: 'true'
54 | mixkey: 'x86'
55 | prefix: 'openwrt'
56 |
57 | - name: Load custom feeds
58 | run: |
59 | [ -e $FEEDS_CONF ] && mv $FEEDS_CONF openwrt/feeds.conf.default
60 | chmod +x $SYS_CONF_SH
61 | cd openwrt
62 | $GITHUB_WORKSPACE/$SYS_CONF_SH
63 |
64 | - name: Update feeds
65 | run: cd openwrt && ./scripts/feeds update -a
66 |
67 | - name: Install feeds
68 | run: cd openwrt && ./scripts/feeds install -a
69 |
70 | - name: Load custom configuration
71 | run: |
72 | [ -e files ] && mv files openwrt/files
73 | [ -e $CONFIG_FILE ] && mv $CONFIG_FILE openwrt/.config
74 | chmod +x $PACKS
75 | cd openwrt
76 | $GITHUB_WORKSPACE/$PACKS
77 |
78 | - name: Extend Driver
79 | if: env.EXTEND_DRIVER == 'true'
80 | run: |
81 | cat configs/Driver.config >> openwrt/.config
82 |
83 | - name: Modify configuration
84 | run: |
85 | cat $EXTERNAL_FILE >> openwrt/.config
86 | cd openwrt && make defconfig
87 | sed -i '/CONFIG_DEFAULT_luci/'d .config
88 | cat .config
89 |
90 | - name: Download package
91 | id: package
92 | run: |
93 | cd openwrt
94 | make download -j$(nproc)
95 | find dl -size -1024c -exec ls -l {} \;
96 | find dl -size -1024c -exec rm -f {} \;
97 |
98 | - name: Compile the firmware
99 | id: compile
100 | run: |
101 | cd openwrt
102 | echo -e "$(nproc) thread compile"
103 | make -j$(nproc) V=s || make -j4 V=s
104 | echo "status=success" >> $GITHUB_OUTPUT
105 | grep '^CONFIG_TARGET.*DEVICE.*=y' .config | sed -r 's/.*DEVICE_(.*)=y/\1/' > DEVICE_NAME
106 | [ -s DEVICE_NAME ] && echo "DEVICE_NAME=_$(cat DEVICE_NAME)" >> $GITHUB_ENV
107 | echo "FILE_DATE=_$(date +"%Y%m%d%H%M")" >> $GITHUB_ENV
108 |
109 | - name: Check space usage
110 | if: (!cancelled())
111 | run: df -hT
112 |
113 | - name: Upload bin directory
114 | uses: actions/upload-artifact@main
115 | if: steps.compile.outputs.status == 'success' && env.UPLOAD_BIN_DIR == 'true'
116 | with:
117 | name: OpenWrt_bin${{ env.DEVICE_NAME }}${{ env.FILE_DATE }}
118 | path: openwrt/bin
119 |
120 | - name: Organize files
121 | id: organize
122 | if: steps.compile.outputs.status == 'success' && env.UPLOAD_FIRMWARE == 'true' && !cancelled()
123 | run: |
124 | cd openwrt/bin/targets/*/*
125 | rm -rf packages
126 | echo "FIRMWARE=$PWD" >> $GITHUB_ENV
127 | echo "status=success" >> $GITHUB_OUTPUT
128 |
129 | - name: Upload firmware directory
130 | uses: actions/upload-artifact@main
131 | if: steps.organize.outputs.status == 'success' && !cancelled()
132 | with:
133 | name: OpenWrt_firmware${{ env.DEVICE_NAME }}${{ env.FILE_DATE }}
134 | path: ${{ env.FIRMWARE }}
135 |
136 | - name: Generate release tag
137 | id: tag
138 | if: steps.compile.outputs.status == 'success' && env.UPLOAD_RELEASE == 'true' && !cancelled()
139 | run: |
140 | echo "== Time:$(date +'%Y-%m-%d %H:%M:%S') =="
141 | echo "release_tag=$(date +"%Y.%m.%d-%H%M%S")" >> $GITHUB_OUTPUT
142 | touch release.txt
143 | echo "status=success" >> $GITHUB_OUTPUT
144 |
145 | - name: Generate release body
146 | if: steps.compile.outputs.status == 'success' && !cancelled()
147 | run: |
148 | echo "" >> release.txt
149 |
150 | - name: Upload firmware to release
151 | uses: softprops/action-gh-release@v1
152 | if: steps.tag.outputs.status == 'success' && !cancelled()
153 | env:
154 | GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
155 | with:
156 | name: ${{ env.OPNAME }}
157 | tag_name: ${{ steps.tag.outputs.release_tag }}
158 | body_path: release.txt
159 | files: ${{ env.FIRMWARE }}/*
160 |
--------------------------------------------------------------------------------
/.github/workflows/x86_64Lite.yml:
--------------------------------------------------------------------------------
1 | name: x86_64Lite
2 |
3 | on:
4 | repository_dispatch:
5 | workflow_dispatch:
6 |
7 | env:
8 | OPNAME: 'x86_64Lite'
9 | REPO_URL: https://github.com/coolsnowwolf/lede
10 | REPO_BRANCH: master
11 | FEEDS_CONF: feeds.conf.default
12 | EXTERNAL_FILE: configs/luci/Lite.config
13 | CONFIG_FILE: configs/x86_64.config
14 | SYS_CONF_SH: configure.sh
15 | PACKS: package.sh
16 | EXTEND_DRIVER: false
17 | UPLOAD_BIN_DIR: false
18 | UPLOAD_FIRMWARE: true
19 | UPLOAD_RELEASE: true
20 | TZ: Asia/Shanghai
21 |
22 | jobs:
23 | build:
24 | runs-on: ubuntu-22.04
25 |
26 | steps:
27 | - name: Checkout
28 | uses: actions/checkout@v4
29 |
30 | - name: Initialization environment
31 | env:
32 | DEBIAN_FRONTEND: noninteractive
33 | run: |
34 | sudo rm -rf /etc/apt/sources.list.d/*
35 | sudo -E apt-get -qq update
36 | sudo -E apt-get -qq install $(curl -fsSL https://raw.githubusercontent.com/bigbugcc/openwrts/master/openwrt-env)
37 | sudo -E apt-get -qq autoremove --purge
38 | sudo -E apt-get -qq clean
39 | sudo timedatectl set-timezone "$TZ"
40 | sudo mkdir -p /mnt/workdir
41 | sudo chown $USER:$GROUPS /mnt/workdir
42 |
43 | - name: Clone source code
44 | working-directory: /mnt/workdir
45 | run: |
46 | df -hT $PWD
47 | git clone --depth 1 $REPO_URL -b $REPO_BRANCH openwrt
48 | ln -sf /mnt/workdir/openwrt $GITHUB_WORKSPACE/openwrt
49 |
50 | - name: Cache
51 | uses: stupidloud/cachewrtbuild@main
52 | with:
53 | ccache: 'true'
54 | mixkey: 'x86'
55 | prefix: 'openwrt'
56 |
57 | - name: Load custom feeds
58 | run: |
59 | [ -e $FEEDS_CONF ] && mv $FEEDS_CONF openwrt/feeds.conf.default
60 | chmod +x $SYS_CONF_SH
61 | cd openwrt
62 | $GITHUB_WORKSPACE/$SYS_CONF_SH
63 |
64 | - name: Update feeds
65 | run: cd openwrt && ./scripts/feeds update -a
66 |
67 | - name: Install feeds
68 | run: cd openwrt && ./scripts/feeds install -a
69 |
70 | - name: Load custom configuration
71 | run: |
72 | [ -e files ] && mv files openwrt/files
73 | [ -e $CONFIG_FILE ] && mv $CONFIG_FILE openwrt/.config
74 | chmod +x $PACKS
75 | cd openwrt
76 | $GITHUB_WORKSPACE/$PACKS
77 |
78 | - name: Extend Driver
79 | if: env.EXTEND_DRIVER == 'true'
80 | run: |
81 | cat configs/Driver.config >> openwrt/.config
82 |
83 | - name: Modify configuration
84 | run: |
85 | cat $EXTERNAL_FILE >> openwrt/.config
86 | cd openwrt && make defconfig
87 | sed -i '/CONFIG_DEFAULT_luci/'d .config
88 | cat .config
89 |
90 | - name: Download package
91 | id: package
92 | run: |
93 | cd openwrt
94 | make download -j$(nproc)
95 | find dl -size -1024c -exec ls -l {} \;
96 | find dl -size -1024c -exec rm -f {} \;
97 |
98 | - name: Compile the firmware
99 | id: compile
100 | run: |
101 | cd openwrt
102 | echo -e "$(nproc) thread compile"
103 | make -j$(nproc) V=s || make -j4 V=s
104 | echo "status=success" >> $GITHUB_OUTPUT
105 | grep '^CONFIG_TARGET.*DEVICE.*=y' .config | sed -r 's/.*DEVICE_(.*)=y/\1/' > DEVICE_NAME
106 | [ -s DEVICE_NAME ] && echo "DEVICE_NAME=_$(cat DEVICE_NAME)" >> $GITHUB_ENV
107 | echo "FILE_DATE=_$(date +"%Y%m%d%H%M")" >> $GITHUB_ENV
108 |
109 | - name: Check space usage
110 | if: (!cancelled())
111 | run: df -hT
112 |
113 | - name: Upload bin directory
114 | uses: actions/upload-artifact@main
115 | if: steps.compile.outputs.status == 'success' && env.UPLOAD_BIN_DIR == 'true'
116 | with:
117 | name: OpenWrt_bin${{ env.DEVICE_NAME }}${{ env.FILE_DATE }}
118 | path: openwrt/bin
119 |
120 | - name: Organize files
121 | id: organize
122 | if: steps.compile.outputs.status == 'success' && env.UPLOAD_FIRMWARE == 'true' && !cancelled()
123 | run: |
124 | cd openwrt/bin/targets/*/*
125 | rm -rf packages
126 | echo "FIRMWARE=$PWD" >> $GITHUB_ENV
127 | echo "status=success" >> $GITHUB_OUTPUT
128 |
129 | - name: Upload firmware directory
130 | uses: actions/upload-artifact@main
131 | if: steps.organize.outputs.status == 'success' && !cancelled()
132 | with:
133 | name: OpenWrt_firmware${{ env.DEVICE_NAME }}${{ env.FILE_DATE }}
134 | path: ${{ env.FIRMWARE }}
135 |
136 | - name: Generate release tag
137 | id: tag
138 | if: steps.compile.outputs.status == 'success' && env.UPLOAD_RELEASE == 'true' && !cancelled()
139 | run: |
140 | echo "== Time:$(date +'%Y-%m-%d %H:%M:%S') =="
141 | echo "release_tag=$(date +"%Y.%m.%d-%H%M%S")" >> $GITHUB_OUTPUT
142 | touch release.txt
143 | echo "status=success" >> $GITHUB_OUTPUT
144 |
145 | - name: Generate release body
146 | if: steps.compile.outputs.status == 'success' && !cancelled()
147 | run: |
148 | echo "" >> release.txt
149 |
150 | - name: Upload firmware to release
151 | uses: softprops/action-gh-release@v1
152 | if: steps.tag.outputs.status == 'success' && !cancelled()
153 | env:
154 | GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
155 | with:
156 | name: ${{ env.OPNAME }}
157 | tag_name: ${{ steps.tag.outputs.release_tag }}
158 | body_path: release.txt
159 | files: ${{ env.FIRMWARE }}/*
--------------------------------------------------------------------------------
/LICENSE:
--------------------------------------------------------------------------------
1 | MIT License
2 |
3 | Copyright (c) 2022 bigbugcc
4 |
5 | Permission is hereby granted, free of charge, to any person obtaining a copy
6 | of this software and associated documentation files (the "Software"), to deal
7 | in the Software without restriction, including without limitation the rights
8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9 | copies of the Software, and to permit persons to whom the Software is
10 | furnished to do so, subject to the following conditions:
11 |
12 | The above copyright notice and this permission notice shall be included in all
13 | copies or substantial portions of the Software.
14 |
15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21 | SOFTWARE.
22 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # Action Openwrt 云自动编译
2 | ⏰ **每周自动拉取最新源码自动编译**
3 |
4 | [![Contributors][contributors-shield]][contributors-url]
5 | [![Forks][forks-shield]][forks-url]
6 | [![Stargazers][stars-shield]][stars-url]
7 | [![Issues][issues-shield]][issues-url]
8 | [![MIT License][license-shield]][license-url]
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
18 | 👉 每周定时自动拉取Openwrt最新源码编译,自动发布到 [ Releases ]👈
19 |
20 | 探索本项目的文档 »
21 |
22 |
23 | 下载地址
24 | ·
25 | Action
26 | ·
27 | 提出新特性
28 |