Browse Source

Download overlay2 Run 1

master
Mayank 5 years ago
parent
commit
374404e2a7
No known key found for this signature in database GPG Key ID: D037D60476CE748C
  1. 10
      .github/workflows/on-push.yml
  2. 72
      .github/workflows/on-tag-only.yml
  3. 14
      build-test.sh

10
.github/workflows/on-push.yml

@ -1,8 +1,7 @@
name: Testing only
on:
push:
branch:
- *
tags: [ '*' ]
jobs:
build:
@ -16,3 +15,10 @@ jobs:
sudo systemctl restart docker
- name: Run Build script
run: sudo ./build-test.sh
- name: Release zip
uses: meeDamian/github-release@2.0
with:
gzip: false
files: "overlay2.tar.gz"
token: ${{ secrets.GITHUB_TOKEN }}
allow_override: true

72
.github/workflows/on-tag-only.yml

@ -1,47 +1,47 @@
name: Automatically Build image on tag ONLY
on:
push:
tags: [ '*' ]
# name: Automatically Build image on tag ONLY
# on:
# push:
# tags: [ '*' ]
jobs:
build:
# jobs:
# build:
runs-on: ubuntu-18.04
# runs-on: ubuntu-18.04
steps:
# steps:
- uses: actions/checkout@v1
- name: Run Apt-get update
run: sudo apt-get update
# - uses: actions/checkout@v1
# - name: Run Apt-get update
# run: sudo apt-get update
- name: Install Dependencies
run: sudo apt-get -y install quilt qemu-user-static debootstrap bsdtar
# - name: Install Dependencies
# run: sudo apt-get -y install quilt qemu-user-static debootstrap bsdtar
- name: Enable experimental features in Docker
run: |
sudo rm -rf /etc/docker/daemon.json
echo '{"experimental": true}' | sudo tee -a /etc/docker/daemon.json
sudo systemctl restart docker
# - name: Enable experimental features in Docker
# run: |
# sudo rm -rf /etc/docker/daemon.json
# echo '{"experimental": true}' | sudo tee -a /etc/docker/daemon.json
# sudo systemctl restart docker
- name: Run Build script
run: sudo ./build.sh
# - name: Run Build script
# run: sudo ./build.sh
- name: Copy ZIP to current working dir
run: cp deploy/*.zip ./
# - name: Copy ZIP to current working dir
# run: cp deploy/*.zip ./
- name: Debug current working dir
run: ls -la
# - name: Debug current working dir
# run: ls -la
# - name: Release Image to placeholder or release
# uses: meeDamian/github-release@2.0
# if: startsWith(github.ref, 'refs/tags/')
# with:
# gzip: false
# files: "*.zip"
# token: ${{ secrets.GITHUB_TOKEN }}
# allow_override: true
# # - name: Release Image to placeholder or release
# # uses: meeDamian/github-release@2.0
# # if: startsWith(github.ref, 'refs/tags/')
# # with:
# # gzip: false
# # files: "*.zip"
# # token: ${{ secrets.GITHUB_TOKEN }}
# # allow_override: true
- name: Upload artifact
uses: actions/upload-artifact@v2
with:
path: "*.zip"
# - name: Upload artifact
# uses: actions/upload-artifact@v2
# with:
# path: "*.zip"

14
build-test.sh

@ -24,14 +24,18 @@ wget -q "https://raw.githubusercontent.com/getumbrel/umbrel-compose/master/docke
IMAGES=$(grep '^\s*image' docker-compose.yml | sed 's/image://' | sed 's/\"//g' | sed '/^$/d;s/[[:blank:]]//g' | sort | uniq)
echo "Pulling images in docker"
while IFS= read -r image; do
docker pull --platform=linux/arm/v7 $image
done <<< "$IMAGES"
# echo "Pulling images in docker"
# while IFS= read -r image; do
# docker pull --platform=linux/arm/v7 $image
# done <<< "$IMAGES"
docker pull --platform=linux/arm/v7 alpine:3.11
docker images -a
echo "Size of overlay 2 dir:"
du -sh /var/lib/docker/overlay2
tar -czvf ~/overlay2.tar.gz /var/lib/docker/overlay2
echo "Size of overlay 2 tar file:"
du -h ~/overlay2.tar.gz
# ls dockerpi
# ls dockerpi/var/lib/tor
# docker save $IMAGES -o umbrel-docker-images.tar

Loading…
Cancel
Save