From 8a1d0decadaf2c574e9ae71f1c5c98a016349895 Mon Sep 17 00:00:00 2001 From: ZhenYu Date: Thu, 19 Dec 2019 00:20:37 -0600 Subject: [PATCH] CI: rm useless apt sources (#2425) * CI: fix apt checking issue * regular update * regular update - 1 --- .github/workflows/openwrt-ci.yml | 198 +++++-------------------------- 1 file changed, 30 insertions(+), 168 deletions(-) diff --git a/.github/workflows/openwrt-ci.yml b/.github/workflows/openwrt-ci.yml index 75229053f..0d0fb9e7b 100644 --- a/.github/workflows/openwrt-ci.yml +++ b/.github/workflows/openwrt-ci.yml @@ -12,12 +12,11 @@ name: OpenWrt-CI on: schedule: - cron: 0 20 * * * - # push: - # branches: - # - master jobs: + build: + runs-on: ubuntu-latest steps: @@ -26,196 +25,59 @@ jobs: with: ref: master - - name: Initialization environment + - name: Space cleanup env: DEBIAN_FRONTEND: noninteractive run: | docker rmi `docker images -q` - echo "Deleting files, please wait ..." - sudo rm -rf \ - /usr/share/dotnet \ - /etc/mysql \ - /etc/php - sudo -E apt-get -y purge \ - azure-cli \ - ghc* \ - zulu* \ - hhvm \ - llvm* \ - firefox \ - google* \ - dotnet* \ - powershell \ - openjdk* \ - mysql* \ - php* + sudo rm -rf /usr/share/dotnet /etc/mysql /etc/php /etc/apt/sources.list.d + sudo -E apt-get -y purge azure-cli ghc* zulu* hhvm llvm* firefox google* dotnet* powershell openjdk* mysql* php* sudo -E apt-get update sudo -E apt-get -y install build-essential asciidoc binutils bzip2 gawk gettext git libncurses5-dev libz-dev patch unzip zlib1g-dev lib32gcc1 libc6-dev-i386 subversion flex uglifyjs git-core gcc-multilib p7zip p7zip-full msmtp libssl-dev texinfo libglib2.0-dev xmlto qemu-utils upx libelf-dev autoconf automake libtool autopoint device-tree-compiler sudo -E apt-get -y autoremove --purge sudo -E apt-get clean + # 利用挂载在 /mnt/ 的 14G 额外空间: + # sudo mkdir -p -m 777 /mnt/openwrt/bin /mnt/openwrt/build_dir/host /mnt/openwrt/build_dir/hostpkg /mnt/openwrt/dl /mnt/openwrt/feeds /mnt/openwrt/staging_dir + # ln -s /mnt/openwrt/bin ./bin + # mkdir -p ./build_dir/host && ln -s /mnt/openwrt/build_dir/host ./build_dir/host + # mkdir -p ./build_dir/host && ln -s /mnt/openwrt/build_dir/hostpkg ./build_dir/hostpkg + # ln -s /mnt/openwrt/dl ./dl + # ln -s /mnt/openwrt/feeds ./feeds + # ln -s /mnt/openwrt/staging_dir ./staging_dir + + df -h + - name: Update feeds run: | ./scripts/feeds update -a ./scripts/feeds install -a - - name: Costom configure file - run: | - rm -f ./.config* - touch ./.config - - # - # ========================固件定制部分======================== - # - - # - # 如果不对本区块做出任何编辑, 则生成默认配置固件. - # - - # 以下为定制化固件选项和说明: - # - - # - # 有些插件/选项是默认开启的, 如果想要关闭, 请参照以下示例进行编写: - # - # ========================================= - # | # 取消编译VMware镜像: | - # | cat >> .config <> .config <> .config <> .config <> .config <> .config <> .config <> .config <> .config <> .config <> .config <