Skip to content

Weekly clean & rebuild #128

Weekly clean & rebuild

Weekly clean & rebuild #128

Workflow file for this run

---
name: Weekly clean & rebuild
on:
schedule:
- cron: '0 8 * * 6'
workflow_dispatch:
concurrency:
group: ${{ github.workflow }}
jobs:
build:
uses: ./.github/workflows/build.yml
with:
cacheless: true
deploy-cache:
name: Deploy cache on cache.dasharo.com
needs: build
runs-on:
labels: dts-builder
steps:
- name: Prepare SSH key
shell: bash
env:
SSH_KEY: ${{secrets.SSH_KEY}}
run: |
echo -e ${SSH_KEY} > ~/.ssh/dts-ci-key
chmod 600 ~/.ssh/dts-ci-key
- name: Send sstate-cache folder to cache.dasharo.com
shell: bash
run: |
ssh -i ~/.ssh/dts-ci-key [email protected] "mkdir -p cache/yocto/dts"
rsync -P -e "ssh -i ~/.ssh/dts-ci-key" -rlptD --delete build/sstate-cache [email protected]:cache/yocto/dts
- name: Send downloads folder to cache.dasharo.com
shell: bash
run: |
rsync -P -e "ssh -i ~/.ssh/dts-ci-key" -rlptD --delete build/downloads [email protected]:cache/yocto/dts
cleanup:
name: Cleanup
if: always()
needs: deploy-cache
runs-on:
labels: dts-builder
steps:
- name: Cleanup after deployment
shell: bash
run: |
rm -rf ~/.ssh/dts-ci-key
rm -rf build