diff --git a/.github/workflows/r2s_lean_minimal-dev.yml b/.github/workflows/r2s_lean_minimal-dev.yml new file mode 100644 index 0000000000..cbf7d6b1c6 --- /dev/null +++ b/.github/workflows/r2s_lean_minimal-dev.yml @@ -0,0 +1,106 @@ +name: r2s Lean版openwrt minimal + +on: + push: + branches: [ master ] + paths: + - '.github/workflows/r2s_lean_minimal-dev.yml' + schedule: + - cron: '10 08 * * *' + +jobs: + + build: + + runs-on: ubuntu-latest + if: github.repository == 'klever1988/nanopi-openwrt' + + steps: + + - name: Checkout + uses: actions/checkout@master + with: + ref: master + + - name: Initialization Environment + env: + DEBIAN_FRONTEND: noninteractive + run: . 1_initialization_environment.sh + + - name: Clone Source + run: . 2_clone_rouce.sh + + - name: Patch Kernel + run: . patch_kernel_5.4-test.sh + + - name: Mods + run: | + cd friendlywrt-rk3328 + . ../remove_unused_config.sh + cat configs/config_rk3328 | grep "TARGET" >> ../base_rk3328.seed + cat ../base_rk3328.seed > configs/config_rk3328 + cat ../minimal_config.seed >> configs/config_rk3328 + cd friendlywrt + git remote add upstream https://github.com/project-openwrt/openwrt && git fetch upstream + git checkout upstream/openwrt-19.07 -b tmp + git mv README.md README + git commit -m 'reset' + git checkout master-v19.07.1 + git rebase adc1a9a3676b8d7be1b48b5aed185a94d8e42728^ --onto tmp -X theirs + rm -f target/linux/rockchip-rk3328/patches-4.14/0001-net-thunderx-workaround-BGX-TX-Underflow-issue.patch + sed -i '/ipv6/,+3d' package/base-files/files/root/setup.sh + git checkout upstream/openwrt-19.07 -- feeds.conf.default + cd package/ctcgfw/ + rm -rf luci-app-oled/ && git clone https://github.com/NateLol/luci-app-oled + cd ../../ + git apply ../../enable_autocore_ctcgfw.diff + #sed -i 's/@LINUX_5_4//' package/lean/luci-app-flowoffload/Makefile + sed -i '/uci commit luci/i\uci set luci.main.mediaurlbase="/luci-static/argon"' package/lean/default-settings/files/zzz-default-settings + sed -i '/exit/i\chown -R root:root /usr/share/netdata/web' package/lean/default-settings/files/zzz-default-settings + sed -i '/exit/i\find /etc/rc.d/ -name *docker* -delete' package/lean/default-settings/files/zzz-default-settings + sed -i 's/option fullcone\t1/option fullcone\t0/' package/network/config/firewall/files/firewall.config + sed -i '/8.8.8.8/d' package/base-files/files/root/setup.sh + mv ../../scripts/check_wan4.sh package/base-files/files/usr/bin && sed -i '/exit/i\/bin/sh /usr/bin/check_wan4.sh &' package/base-files/files/etc/rc.local + mv ../../scripts/autoupdate.sh package/base-files/files/root/au.sh && chmod +x package/base-files/files/root/au.sh + echo -e '\nDYC Build\n' >> package/base-files/files/etc/banner + + - name: Add OpenClash Core + run: | + cd friendlywrt-rk3328/friendlywrt/package/base-files/files + mkdir -p etc/openclash/core && cd etc/openclash/core + curl -L https://github.com/vernesong/OpenClash/releases/download/Clash/clash-linux-armv8.tar.gz | tar zxf - + chmod +x clash + + - name: Build FriendlyWrt + run: | + cd friendlywrt-rk3328 + sed -i 's/set -eu/set -u/' scripts/mk-friendlywrt.sh + ./build.sh nanopi_r2s.mk + cd .. && sudo bash fix_ownership.sh + + - name: Assemble Artifact + id: assemble_artifact + run: | + . x_assemble_artifact.sh + release_tag="R2S-Minimal-$(date +%Y-%m-%d)-dev" + echo "##[set-output name=release_tag;]$release_tag" + - name: Create Release + id: create_release + uses: actions/create-release@v1 + env: + GITHUB_TOKEN: ${{ secrets.sec_token }} + with: + tag_name: ${{ steps.assemble_artifact.outputs.release_tag }} + release_name: 仅测试勿使用 ${{ steps.assemble_artifact.outputs.release_tag }} + draft: false + prerelease: false + - name: Upload Release Asset + id: upload-release-asset + uses: actions/upload-release-asset@v1 + env: + GITHUB_TOKEN: ${{ secrets.sec_token }} + with: + upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps + asset_path: ./artifact.zip + asset_name: ${{ steps.assemble_artifact.outputs.release_tag }}-ROM.zip + asset_content_type: application/zip diff --git a/.github/workflows/r2s_lean_minimal-dev.yml_ b/.github/workflows/r2s_lean_minimal-dev.yml_ deleted file mode 100644 index aa0c7fb0c1..0000000000 --- a/.github/workflows/r2s_lean_minimal-dev.yml_ +++ /dev/null @@ -1,226 +0,0 @@ -name: r2s Lean版openwrt minimal - -on: - push: - branches: [ master ] - paths: - - '.github/workflows/r2s_lean_minimal-dev.yml' - schedule: - - cron: '10 08 * * *' - -jobs: - - build: - - runs-on: ubuntu-latest - if: github.repository == 'klever1988/nanopi-openwrt' - - steps: - - - name: Checkout - uses: actions/checkout@master - with: - ref: master - - - name: Initialization Environment - env: - DEBIAN_FRONTEND: noninteractive - run: | - sudo rm -rf /etc/apt/sources.list.d - sudo apt-get update - sudo apt-get -y --no-install-recommends install build-essential asciidoc binutils bzip2 gawk gettext git libncurses5-dev libz-dev patch python3 unzip zlib1g-dev lib32gcc1 libc6-dev-i386 subversion flex uglifyjs gcc-multilib g++-multilib p7zip p7zip-full msmtp libssl-dev texinfo libglib2.0-dev xmlto qemu-utils upx libelf-dev autoconf automake libtool autopoint device-tree-compiler - curl https://raw.githubusercontent.com/friendlyarm/build-env-on-ubuntu-bionic/master/install.sh | sed '/#/d' | sed 's/\\//g' | sed 's/exit 0//g' | sed 's/sudo apt -y install//g' | sed 's/sudo apt-get -y install//g' | sed 's/:i386//g' | xargs sudo apt-get -y --no-install-recommends install - docker rmi `docker images -q` - sudo rm -rf /usr/share/dotnet /usr/local/lib/android/sdk /usr/local/share/boost /opt/ghc - - - name: Install Repo - run: | - git clone https://github.com/friendlyarm/repo - sudo cp repo/repo /usr/bin/ - - - name: Init Source - run: | - mkdir friendlywrt-rk3328 - cd friendlywrt-rk3328 - repo init -u https://github.com/friendlyarm/friendlywrt_manifests -b master-v19.07.1 -m rk3328.xml --repo-url=https://github.com/friendlyarm/repo --no-clone-bundle --depth=1 - repo sync -c --no-tags --no-clone-bundle -j8 - cd friendlywrt/ && git fetch --unshallow - - - name: Patch Kernel - run: | - . patch_kernel_5.4-test.sh - - - name: Mods - run: | - cd friendlywrt-rk3328 - . ../remove_unused_config.sh - cat configs/config_rk3328 | grep "TARGET" >> ../base_rk3328.seed - cat ../base_rk3328.seed > configs/config_rk3328 - echo ' - CONFIG_PACKAGE_ipv6helper=y - CONFIG_PACKAGE_dnsmasq_full_dhcpv6=y - CONFIG_OPENSSL_ENGINE_BUILTIN=y - CONFIG_OPENSSL_WITH_DTLS=y - CONFIG_OPENSSL_WITH_EC2M=y - CONFIG_OPENSSL_WITH_NPN=y - CONFIG_PACKAGE_autocore=y - CONFIG_PACKAGE_htop=y - CONFIG_PACKAGE_diffutils=y - CONFIG_PACKAGE_vim-fuller=y - CONFIG_PACKAGE_pv=y - CONFIG_PACKAGE_pigz=y - CONFIG_PACKAGE_unzip=y - CONFIG_PACKAGE_losetup=y - CONFIG_PACKAGE_luci-app-frpc=y - CONFIG_PACKAGE_luci-app-netdata=y - CONFIG_LIBSODIUM_MINIMAL=y - CONFIG_PACKAGE_ddns-scripts_aliyun=y - CONFIG_PACKAGE_ddns-scripts_cloudflare.com-v4=y - CONFIG_PACKAGE_luci-app-ssr-plus=y - CONFIG_PACKAGE_luci-app-ssr-plus_INCLUDE_Kcptun=y - CONFIG_PACKAGE_luci-app-ssr-plus_INCLUDE_DNS2SOCKS=y - CONFIG_PACKAGE_luci-app-ssr-plus_INCLUDE_Redsocks2=y - CONFIG_PACKAGE_luci-app-ssr-plus_INCLUDE_Shadowsocks=y - CONFIG_PACKAGE_luci-app-ssr-plus_INCLUDE_Simple_obfs=y - CONFIG_PACKAGE_luci-app-ssr-plus_INCLUDE_Trojan=y - CONFIG_PACKAGE_luci-app-ssr-plus_INCLUDE_V2ray=y - CONFIG_PACKAGE_luci-app-ssr-plus_INCLUDE_V2ray_plugin=y - CONFIG_PACKAGE_luci-app-ssrserver-python=y - CONFIG_PACKAGE_luci-app-uhttpd=y - CONFIG_PACKAGE_luci-app-unblockmusic=y - CONFIG_PACKAGE_luci-app-v2ray-server=y - CONFIG_PACKAGE_luci-app-vssr=y - CONFIG_PACKAGE_luci-theme-argon=y - CONFIG_PACKAGE_luci-theme-material=y - CONFIG_PACKAGE_luci-theme-netgear=y - CONFIG_PACKAGE_luci-app-unblockmusic=y - CONFIG_PACKAGE_kmod-rtl8xxxu=y - CONFIG_UnblockNeteaseMusic_Go=y - CONFIG_UnblockNeteaseMusic_NodeJS=y - CONFIG_PACKAGE_luci-app-passwall=y - CONFIG_PACKAGE_luci-app-passwall_INCLUDE_Brook=y - CONFIG_PACKAGE_luci-app-passwall_INCLUDE_Shadowsocks=y - CONFIG_PACKAGE_luci-app-passwall_INCLUDE_Trojan=y - CONFIG_PACKAGE_luci-app-passwall_INCLUDE_Trojan_GO=y - CONFIG_PACKAGE_luci-app-passwall_INCLUDE_simple-obfs=y - CONFIG_PACKAGE_luci-app-passwall_INCLUDE_v2ray-plugin=y - CONFIG_PACKAGE_luci-app-openclash=y - CONFIG_PACKAGE_luci-app-zerotier=y - # CONFIG_PACKAGE_luci-app-accesscontrol is not set - # CONFIG_PACKAGE_luci-app-nlbwmon is not set - # CONFIG_PACKAGE_nlbwmon is not set - # CONFIG_PACKAGE_luci-app-pppoe-relay is not set - # CONFIG_PACKAGE_luci-app-pppoe-server is not set - # CONFIG_PACKAGE_luci-app-pptp-vpnserver-manyusers is not set - # CONFIG_PACKAGE_luci-app-sqm is not set - # CONFIG_PACKAGE_luci-app-ssr-python-pro-server is not set - # CONFIG_PACKAGE_luci-app-v2ray-server is not set - # CONFIG_PACKAGE_luci-app-vsftpd is not set - # CONFIG_PACKAGE_luci-app-vssr_INCLUDE_ShadowsocksR_Socks is not set - # CONFIG_TARGET_ROOTFS_TARGZ is not set - # CONFIG_OPENSSL_ENGINE_BUILTIN_DEVCRYPTO is not set - # CONFIG_PACKAGE_kmod-crypto-authenc is not set - # CONFIG_PACKAGE_kmod-cryptodev is not set - # CONFIG_PACKAGE_libopenssl-devcrypto is not set - # CONFIG_V2RAY_COMPRESS_UPX is not set - CONFIG_PACKAGE_luci-app-oled=y - CONFIG_PACKAGE_luci-app-flowoffload=y - # CONFIG_PACKAGE_luci-app-sfe is not set - ' >> configs/config_rk3328 - cd friendlywrt - git config --local user.email "action@github.com" && git config --local user.name "GitHub Action" - git remote add upstream https://github.com/coolsnowwolf/lede && git fetch upstream - git checkout upstream/master -b tmp - rm -r target/linux/sunxi/image - git checkout 33f7cb735300bd9a099995236ed768c8925fec75 -- target/linux/sunxi/image/ - git rm README.md - git commit -m 'reset' - git checkout master-v19.07.1 - git rebase adc1a9a3676b8d7be1b48b5aed185a94d8e42728^ --onto tmp -X theirs - rm -f target/linux/rockchip-rk3328/patches-4.14/0001-net-thunderx-workaround-BGX-TX-Underflow-issue.patch target/linux/generic/hack-4.14/999-net-patch-linux-kernel-to-support-shortcut-fe.patch - sed -i '/ipv6/,+3d' package/base-files/files/root/setup.sh - git checkout upstream/master -- feeds.conf.default - sed -i -E 's/#(src-git.+)(helloworld.+)/\1\2/' feeds.conf.default - cd package/lean/ - git clone https://github.com/NateLol/luci-app-oled - rm -rf luci-theme-argon - git clone -b 18.06 https://github.com/jerrykuku/luci-theme-argon.git - cd ../../ - git apply ../../enable_autocore.diff - sed -i 's/@LINUX_5_4//' package/lean/luci-app-flowoffload/Makefile - sed -i '/uci commit luci/i\uci set luci.main.mediaurlbase="/luci-static/argon"' package/lean/default-settings/files/zzz-default-settings - sed -i '/exit/i\chown -R root:root /usr/share/netdata/web' package/lean/default-settings/files/zzz-default-settings - sed -i '/exit/i\find /etc/rc.d/ -name *docker* -delete' package/lean/default-settings/files/zzz-default-settings - sed -i 's/option fullcone\t1/option fullcone\t0/' package/network/config/firewall/files/firewall.config - sed -i '/8.8.8.8/d' package/base-files/files/root/setup.sh - mv ../../scripts/check_wan4.sh package/base-files/files/usr/bin && sed -i '/exit/i\/bin/sh /usr/bin/check_wan4.sh &' package/base-files/files/etc/rc.local - mv ../../scripts/autoupdate.sh package/base-files/files/root/au.sh && chmod +x package/base-files/files/root/au.sh - echo -e '\nDYC Build\n' >> package/base-files/files/etc/banner - - - name: Add OpenClash - run: | - git clone -b master https://github.com/vernesong/OpenClash.git - mv OpenClash/luci-app-openclash friendlywrt-rk3328/friendlywrt/package - cd friendlywrt-rk3328/friendlywrt/package/base-files/files - mkdir -p etc/openclash/core && cd etc/openclash/core - curl -L https://github.com/vernesong/OpenClash/releases/download/Clash/clash-linux-armv8.tar.gz | tar zxf - - chmod +x clash - - - name: Add Passwall - run: | - cd friendlywrt-rk3328/friendlywrt - echo -e '\nsrc-git lienol https://github.com/Lienol/openwrt-package' >> feeds.conf.default - ./scripts/feeds update -a - rm -rf feeds/lienol/lienol/ipt2socks - rm -rf feeds/lienol/lienol/shadowsocksr-libev - rm -rf feeds/lienol/lienol/pdnsd-alt - rm -rf feeds/lienol/package/verysync - rm -rf feeds/lienol/lienol/luci-app-verysync - rm -rf package/lean/luci-app-kodexplorer - rm -rf package/lean/luci-app-pppoe-relay - rm -rf package/lean/luci-app-pptp-server - rm -rf package/lean/luci-app-v2ray-server - ./scripts/feeds install -a - - - name: Build FriendlyWrt - run: | - cd friendlywrt-rk3328 - sed -i 's/set -eu/set -u/' scripts/mk-friendlywrt.sh - ./build.sh nanopi_r2s.mk - - - name: Zip Files - run: | - gzip friendlywrt-rk3328/out/*.img - - name: Assemble Artifact - id: assemble_artifact - run: | - rm -rf ./artifact/ - mkdir -p ./artifact/ - mv friendlywrt-rk3328/out/*img* ./artifact/ - cp friendlywrt-rk3328/friendlywrt/.config ./artifact/ - cd ./artifact/ - md5sum *img* > md5sum.txt - cd .. - zip -r artifact.zip ./artifact/ - release_tag="R2S-Minimal-$(date +%Y-%m-%d)-dev" - echo "##[set-output name=release_tag;]$release_tag" - - name: Create Release - id: create_release - uses: actions/create-release@v1 - env: - GITHUB_TOKEN: ${{ secrets.sec_token }} - with: - tag_name: ${{ steps.assemble_artifact.outputs.release_tag }} - release_name: 仅测试勿使用 ${{ steps.assemble_artifact.outputs.release_tag }} - draft: false - prerelease: false - - name: Upload Release Asset - id: upload-release-asset - uses: actions/upload-release-asset@v1 - env: - GITHUB_TOKEN: ${{ secrets.sec_token }} - with: - upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps - asset_path: ./artifact.zip - asset_name: ${{ steps.assemble_artifact.outputs.release_tag }}-ROM.zip - asset_content_type: application/zip diff --git a/.github/workflows/r2s_lean_minimal-test.yml b/.github/workflows/r2s_lean_minimal-test.yml_ similarity index 56% rename from .github/workflows/r2s_lean_minimal-test.yml rename to .github/workflows/r2s_lean_minimal-test.yml_ index a9242fec8a..f2a25533e6 100644 --- a/.github/workflows/r2s_lean_minimal-test.yml +++ b/.github/workflows/r2s_lean_minimal-test.yml_ @@ -26,30 +26,13 @@ jobs: - name: Initialization Environment env: DEBIAN_FRONTEND: noninteractive - run: | - sudo rm -rf /etc/apt/sources.list.d - sudo apt-get update - sudo apt-get -y --no-install-recommends install build-essential asciidoc binutils bzip2 gawk gettext git libncurses5-dev libz-dev patch python3 unzip zlib1g-dev lib32gcc1 libc6-dev-i386 subversion flex uglifyjs gcc-multilib g++-multilib p7zip p7zip-full msmtp libssl-dev texinfo libglib2.0-dev xmlto qemu-utils upx libelf-dev autoconf automake libtool autopoint device-tree-compiler - curl https://raw.githubusercontent.com/friendlyarm/build-env-on-ubuntu-bionic/master/install.sh | sed '/#/d' | sed 's/\\//g' | sed 's/exit 0//g' | sed 's/sudo apt -y install//g' | sed 's/sudo apt-get -y install//g' | sed 's/:i386//g' | xargs sudo apt-get -y --no-install-recommends install - docker rmi `docker images -q` - sudo rm -rf /usr/share/dotnet /usr/local/lib/android/sdk /usr/local/share/boost /opt/ghc - - - name: Install Repo - run: | - git clone https://github.com/friendlyarm/repo - sudo cp repo/repo /usr/bin/ + run: . 1_initialization_environment.sh - - name: Init Source - run: | - mkdir friendlywrt-rk3328 - cd friendlywrt-rk3328 - repo init -u https://github.com/friendlyarm/friendlywrt_manifests -b master-v19.07.1 -m rk3328.xml --repo-url=https://github.com/friendlyarm/repo --no-clone-bundle --depth=1 - repo sync -c --no-tags --no-clone-bundle -j8 - cd friendlywrt/ && git fetch --unshallow + - name: Clone Source + run: . 2_clone_rouce.sh - name: Patch Kernel - run: | - . patch_kernel_5.4-test.sh + run: . patch_kernel_5.4-test.sh - name: Mods run: | @@ -57,77 +40,7 @@ jobs: . ../remove_unused_config.sh cat configs/config_rk3328 | grep "TARGET" >> ../base_rk3328.seed cat ../base_rk3328.seed > configs/config_rk3328 - echo ' - CONFIG_PACKAGE_ipv6helper=y - CONFIG_PACKAGE_dnsmasq_full_dhcpv6=y - CONFIG_OPENSSL_ENGINE_BUILTIN=y - CONFIG_OPENSSL_WITH_DTLS=y - CONFIG_OPENSSL_WITH_EC2M=y - CONFIG_OPENSSL_WITH_NPN=y - CONFIG_PACKAGE_autocore=y - CONFIG_PACKAGE_htop=y - CONFIG_PACKAGE_diffutils=y - CONFIG_PACKAGE_vim-fuller=y - CONFIG_PACKAGE_pv=y - CONFIG_PACKAGE_pigz=y - CONFIG_PACKAGE_unzip=y - CONFIG_PACKAGE_losetup=y - CONFIG_PACKAGE_luci-app-frpc=y - CONFIG_PACKAGE_luci-app-netdata=y - CONFIG_LIBSODIUM_MINIMAL=y - CONFIG_PACKAGE_ddns-scripts_aliyun=y - CONFIG_PACKAGE_ddns-scripts_cloudflare.com-v4=y - CONFIG_PACKAGE_luci-app-ssr-plus=y - CONFIG_PACKAGE_luci-app-ssr-plus_INCLUDE_Kcptun=y - CONFIG_PACKAGE_luci-app-ssr-plus_INCLUDE_DNS2SOCKS=y - CONFIG_PACKAGE_luci-app-ssr-plus_INCLUDE_Redsocks2=y - CONFIG_PACKAGE_luci-app-ssr-plus_INCLUDE_Shadowsocks=y - CONFIG_PACKAGE_luci-app-ssr-plus_INCLUDE_Simple_obfs=y - CONFIG_PACKAGE_luci-app-ssr-plus_INCLUDE_Trojan=y - CONFIG_PACKAGE_luci-app-ssr-plus_INCLUDE_V2ray=y - CONFIG_PACKAGE_luci-app-ssr-plus_INCLUDE_V2ray_plugin=y - CONFIG_PACKAGE_luci-app-ssrserver-python=y - CONFIG_PACKAGE_luci-app-uhttpd=y - CONFIG_PACKAGE_luci-app-unblockmusic=y - CONFIG_PACKAGE_luci-app-v2ray-server=y - CONFIG_PACKAGE_luci-app-vssr=y - CONFIG_PACKAGE_luci-theme-argon=y - CONFIG_PACKAGE_luci-theme-material=y - CONFIG_PACKAGE_luci-theme-netgear=y - CONFIG_PACKAGE_luci-app-unblockmusic=y - CONFIG_PACKAGE_kmod-rtl8xxxu=y - CONFIG_UnblockNeteaseMusic_Go=y - CONFIG_UnblockNeteaseMusic_NodeJS=y - CONFIG_PACKAGE_luci-app-passwall=y - CONFIG_PACKAGE_luci-app-passwall_INCLUDE_Brook=y - CONFIG_PACKAGE_luci-app-passwall_INCLUDE_Shadowsocks=y - CONFIG_PACKAGE_luci-app-passwall_INCLUDE_Trojan=y - CONFIG_PACKAGE_luci-app-passwall_INCLUDE_Trojan_GO=y - CONFIG_PACKAGE_luci-app-passwall_INCLUDE_simple-obfs=y - CONFIG_PACKAGE_luci-app-passwall_INCLUDE_v2ray-plugin=y - CONFIG_PACKAGE_luci-app-openclash=y - CONFIG_PACKAGE_luci-app-zerotier=y - # CONFIG_PACKAGE_luci-app-accesscontrol is not set - # CONFIG_PACKAGE_luci-app-nlbwmon is not set - # CONFIG_PACKAGE_nlbwmon is not set - # CONFIG_PACKAGE_luci-app-pppoe-relay is not set - # CONFIG_PACKAGE_luci-app-pppoe-server is not set - # CONFIG_PACKAGE_luci-app-pptp-vpnserver-manyusers is not set - # CONFIG_PACKAGE_luci-app-sqm is not set - # CONFIG_PACKAGE_luci-app-ssr-python-pro-server is not set - # CONFIG_PACKAGE_luci-app-v2ray-server is not set - # CONFIG_PACKAGE_luci-app-vsftpd is not set - # CONFIG_PACKAGE_luci-app-vssr_INCLUDE_ShadowsocksR_Socks is not set - # CONFIG_TARGET_ROOTFS_TARGZ is not set - # CONFIG_OPENSSL_ENGINE_BUILTIN_DEVCRYPTO is not set - # CONFIG_PACKAGE_kmod-crypto-authenc is not set - # CONFIG_PACKAGE_kmod-cryptodev is not set - # CONFIG_PACKAGE_libopenssl-devcrypto is not set - # CONFIG_V2RAY_COMPRESS_UPX is not set - CONFIG_PACKAGE_luci-app-oled=y - CONFIG_PACKAGE_luci-app-flowoffload=y - # CONFIG_PACKAGE_luci-app-sfe is not set - ' >> configs/config_rk3328 + cat minimal_config.seed >> configs/config_rk3328 cd friendlywrt git config --local user.email "action@github.com" && git config --local user.name "GitHub Action" git remote add upstream https://github.com/coolsnowwolf/openwrt && git fetch upstream @@ -224,7 +137,7 @@ jobs: GITHUB_TOKEN: ${{ secrets.sec_token }} with: tag_name: ${{ steps.assemble_artifact.outputs.release_tag }} - release_name: 自动发布 ${{ steps.assemble_artifact.outputs.release_tag }} + release_name: 仅测试勿使用 ${{ steps.assemble_artifact.outputs.release_tag }} draft: false prerelease: false - name: Upload Release Asset diff --git a/.github/workflows/r2s_lean_minimal.yml b/.github/workflows/r2s_lean_minimal.yml index db07f4e989..9d68395913 100644 --- a/.github/workflows/r2s_lean_minimal.yml +++ b/.github/workflows/r2s_lean_minimal.yml @@ -26,30 +26,13 @@ jobs: - name: Initialization Environment env: DEBIAN_FRONTEND: noninteractive - run: | - sudo rm -rf /etc/apt/sources.list.d - sudo apt-get update - sudo apt-get -y --no-install-recommends install build-essential asciidoc binutils bzip2 gawk gettext git libncurses5-dev libz-dev patch python3 unzip zlib1g-dev lib32gcc1 libc6-dev-i386 subversion flex uglifyjs gcc-multilib g++-multilib p7zip p7zip-full msmtp libssl-dev texinfo libglib2.0-dev xmlto qemu-utils upx libelf-dev autoconf automake libtool autopoint device-tree-compiler - curl https://raw.githubusercontent.com/friendlyarm/build-env-on-ubuntu-bionic/master/install.sh | sed '/#/d' | sed 's/\\//g' | sed 's/exit 0//g' | sed 's/sudo apt -y install//g' | sed 's/sudo apt-get -y install//g' | sed 's/:i386//g' | xargs sudo apt-get -y --no-install-recommends install - docker rmi `docker images -q` - sudo rm -rf /usr/share/dotnet /usr/local/lib/android/sdk /usr/local/share/boost /opt/ghc - - - name: Install Repo - run: | - git clone https://github.com/friendlyarm/repo - sudo cp repo/repo /usr/bin/ + run: . 1_initialization_environment.sh - - name: Init Source - run: | - mkdir friendlywrt-rk3328 - cd friendlywrt-rk3328 - repo init -u https://github.com/friendlyarm/friendlywrt_manifests -b master-v19.07.1 -m rk3328.xml --repo-url=https://github.com/friendlyarm/repo --no-clone-bundle --depth=1 - repo sync -c --no-tags --no-clone-bundle -j8 - cd friendlywrt/ && git fetch --unshallow + - name: Clone Source + run: . 2_clone_rouce.sh - name: Patch Kernel - run: | - . patch_kernel_5.4.sh + run: . patch_kernel_5.4.sh - name: Mods run: | @@ -57,92 +40,14 @@ jobs: . ../remove_unused_config.sh cat configs/config_rk3328 | grep "TARGET" >> ../base_rk3328.seed cat ../base_rk3328.seed > configs/config_rk3328 - echo ' - CONFIG_PACKAGE_ipv6helper=y - CONFIG_PACKAGE_dnsmasq_full_dhcpv6=y - CONFIG_OPENSSL_ENGINE_BUILTIN=y - CONFIG_OPENSSL_WITH_DTLS=y - CONFIG_OPENSSL_WITH_EC2M=y - CONFIG_OPENSSL_WITH_NPN=y - CONFIG_PACKAGE_autocore=y - CONFIG_PACKAGE_htop=y - CONFIG_PACKAGE_diffutils=y - CONFIG_PACKAGE_vim-fuller=y - CONFIG_PACKAGE_pv=y - CONFIG_PACKAGE_pigz=y - CONFIG_PACKAGE_unzip=y - CONFIG_PACKAGE_losetup=y - CONFIG_PACKAGE_luci-app-frpc=y - CONFIG_PACKAGE_luci-app-netdata=y - CONFIG_LIBSODIUM_MINIMAL=y - CONFIG_PACKAGE_ddns-scripts_aliyun=y - CONFIG_PACKAGE_ddns-scripts_cloudflare.com-v4=y - CONFIG_PACKAGE_luci-app-ssr-plus=y - CONFIG_PACKAGE_luci-app-ssr-plus_INCLUDE_Kcptun=y - CONFIG_PACKAGE_luci-app-ssr-plus_INCLUDE_DNS2SOCKS=y - CONFIG_PACKAGE_luci-app-ssr-plus_INCLUDE_Redsocks2=y - CONFIG_PACKAGE_luci-app-ssr-plus_INCLUDE_Shadowsocks=y - CONFIG_PACKAGE_luci-app-ssr-plus_INCLUDE_Simple_obfs=y - CONFIG_PACKAGE_luci-app-ssr-plus_INCLUDE_Trojan=y - CONFIG_PACKAGE_luci-app-ssr-plus_INCLUDE_V2ray=y - CONFIG_PACKAGE_luci-app-ssr-plus_INCLUDE_V2ray_plugin=y - CONFIG_PACKAGE_luci-app-uhttpd=y - CONFIG_PACKAGE_luci-app-unblockmusic=y - CONFIG_PACKAGE_luci-app-v2ray-server=y - CONFIG_PACKAGE_luci-app-vssr=y - CONFIG_PACKAGE_luci-theme-argon=y - CONFIG_PACKAGE_luci-theme-material=y - CONFIG_PACKAGE_luci-theme-netgear=y - CONFIG_PACKAGE_luci-app-unblockmusic=y - CONFIG_PACKAGE_kmod-rtl8xxxu=y - CONFIG_UnblockNeteaseMusic_Go=y - CONFIG_UnblockNeteaseMusic_NodeJS=y - CONFIG_PACKAGE_luci-app-passwall=y - CONFIG_PACKAGE_luci-app-passwall_INCLUDE_Brook=y - CONFIG_PACKAGE_luci-app-ssr-plus_INCLUDE_ShadowsocksR_Server=y - CONFIG_PACKAGE_luci-app-passwall_INCLUDE_Trojan=y - CONFIG_PACKAGE_luci-app-passwall_INCLUDE_Trojan_GO=y - CONFIG_PACKAGE_luci-app-passwall_INCLUDE_simple-obfs=y - CONFIG_PACKAGE_luci-app-passwall_INCLUDE_v2ray-plugin=y - CONFIG_PACKAGE_luci-app-passwall_INCLUDE_https_dns_proxy=n - CONFIG_PACKAGE_luci-app-openclash=y - CONFIG_PACKAGE_luci-app-zerotier=y - # CONFIG_PACKAGE_luci-app-accesscontrol is not set - # CONFIG_PACKAGE_luci-app-nlbwmon is not set - # CONFIG_PACKAGE_nlbwmon is not set - # CONFIG_PACKAGE_luci-app-pppoe-relay is not set - # CONFIG_PACKAGE_luci-app-pppoe-server is not set - # CONFIG_PACKAGE_luci-app-pptp-vpnserver-manyusers is not set - # CONFIG_PACKAGE_luci-app-sqm is not set - # CONFIG_PACKAGE_luci-app-ssr-python-pro-server is not set - # CONFIG_PACKAGE_luci-app-v2ray-server is not set - # CONFIG_PACKAGE_luci-app-vsftpd is not set - # CONFIG_PACKAGE_luci-app-vssr_INCLUDE_ShadowsocksR_Socks is not set - # CONFIG_TARGET_ROOTFS_TARGZ is not set - # CONFIG_OPENSSL_ENGINE_BUILTIN_DEVCRYPTO is not set - # CONFIG_PACKAGE_kmod-crypto-authenc is not set - # CONFIG_PACKAGE_kmod-cryptodev is not set - # CONFIG_PACKAGE_libopenssl-devcrypto is not set - # CONFIG_V2RAY_COMPRESS_UPX is not set - CONFIG_PACKAGE_luci-app-oled=y - CONFIG_PACKAGE_luci-app-adguardhome=y - CONFIG_PACKAGE_luci-app-flowoffload=y - # CONFIG_PACKAGE_luci-app-sfe is not set - CONFIG_DROPBEAR_ECC=y - CONFIG_DROPBEAR_ECC_FULL=y - ' >> configs/config_rk3328 + cat ../minimal_config.seed >> configs/config_rk3328 cd friendlywrt - git config --local user.email "action@github.com" && git config --local user.name "GitHub Action" git remote add upstream https://github.com/coolsnowwolf/openwrt && git fetch upstream git checkout upstream/lede-17.01 -b tmp - #git checkout 33f7cb735300bd9a099995236ed768c8925fec75 -- target/linux/sunxi/image/ - git rm README.md + git mv README.md README git commit -m 'reset' - git checkout origin/master-v19.07.1 + git checkout master-v19.07.1 git rebase adc1a9a3676b8d7be1b48b5aed185a94d8e42728^ --onto tmp -X theirs - #git revert 33abeff31cfb2ae58adf167c82bd36b5f56a5b1c -X ours || true - #rm -rf package/kernel/mt76/Makefile package/network/services/hostapd package/kernel/mac80211 - #git checkout 0a395d6fd6c38c554709197ae3cd6315f143cd7a -- package/kernel/mt76/Makefile package/network/services/hostapd package/kernel/mac80211 rm -f target/linux/rockchip-rk3328/patches-4.14/0001-net-thunderx-workaround-BGX-TX-Underflow-issue.patch target/linux/generic/hack-4.14/999-net-patch-linux-kernel-to-support-shortcut-fe.patch sed -i '/ipv6/,+3d' package/base-files/files/root/setup.sh git checkout upstream/lede-17.01 -- feeds.conf.default @@ -150,21 +55,10 @@ jobs: cd package/lean/ git clone https://github.com/NateLol/luci-app-oled git clone https://github.com/rufengsuixing/luci-app-adguardhome - #git clone https://github.com/jerrykuku/lua-maxminddb.git - #git clone https://github.com/jerrykuku/luci-app-vssr.git - #cd luci-app-vssr/root/etc/ - #echo 'china_ssr.txt - #config/black.list - #config/white.list - #dnsmasq.oversea/oversea_list.conf - #dnsmasq.ssr/ad.conf - #dnsmasq.ssr/gfw_base.conf' | xargs rm - #cd ../../../ rm -rf luci-theme-argon git clone -b 18.06 https://github.com/jerrykuku/luci-theme-argon.git cd ../../ git apply ../../enable_autocore.diff - #git apply ../../fix_cpufreq.diff sed -i 's/@LINUX_5_4//' package/lean/luci-app-flowoffload/Makefile sed -i '/uci commit luci/i\uci set luci.main.mediaurlbase="/luci-static/argon"' package/lean/default-settings/files/zzz-default-settings sed -i '/exit/i\chown -R root:root /usr/share/netdata/web' package/lean/default-settings/files/zzz-default-settings @@ -176,29 +70,10 @@ jobs: echo -e '\nDYC Build\n' >> package/base-files/files/etc/banner - name: Add OpenClash - run: | - git clone -b master https://github.com/vernesong/OpenClash.git - mv OpenClash/luci-app-openclash friendlywrt-rk3328/friendlywrt/package - cd friendlywrt-rk3328/friendlywrt/package/base-files/files - mkdir -p etc/openclash/core && cd etc/openclash/core - curl -L https://github.com/vernesong/OpenClash/releases/download/Clash/clash-linux-armv8.tar.gz | tar zxf - - chmod +x clash + run: . add_openclash.sh - name: Add Passwall - run: | - cd friendlywrt-rk3328/friendlywrt - echo -e '\nsrc-git lienol https://github.com/Lienol/openwrt-package' >> feeds.conf.default - ./scripts/feeds update -a - rm -rf feeds/lienol/lienol/ipt2socks - rm -rf feeds/lienol/lienol/shadowsocksr-libev - rm -rf feeds/lienol/lienol/pdnsd-alt - rm -rf feeds/lienol/package/verysync - rm -rf feeds/lienol/lienol/luci-app-verysync - rm -rf package/lean/luci-app-kodexplorer - rm -rf package/lean/luci-app-pppoe-relay - rm -rf package/lean/luci-app-pptp-server - rm -rf package/lean/luci-app-v2ray-server - ./scripts/feeds install -a + run: . add_passwall.sh - name: Build FriendlyWrt run: | @@ -207,20 +82,10 @@ jobs: ./build.sh nanopi_r2s.mk cd .. && sudo bash fix_ownership.sh - - name: Zip Files - run: | - gzip friendlywrt-rk3328/out/*.img - name: Assemble Artifact id: assemble_artifact run: | - rm -rf ./artifact/ - mkdir -p ./artifact/ - mv friendlywrt-rk3328/out/*img* ./artifact/ - cp friendlywrt-rk3328/friendlywrt/.config ./artifact/ - cd ./artifact/ - md5sum *img* > md5sum.txt - cd .. - zip -r artifact.zip ./artifact/ + . x_assemble_artifact.sh release_tag="R2S-Minimal-$(date +%Y-%m-%d)" echo "##[set-output name=release_tag;]$release_tag" - name: Create Release diff --git a/1_initialization_environment.sh b/1_initialization_environment.sh new file mode 100644 index 0000000000..1a2b589d62 --- /dev/null +++ b/1_initialization_environment.sh @@ -0,0 +1,7 @@ +git config --global user.email "action@github.com" && git config --global user.name "GitHub Action" +sudo rm -rf /etc/apt/sources.list.d +sudo apt-get update +sudo apt-get -y --no-install-recommends install build-essential asciidoc binutils bzip2 gawk gettext git libncurses5-dev libz-dev patch python3 unzip zlib1g-dev lib32gcc1 libc6-dev-i386 subversion flex uglifyjs gcc-multilib g++-multilib p7zip p7zip-full msmtp libssl-dev texinfo libglib2.0-dev xmlto qemu-utils upx libelf-dev autoconf automake libtool autopoint device-tree-compiler +curl https://raw.githubusercontent.com/friendlyarm/build-env-on-ubuntu-bionic/master/install.sh | sed '/#/d' | sed 's/\\//g' | sed 's/exit 0//g' | sed 's/sudo apt -y install//g' | sed 's/sudo apt-get -y install//g' | sed 's/:i386//g' | xargs sudo apt-get -y --no-install-recommends install +docker rmi `docker images -q` +sudo rm -rf /usr/share/dotnet /usr/local/lib/android/sdk /usr/local/share/boost /opt/ghc diff --git a/2_clone_rouce.sh b/2_clone_rouce.sh new file mode 100644 index 0000000000..397aa5066c --- /dev/null +++ b/2_clone_rouce.sh @@ -0,0 +1,8 @@ +git clone https://github.com/friendlyarm/repo +sudo cp repo/repo /usr/bin/ +mkdir friendlywrt-rk3328 +cd friendlywrt-rk3328 +repo init -u https://github.com/friendlyarm/friendlywrt_manifests -b master-v19.07.1 -m rk3328.xml --repo-url=https://github.com/friendlyarm/repo --no-clone-bundle --depth=1 +repo sync -c --no-tags --no-clone-bundle -j8 +cd friendlywrt/ && git fetch --unshallow +git checkout `git branch -va | grep remotes/m | awk '{print $3}' | awk -F\/ '{print $2}'` diff --git a/add_openclash.sh b/add_openclash.sh new file mode 100644 index 0000000000..f5729fa292 --- /dev/null +++ b/add_openclash.sh @@ -0,0 +1,6 @@ +git clone -b master https://github.com/vernesong/OpenClash.git +mv OpenClash/luci-app-openclash friendlywrt-rk3328/friendlywrt/package +cd friendlywrt-rk3328/friendlywrt/package/base-files/files +mkdir -p etc/openclash/core && cd etc/openclash/core +curl -L https://github.com/vernesong/OpenClash/releases/download/Clash/clash-linux-armv8.tar.gz | tar zxf - +chmod +x clash diff --git a/add_passwall.sh b/add_passwall.sh new file mode 100644 index 0000000000..a36ad55521 --- /dev/null +++ b/add_passwall.sh @@ -0,0 +1,13 @@ +cd friendlywrt-rk3328/friendlywrt +echo -e '\nsrc-git lienol https://github.com/xiaorouji/openwrt-package' >> feeds.conf.default +./scripts/feeds update -a +rm -rf feeds/lienol/lienol/ipt2socks +rm -rf feeds/lienol/lienol/shadowsocksr-libev +rm -rf feeds/lienol/lienol/pdnsd-alt +rm -rf feeds/lienol/package/verysync +rm -rf feeds/lienol/lienol/luci-app-verysync +rm -rf package/lean/luci-app-kodexplorer +rm -rf package/lean/luci-app-pppoe-relay +rm -rf package/lean/luci-app-pptp-server +rm -rf package/lean/luci-app-v2ray-server +./scripts/feeds install -a diff --git a/enable_autocore_ctcgfw.diff b/enable_autocore_ctcgfw.diff new file mode 100644 index 0000000000..ab5856a67f --- /dev/null +++ b/enable_autocore_ctcgfw.diff @@ -0,0 +1,60 @@ +diff --git a/package/lean/autocore/Makefile b/package/lean/autocore/Makefile +index 22b986d58c..945f9a2784 100644 +--- a/package/lean/autocore/Makefile ++++ b/package/lean/autocore/Makefile +@@ -17,7 +17,7 @@ include $(INCLUDE_DIR)/package.mk + define Package/autocore + TITLE:=x86/x64 auto core loadbalance script. + MAINTAINER:=Lean +- DEPENDS:=@TARGET_x86 +bc +lm-sensors +ethtool ++ DEPENDS:=+bc +lm-sensors +ethtool + endef + + define Package/autocore/description +diff --git a/package/lean/autocore/files/autocore b/package/lean/autocore/files/autocore +index 436e92940a..16262fb1c6 100755 +--- a/package/lean/autocore/files/autocore ++++ b/package/lean/autocore/files/autocore +@@ -33,7 +33,7 @@ start() + g=${a}${b}${c}${d}${e}${f} + + mkdir -p /tmp/sysinfo +- echo $g > /tmp/sysinfo/model ++ #echo $g > /tmp/sysinfo/model + + a=$(ip address | grep ^[0-9] | awk -F: '{print $2}' | sed "s/ //g" | grep '^[e]' | grep -v "@" | grep -v "\.") + b=$(echo "$a" | wc -l) +@@ -44,7 +44,7 @@ start() + ethtool -K $c tx-checksum-ip-generic on >/dev/null 2>&1 || ( + ethtool -K $c tx-checksum-ipv4 on >/dev/null 2>&1 + ethtool -K $c tx-checksum-ipv6 on >/dev/null 2>&1) +- ethtool -K $c tx-scatter-gather on >/dev/null 2>&1 ++ #ethtool -K $c tx-scatter-gather on >/dev/null 2>&1 + ethtool -K $c gso on >/dev/null 2>&1 + ethtool -K $c tso on >/dev/null 2>&1 + ethtool -K $c ufo on >/dev/null 2>&1 +diff --git a/package/lean/autocore/files/cpuinfo b/package/lean/autocore/files/cpuinfo +index 8c0527f84f..6adabeafc7 100755 +--- a/package/lean/autocore/files/cpuinfo ++++ b/package/lean/autocore/files/cpuinfo +@@ -1,5 +1,5 @@ + #!/bin/sh + +-MHz=`grep 'MHz' /proc/cpuinfo | cut -c11- |sed -n '1p'` +-TEMP=`sensors 2>/dev/null | grep 'Core 0' | cut -c12-` ++MHz=`echo "$(cat /sys/devices/system/cpu/cpu[04]/cpufreq/cpuinfo_cur_freq)/1000" | bc` ++TEMP=`echo "scale=2; $(cat /sys/class/thermal/thermal_zone0/temp)/1000" | bc`° + echo "$MHz MHz $TEMP " +diff --git a/package/lean/autocore/files/rpcd_10_system.js b/package/lean/autocore/files/rpcd_10_system.js +index 73638a0b6b..dda369ba5c 100644 +--- a/package/lean/autocore/files/rpcd_10_system.js ++++ b/package/lean/autocore/files/rpcd_10_system.js +@@ -76,7 +76,7 @@ return L.Class.extend({ + _('Hostname'), boardinfo.hostname, + _('Model'), boardinfo.model + cpubench.cpubench, + _('CPU Info'), cpuinfo.cpuinfo, +- _('Firmware Version'), (L.isObject(boardinfo.release) ? boardinfo.release.description : '')/* + ' / ' : '') + (luciversion || '')*/, ++ _('Firmware Version'), (L.isObject(boardinfo.release) ? boardinfo.release.description : '') + ' built by DYC'/* + ' / ' : '') + (luciversion || '')*/, + _('Kernel Version'), boardinfo.kernel, + _('Local Time'), datestr, + _('Uptime'), systeminfo.uptime ? '%t'.format(systeminfo.uptime) : null, diff --git a/minimal_config.seed b/minimal_config.seed new file mode 100644 index 0000000000..3b5ae69fa1 --- /dev/null +++ b/minimal_config.seed @@ -0,0 +1,72 @@ +CONFIG_PACKAGE_ipv6helper=y +CONFIG_PACKAGE_dnsmasq_full_dhcpv6=y +CONFIG_OPENSSL_ENGINE_BUILTIN=y +CONFIG_OPENSSL_WITH_DTLS=y +CONFIG_OPENSSL_WITH_EC2M=y +CONFIG_OPENSSL_WITH_NPN=y +CONFIG_PACKAGE_autocore=y +CONFIG_PACKAGE_htop=y +CONFIG_PACKAGE_diffutils=y +CONFIG_PACKAGE_vim-fuller=y +CONFIG_PACKAGE_pv=y +CONFIG_PACKAGE_pigz=y +CONFIG_PACKAGE_unzip=y +CONFIG_PACKAGE_losetup=y +CONFIG_PACKAGE_luci-app-frpc=y +CONFIG_PACKAGE_luci-app-netdata=y +CONFIG_LIBSODIUM_MINIMAL=y +CONFIG_PACKAGE_ddns-scripts_aliyun=y +CONFIG_PACKAGE_ddns-scripts_cloudflare.com-v4=y +CONFIG_PACKAGE_luci-app-ssr-plus=y +CONFIG_PACKAGE_luci-app-ssr-plus_INCLUDE_Kcptun=y +CONFIG_PACKAGE_luci-app-ssr-plus_INCLUDE_DNS2SOCKS=y +CONFIG_PACKAGE_luci-app-ssr-plus_INCLUDE_Redsocks2=y +CONFIG_PACKAGE_luci-app-ssr-plus_INCLUDE_Shadowsocks=y +CONFIG_PACKAGE_luci-app-ssr-plus_INCLUDE_Simple_obfs=y +CONFIG_PACKAGE_luci-app-ssr-plus_INCLUDE_Trojan=y +CONFIG_PACKAGE_luci-app-ssr-plus_INCLUDE_V2ray=y +CONFIG_PACKAGE_luci-app-ssr-plus_INCLUDE_V2ray_plugin=y +CONFIG_PACKAGE_luci-app-uhttpd=y +CONFIG_PACKAGE_luci-app-unblockmusic=y +CONFIG_PACKAGE_luci-app-v2ray-server=y +CONFIG_PACKAGE_luci-app-vssr=y +CONFIG_PACKAGE_luci-theme-argon=y +CONFIG_PACKAGE_luci-theme-material=y +CONFIG_PACKAGE_luci-theme-netgear=y +CONFIG_PACKAGE_luci-app-unblockmusic=y +CONFIG_PACKAGE_kmod-rtl8xxxu=y +CONFIG_UnblockNeteaseMusic_Go=y +CONFIG_UnblockNeteaseMusic_NodeJS=y +CONFIG_PACKAGE_luci-app-passwall=y +CONFIG_PACKAGE_luci-app-passwall_INCLUDE_Brook=y +CONFIG_PACKAGE_luci-app-ssr-plus_INCLUDE_ShadowsocksR_Server=y +CONFIG_PACKAGE_luci-app-passwall_INCLUDE_Trojan=y +CONFIG_PACKAGE_luci-app-passwall_INCLUDE_Trojan_GO=y +CONFIG_PACKAGE_luci-app-passwall_INCLUDE_simple-obfs=y +CONFIG_PACKAGE_luci-app-passwall_INCLUDE_v2ray-plugin=y +CONFIG_PACKAGE_luci-app-passwall_INCLUDE_https_dns_proxy=n +CONFIG_PACKAGE_luci-app-openclash=y +CONFIG_PACKAGE_luci-app-zerotier=y +# CONFIG_PACKAGE_luci-app-accesscontrol is not set +# CONFIG_PACKAGE_luci-app-nlbwmon is not set +# CONFIG_PACKAGE_nlbwmon is not set +# CONFIG_PACKAGE_luci-app-pppoe-relay is not set +# CONFIG_PACKAGE_luci-app-pppoe-server is not set +# CONFIG_PACKAGE_luci-app-pptp-vpnserver-manyusers is not set +# CONFIG_PACKAGE_luci-app-sqm is not set +# CONFIG_PACKAGE_luci-app-ssr-python-pro-server is not set +# CONFIG_PACKAGE_luci-app-v2ray-server is not set +# CONFIG_PACKAGE_luci-app-vsftpd is not set +# CONFIG_PACKAGE_luci-app-vssr_INCLUDE_ShadowsocksR_Socks is not set +# CONFIG_TARGET_ROOTFS_TARGZ is not set +# CONFIG_OPENSSL_ENGINE_BUILTIN_DEVCRYPTO is not set +# CONFIG_PACKAGE_kmod-crypto-authenc is not set +# CONFIG_PACKAGE_kmod-cryptodev is not set +# CONFIG_PACKAGE_libopenssl-devcrypto is not set +# CONFIG_V2RAY_COMPRESS_UPX is not set +CONFIG_PACKAGE_luci-app-oled=y +CONFIG_PACKAGE_luci-app-adguardhome=y +CONFIG_PACKAGE_luci-app-flowoffload=y +# CONFIG_PACKAGE_luci-app-sfe is not set +CONFIG_DROPBEAR_ECC=y +CONFIG_DROPBEAR_ECC_FULL=y diff --git a/patch_kernel_5.4-test.sh b/patch_kernel_5.4-test.sh index 565bd367ca..72a7ebde8f 100644 --- a/patch_kernel_5.4-test.sh +++ b/patch_kernel_5.4-test.sh @@ -4,8 +4,8 @@ git apply ../../add_fullconenat.diff wget https://raw.githubusercontent.com/QiuSimons/R2S-OpenWrt/master/PATCH/new/main/999-unlock-1608mhz-rk3328.patch git apply 999-unlock-1608mhz-rk3328.patch cd ../ -git clone https://github.com/coolsnowwolf/lede && cd lede/ -git checkout 12d0742fd52a6fd32ffd1bd0cf58e33eb416416f +git clone -b openwrt-18.06-k5.4 --single-branch https://github.com/project-openwrt/openwrt && cd openwrt/ +git checkout 20c62b15584e5c902d51abdcec6e056584daa926 cp -a ./target/linux/generic/files/* ../kernel/ ./scripts/patch-kernel.sh ../kernel target/linux/generic/backport-5.4 ./scripts/patch-kernel.sh ../kernel target/linux/generic/pending-5.4 @@ -14,5 +14,12 @@ cd ../ wget https://github.com/torvalds/linux/raw/master/scripts/kconfig/merge_config.sh && chmod +x merge_config.sh grep -i '_NETFILTER_\|FLOW' ../.config.override > .config.override ./merge_config.sh -m .config.override kernel/arch/arm64/configs/nanopi-r2_linux_defconfig && mv .config kernel/arch/arm64/configs/nanopi-r2_linux_defconfig +echo ' +CONFIG_NF_CONNTRACK_EVENTS=y +CONFIG_NF_CONNTRACK_TIMEOUT=y +CONFIG_SHORTCUT_FE=y +CONFIG_XFRM=y +CONFIG_NF_CONNTRACK_CHAIN_EVENTS=y +' >> kernel/arch/arm64/configs/nanopi-r2_linux_defconfig sed -i -r 's/# (CONFIG_.*_ERRATUM_.*?) is.*/\1=y/g' kernel/arch/arm64/configs/nanopi-r2_linux_defconfig diff --git a/remove_unused_config.sh b/remove_unused_config.sh index ed7cfa1a96..4b1a57b01d 100644 --- a/remove_unused_config.sh +++ b/remove_unused_config.sh @@ -1,15 +1,12 @@ -[ -f configs/config_rk3328 ] && sed -i '/=m/d;/CONFIG_IB/d;/CONFIG_SDK/d;/CONFIG_BUILDBOT/d;/CONFIG_ALL_KMODS/d;/CONFIG_ALL_NONSHARED/d;/docker/d;/DOCKER/d;/CONFIG_DISPLAY_SUPPORT/d;/CONFIG_AUDIO_SUPPORT/d;/CONFIG_OPENSSL_PREFER_CHACHA_OVER_GCM/d;/CONFIG_VERSION/d;/SAMBA/d;/samba/d;/modemmanager/d;' configs/config_rk3328 -[ -f configs/config_rk3328 ] && sed -i '/CONFIG_KERNEL_CGROUP_PERF/i\CONFIG_KERNEL_CGROUPS=y' configs/config_rk3328 -[ -f configs/config_h5 ] && sed -i '/=m/d;/CONFIG_IB/d;/CONFIG_SDK/d;/CONFIG_BUILDBOT/d;/CONFIG_ALL_KMODS/d;/CONFIG_ALL_NONSHARED/d;/docker/d;/DOCKER/d;/CONFIG_DISPLAY_SUPPORT/d;/CONFIG_AUDIO_SUPPORT/d;/CONFIG_OPENSSL_PREFER_CHACHA_OVER_GCM/d;/CONFIG_VERSION/d;/SAMBA/d;/samba/d;/modemmanager/d;' configs/config_h5 -[ -f configs/config_h5 ] && sed -i '/CONFIG_KERNEL_CGROUP_PERF/i\CONFIG_KERNEL_CGROUPS=y' configs/config_h5 -[ -f configs/config_h3 ] && sed -i '/=m/d;/CONFIG_IB/d;/CONFIG_SDK/d;/CONFIG_BUILDBOT/d;/CONFIG_ALL_KMODS/d;/CONFIG_ALL_NONSHARED/d;/docker/d;/DOCKER/d;/CONFIG_DISPLAY_SUPPORT/d;/CONFIG_AUDIO_SUPPORT/d;/CONFIG_OPENSSL_PREFER_CHACHA_OVER_GCM/d;/CONFIG_VERSION/d;/SAMBA/d;/samba/d;/modemmanager/d;' configs/config_h3 -[ -f configs/config_h3 ] && sed -i '/CONFIG_KERNEL_CGROUP_PERF/i\CONFIG_KERNEL_CGROUPS=y' configs/config_h3 +[ -f configs/config_rk3328 ] && sed -i '/=m/d;/CONFIG_IB/d;/CONFIG_SDK/d;/CONFIG_BUILDBOT/d;/CONFIG_ALL_KMODS/d;/CONFIG_ALL_NONSHARED/d;/docker/d;/DOCKER/d;/CONFIG_DISPLAY_SUPPORT/d;/CONFIG_AUDIO_SUPPORT/d;/CONFIG_OPENSSL_PREFER_CHACHA_OVER_GCM/d;/CONFIG_VERSION/d;/SAMBA/d;/samba/d;/modemmanager/d;/CGROUPS/d' configs/config_rk3328 +[ -f configs/config_h5 ] && sed -i '/=m/d;/CONFIG_IB/d;/CONFIG_SDK/d;/CONFIG_BUILDBOT/d;/CONFIG_ALL_KMODS/d;/CONFIG_ALL_NONSHARED/d;/docker/d;/DOCKER/d;/CONFIG_DISPLAY_SUPPORT/d;/CONFIG_AUDIO_SUPPORT/d;/CONFIG_OPENSSL_PREFER_CHACHA_OVER_GCM/d;/CONFIG_VERSION/d;/SAMBA/d;/samba/d;/modemmanager/d;/CGROUPS/d' configs/config_h5 +[ -f configs/config_h3 ] && sed -i '/=m/d;/CONFIG_IB/d;/CONFIG_SDK/d;/CONFIG_BUILDBOT/d;/CONFIG_ALL_KMODS/d;/CONFIG_ALL_NONSHARED/d;/docker/d;/DOCKER/d;/CONFIG_DISPLAY_SUPPORT/d;/CONFIG_AUDIO_SUPPORT/d;/CONFIG_OPENSSL_PREFER_CHACHA_OVER_GCM/d;/CONFIG_VERSION/d;/SAMBA/d;/samba/d;/modemmanager/d;/CGROUPS/d' configs/config_h3 +[ -f friendlywrt/target/linux/rockchip-rk3328/config-4.14 ] && sed -i '/CONFIG_CGROUPS/a\CONFIG_CGROUP_PERF=y' friendlywrt/target/linux/rockchip-rk3328/config-4.14 +[ -f friendlywrt/target/linux/allwinner-h5/config-4.14 ] && sed -i '/CONFIG_CGROUPS/a\CONFIG_CGROUP_PERF=y' friendlywrt/target/linux/allwinner-h5/config-4.14 +cd friendlywrt/ && git add . && git commit -m 'reset' && cd ../ find device/ -name distfeeds.conf -delete -#[ -f kernel/arch/arm64/configs/nanopi-r2_linux_defconfig ] && sed -i 's/CONFIG_BPFILTER=y/CONFIG_BPFILTER=n/' kernel/arch/arm64/configs/nanopi-r2_linux_defconfig -#[ -f kernel/arch/arm64/configs/nanopi-r2_linux_defconfig ] && sed -i 's/CONFIG_NFT_FLOW_OFFLOAD=m/CONFIG_NFT_FLOW_OFFLOAD=y/' kernel/arch/arm64/configs/nanopi-r2_linux_defconfig - [ -f configs/config_rk3328 ] && echo -e '\nCONFIG_KERNEL_BUILD_USER="Dayong Chen"\nCONFIG_GRUB_TITLE="OpenWrt on Nanopi devices compiled by DayongChen"' >> configs/config_rk3328 [ -f configs/config_h5 ] && echo -e '\nCONFIG_KERNEL_BUILD_USER="Dayong Chen"\nCONFIG_GRUB_TITLE="OpenWrt on Nanopi devices compiled by DayongChen"' >> configs/config_h5 [ -f configs/config_h3 ] && echo -e '\nCONFIG_KERNEL_BUILD_USER="Dayong Chen"\nCONFIG_GRUB_TITLE="OpenWrt on Nanopi devices compiled by DayongChen"' >> configs/config_h3 diff --git a/x_assemble_artifact.sh b/x_assemble_artifact.sh new file mode 100644 index 0000000000..9892a09a83 --- /dev/null +++ b/x_assemble_artifact.sh @@ -0,0 +1,8 @@ +gzip friendlywrt-*/out/*.img +rm -rf ./artifact/ && mkdir -p ./artifact/ +mv friendlywrt-*/out/*img* ./artifact/ +cp friendlywrt-*/friendlywrt/.config ./artifact/ +cd ./artifact/ +md5sum *img* > md5sum.txt +cd .. +zip -r artifact.zip ./artifact/