update selfhost nodes #69
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name : update selfhost nodes | |
on: | |
# manual only | |
workflow_dispatch: | |
schedule: | |
- cron: "05 0 * * 0" # At 00:05 UTC on each Saturday | |
push: | |
branches: | |
- main | |
paths: | |
- 'toolset/**' | |
pull_request: | |
types: [ closed ] | |
branches: | |
- main | |
paths: | |
- 'toolset/**' | |
jobs: | |
build: | |
strategy: | |
fail-fast: false | |
matrix: | |
agent: [agent1, agent2, agent3, agent4] | |
runs-on: ${{matrix.agent}} | |
continue-on-error: true | |
permissions: {} | |
steps: | |
# https://docs.docker.com/engine/install/ubuntu/ | |
- name: upgrade docker | |
run: | | |
set +e | |
for pkg in docker.io docker-doc docker-compose docker-compose-v2 podman-docker containerd runc; do apt-get remove $pkg; done | |
apt autoremove | |
set -e | |
# Add Docker's official GPG key: | |
apt-get update | |
apt-get install ca-certificates curl | |
install -m 0755 -d /etc/apt/keyrings | |
curl -fsSL https://download.docker.com/linux/ubuntu/gpg -o /etc/apt/keyrings/docker.asc | |
chmod a+r /etc/apt/keyrings/docker.asc | |
# Add the repository to Apt sources: | |
echo \ | |
"deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.asc] https://download.docker.com/linux/ubuntu \ | |
$(. /etc/os-release && echo "$VERSION_CODENAME") stable" | \ | |
tee /etc/apt/sources.list.d/docker.list > /dev/null | |
apt-get update | |
apt-get install docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin | |
- name: Cleanup Docker | |
run: | | |
docker system prune -a -f | |
docker volume prune -f | |
- uses: actions/checkout@v4 | |
- name: Install the toolchain | |
run: | | |
export HOME=/root # Hack to workaround miniconda installation | |
./toolset/scripts/install.sh /root/miniconda |