v2024-05-17-jax #59
Workflow file for this run
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: build and push BrineyLab Docker images | |
on: | |
release: | |
types: [published] | |
jobs: | |
# ------------------ | |
# BASE | |
# ------------------ | |
base: | |
runs-on: ubuntu-latest | |
permissions: | |
contents: read | |
packages: write | |
steps: | |
- name: Delete huge unnecessary tools folder | |
run: rm -rf /opt/hostedtoolcache | |
- name: checkout | |
uses: actions/checkout@v4 | |
- name: set up QEMU | |
uses: docker/setup-qemu-action@v3 | |
- name: set up docker buildx | |
uses: docker/setup-buildx-action@v3 | |
- name: login to Docker Hub | |
uses: docker/login-action@v3 | |
with: | |
username: ${{ secrets.DOCKERHUB_USERNAME }} | |
password: ${{ secrets.DOCKERHUB_TOKEN }} | |
- name: build and push | |
uses: docker/build-push-action@v5 | |
with: | |
context: ./base | |
push: true | |
tags: | | |
brineylab/base:latest | |
brineylab/base:${{ github.event.release.tag_name }} | |
# ------------------ | |
# CODESERVER | |
# ------------------ | |
# codeserver depends on python and needs to wait to be built | |
kubeflow-codeserver: | |
runs-on: ubuntu-latest | |
permissions: | |
contents: read | |
packages: write | |
steps: | |
- name: Uninstall unnecessary software | |
run: | | |
echo "Disk space before uninstalling unnecessary software:" | |
sudo df -h | |
sudo apt install aptitude -y >/dev/null 2>&1 | |
sudo aptitude purge aria2 ansible azure-cli shellcheck rpm xorriso zsync \ | |
esl-erlang firefox gfortran-8 gfortran-9 google-chrome-stable \ | |
google-cloud-sdk google-cloud-cli imagemagick \ | |
libmagickcore-dev libmagickwand-dev libmagic-dev ant ant-optional kubectl \ | |
mercurial apt-transport-https mono-complete libmysqlclient \ | |
unixodbc-dev yarn chrpath libssl-dev libxft-dev \ | |
libfreetype6 libfreetype6-dev libfontconfig1 libfontconfig1-dev \ | |
snmp pollinate libpq-dev postgresql-client powershell ruby-full \ | |
sphinxsearch subversion mongodb-org azure-cli microsoft-edge-stable \ | |
-y -f >/dev/null 2>&1 | |
sudo aptitude purge google-cloud-sdk -f -y >/dev/null 2>&1 | |
sudo aptitude purge microsoft-edge-stable -f -y >/dev/null 2>&1 || true | |
sudo apt purge microsoft-edge-stable -f -y >/dev/null 2>&1 || true | |
removePackages=`apt list --manual-installed | awk '{print $1}' | sed 's|\(.*\)/.*|\1|' | grep -E -v 'base*|bash|binutils|bsdutils|bzip2|ca-certificates|coreutils|curl|dbus|diffutils|dpkg*|file|findutils|git*|grep|gzip|hostname|init|iproute2|iputils-ping|keyutils|lib*|linux-headers*|linux-image*|lld*|locales|login|lsb-release|make|net-tools|openssh-*|openssl|patchelf|rpm|rsync|session-manager-plugin|shellcheck|ssh|sudo|sysvinit-utils|tar|tcl*|time|tk|tzdata|ubuntu-*|unzip|upx-ucl|walinuxagent|wget|xz-utils|zip*|zsync|apt|dash|ncurses-bin|shim-signed|grub-efi-*|mokutil|sbsigntool|secureboot-db|docker-*|containerd.io' | tr '\n' ' '` | |
echo "Removing following userinstalled packages: $removePackages" | |
sudo apt-get purge -y $removePackages | |
sudo apt-get clean && sudo apt-get autoremove --purge -y $(dpkg -l | grep '^rc' | awk '{print $2}') && sudo rm -rf /var/lib/apt/lists/* | |
echo "Disk space after uninstalling unnecessary software" | |
sudo df -h | |
- name: Delete huge unnecessary tools folder | |
run: | | |
echo "Disk space before deleting huge unnecessary tools folder:" | |
sudo df -h | |
rm -rf /opt/hostedtoolcache | |
sudo rm -rf /usr/share/dotnet | |
sudo rm -rf /usr/local/games | |
sudo rm -rf /usr/local/sqlpackage | |
sudo rm -rf /usr/local/.ghcup | |
sudo rm -rf /usr/local/share/powershell | |
sudo rm -rf /usr/local/share/edge_driver | |
sudo rm -rf /usr/local/share/gecko_driver | |
sudo rm -rf /usr/local/share/chromium | |
sudo rm -rf /usr/local/share/chromedriver-linux64 | |
sudo rm -rf /usr/local/share/vcpkg | |
sudo rm -rf /usr/local/lib/node_modules | |
sudo rm -rf /usr/local/julia* | |
sudo rm -rf /opt/mssql-tools | |
sudo rm -rf /etc/skel | |
sudo rm -rf /usr/share/vim | |
sudo rm -rf /usr/share/postgresql | |
sudo rm -rf /usr/share/man | |
sudo rm -rf /usr/share/apache-maven-* | |
sudo rm -rf /usr/share/R | |
sudo rm -rf /usr/share/alsa | |
sudo rm -rf /usr/share/miniconda | |
sudo rm -rf /usr/share/grub | |
sudo rm -rf /usr/share/gradle-* | |
sudo rm -rf /usr/share/locale | |
sudo rm -rf /usr/share/texinfo | |
sudo rm -rf /usr/share/kotlinc | |
sudo rm -rf /usr/share/swift | |
sudo rm -rf /usr/share/doc | |
sudo rm -rf /usr/share/az_9.3.0 | |
sudo rm -rf /usr/share/sbt | |
sudo rm -rf /usr/share/ri | |
sudo rm -rf /usr/share/icons | |
sudo rm -rf /usr/share/java | |
sudo rm -rf /usr/share/fonts | |
sudo rm -rf /usr/lib/google-cloud-sdk | |
sudo rm -rf /usr/lib/jvm | |
sudo rm -rf /usr/lib/mono | |
sudo rm -rf /usr/lib/R | |
sudo rm -rf /usr/lib/postgresql | |
sudo rm -rf /usr/lib/heroku | |
sudo rm -rf "$AGENT_TOOLSDIRECTORY" | |
echo "Disk space after deleting huge unnecessary tools folder:" | |
sudo df -h | |
- name: Maximize build space | |
uses: easimon/maximize-build-space@master | |
with: | |
root-reserve-mb: 59392 | |
swap-size-mb: 1024 | |
remove-dotnet: 'true' | |
remove-android: 'true' | |
remove-haskell: 'true' | |
remove-codeql: 'true' | |
remove-docker-images: 'true' | |
- name: checkout | |
uses: actions/checkout@v4 | |
- name: set up QEMU | |
uses: docker/setup-qemu-action@v3 | |
- name: set up docker buildx | |
uses: docker/setup-buildx-action@v3 | |
- name: login to Docker Hub | |
uses: docker/login-action@v3 | |
with: | |
username: ${{ secrets.DOCKERHUB_USERNAME }} | |
password: ${{ secrets.DOCKERHUB_TOKEN }} | |
- name: build and push | |
uses: docker/build-push-action@v5 | |
with: | |
context: ./kubeflow/codeserver | |
push: true | |
tags: | | |
brineylab/kubeflow-codeserver:latest | |
brineylab/kubeflow-codeserver:${{ github.event.release.tag_name }} | |
# ------------------ | |
# JUPYTERHUB | |
# ------------------ | |
jupyterhub-base: | |
runs-on: ubuntu-latest | |
needs: [base] | |
permissions: | |
contents: read | |
packages: write | |
steps: | |
- name: Delete huge unnecessary tools folder | |
run: rm -rf /opt/hostedtoolcache | |
- name: checkout | |
uses: actions/checkout@v4 | |
- name: set up QEMU | |
uses: docker/setup-qemu-action@v3 | |
- name: set up docker buildx | |
uses: docker/setup-buildx-action@v3 | |
- name: login to Docker Hub | |
uses: docker/login-action@v3 | |
with: | |
username: ${{ secrets.DOCKERHUB_USERNAME }} | |
password: ${{ secrets.DOCKERHUB_TOKEN }} | |
- name: build and push | |
uses: docker/build-push-action@v5 | |
with: | |
context: ./jupyterhub/base | |
push: true | |
tags: | | |
brineylab/jupyterhub-base:latest | |
brineylab/jupyterhub-base:${{ github.event.release.tag_name }} | |
# jupyter depends on base and needs to wait to be built | |
jupyterhub-jupyter: | |
runs-on: ubuntu-latest | |
needs: [jupyterhub-base] | |
permissions: | |
contents: read | |
packages: write | |
steps: | |
- name: Delete huge unnecessary tools folder | |
run: rm -rf /opt/hostedtoolcache | |
- name: checkout | |
uses: actions/checkout@v4 | |
- name: set up QEMU | |
uses: docker/setup-qemu-action@v3 | |
- name: set up docker buildx | |
uses: docker/setup-buildx-action@v3 | |
- name: login to Docker Hub | |
uses: docker/login-action@v3 | |
with: | |
username: ${{ secrets.DOCKERHUB_USERNAME }} | |
password: ${{ secrets.DOCKERHUB_TOKEN }} | |
- name: build and push | |
uses: docker/build-push-action@v5 | |
with: | |
context: ./jupyterhub/jupyter | |
push: true | |
tags: | | |
brineylab/jupyterhub-jupyter:latest | |
brineylab/jupyterhub-jupyter:${{ github.event.release.tag_name }} | |
brineylab/jupyter:latest | |
brineylab/jupyter:${{ github.event.release.tag_name }} | |
# datascience image depends on jupyter | |
jupyterhub-datascience: | |
runs-on: ubuntu-latest | |
needs: [jupyterhub-jupyter] | |
permissions: | |
contents: read | |
packages: write | |
steps: | |
- name: Uninstall unnecessary software | |
run: | | |
echo "Disk space before uninstalling unnecessary software:" | |
sudo df -h | |
sudo apt install aptitude -y >/dev/null 2>&1 | |
sudo aptitude purge aria2 ansible azure-cli shellcheck rpm xorriso zsync \ | |
esl-erlang firefox gfortran-8 gfortran-9 google-chrome-stable \ | |
google-cloud-sdk google-cloud-cli imagemagick \ | |
libmagickcore-dev libmagickwand-dev libmagic-dev ant ant-optional kubectl \ | |
mercurial apt-transport-https mono-complete libmysqlclient \ | |
unixodbc-dev yarn chrpath libssl-dev libxft-dev \ | |
libfreetype6 libfreetype6-dev libfontconfig1 libfontconfig1-dev \ | |
snmp pollinate libpq-dev postgresql-client powershell ruby-full \ | |
sphinxsearch subversion mongodb-org azure-cli microsoft-edge-stable \ | |
-y -f >/dev/null 2>&1 | |
sudo aptitude purge google-cloud-sdk -f -y >/dev/null 2>&1 | |
sudo aptitude purge microsoft-edge-stable -f -y >/dev/null 2>&1 || true | |
sudo apt purge microsoft-edge-stable -f -y >/dev/null 2>&1 || true | |
echo "Disk space after uninstalling unnecessary software" | |
sudo df -h | |
- name: Delete huge unnecessary tools folder | |
run: | | |
echo "Disk space before deleting huge unnecessary tools folder:" | |
sudo df -h | |
rm -rf /opt/hostedtoolcache | |
sudo rm -rf /usr/share/dotnet | |
sudo rm -rf /usr/local/games | |
sudo rm -rf /usr/local/sqlpackage | |
sudo rm -rf /usr/local/.ghcup | |
sudo rm -rf /usr/local/share/powershell | |
sudo rm -rf /usr/local/share/edge_driver | |
sudo rm -rf /usr/local/share/gecko_driver | |
sudo rm -rf /usr/local/share/chromium | |
sudo rm -rf /usr/local/share/chromedriver-linux64 | |
sudo rm -rf /usr/local/share/vcpkg | |
sudo rm -rf /usr/local/lib/node_modules | |
sudo rm -rf /usr/local/julia* | |
sudo rm -rf /opt/mssql-tools | |
sudo rm -rf /etc/skel | |
sudo rm -rf /usr/share/vim | |
sudo rm -rf /usr/share/postgresql | |
sudo rm -rf /usr/share/man | |
sudo rm -rf /usr/share/apache-maven-* | |
sudo rm -rf /usr/share/R | |
sudo rm -rf /usr/share/alsa | |
sudo rm -rf /usr/share/miniconda | |
sudo rm -rf /usr/share/grub | |
sudo rm -rf /usr/share/gradle-* | |
sudo rm -rf /usr/share/locale | |
sudo rm -rf /usr/share/texinfo | |
sudo rm -rf /usr/share/kotlinc | |
sudo rm -rf /usr/share/swift | |
sudo rm -rf /usr/share/doc | |
sudo rm -rf /usr/share/az_9.3.0 | |
sudo rm -rf /usr/share/sbt | |
sudo rm -rf /usr/share/ri | |
sudo rm -rf /usr/share/icons | |
sudo rm -rf /usr/share/java | |
sudo rm -rf /usr/share/fonts | |
sudo rm -rf /usr/lib/google-cloud-sdk | |
sudo rm -rf /usr/lib/jvm | |
sudo rm -rf /usr/lib/mono | |
sudo rm -rf /usr/lib/R | |
sudo rm -rf /usr/lib/postgresql | |
sudo rm -rf /usr/lib/heroku | |
sudo rm -rf "$AGENT_TOOLSDIRECTORY" | |
echo "Disk space after deleting huge unnecessary tools folder:" | |
sudo df -h | |
- name: Maximize build space | |
uses: easimon/maximize-build-space@master | |
with: | |
root-reserve-mb: 59392 | |
swap-size-mb: 1024 | |
remove-dotnet: 'true' | |
remove-android: 'true' | |
remove-haskell: 'true' | |
remove-codeql: 'true' | |
remove-docker-images: 'true' | |
- name: checkout | |
uses: actions/checkout@v4 | |
- name: set up QEMU | |
uses: docker/setup-qemu-action@v3 | |
- name: set up docker buildx | |
uses: docker/setup-buildx-action@v3 | |
- name: login to Docker Hub | |
uses: docker/login-action@v3 | |
with: | |
username: ${{ secrets.DOCKERHUB_USERNAME }} | |
password: ${{ secrets.DOCKERHUB_TOKEN }} | |
- name: build and push | |
uses: docker/build-push-action@v5 | |
with: | |
context: ./jupyterhub/datascience | |
push: true | |
tags: | | |
brineylab/jupyterhub-datascience:latest | |
brineylab/jupyterhub-datascience:${{ github.event.release.tag_name }} | |
brineylab/datascience:latest | |
brineylab/datascience:${{ github.event.release.tag_name }} | |
# deeplearning image depends on datascience | |
jupyterhub-deeplearning: | |
runs-on: ubuntu-latest | |
needs: [jupyterhub-datascience] | |
permissions: | |
contents: read | |
packages: write | |
steps: | |
- name: Uninstall unnecessary software | |
run: | | |
echo "Disk space before uninstalling unnecessary software:" | |
sudo df -h | |
sudo rm -rf \ | |
/usr/share/dotnet /usr/local/lib/android /opt/ghc \ | |
/usr/local/share/powershell /usr/share/swift /usr/local/.ghcup \ | |
/usr/lib/jvm || true | |
sudo apt install aptitude -y >/dev/null 2>&1 | |
sudo aptitude purge aria2 ansible azure-cli shellcheck rpm xorriso zsync \ | |
esl-erlang firefox gfortran-8 gfortran-9 google-chrome-stable \ | |
google-cloud-sdk google-cloud-cli imagemagick \ | |
libmagickcore-dev libmagickwand-dev libmagic-dev ant ant-optional kubectl \ | |
mercurial apt-transport-https mono-complete libmysqlclient \ | |
unixodbc-dev yarn chrpath libssl-dev libxft-dev \ | |
libfreetype6 libfreetype6-dev libfontconfig1 libfontconfig1-dev \ | |
snmp pollinate libpq-dev postgresql-client powershell ruby-full \ | |
sphinxsearch subversion mongodb-org azure-cli microsoft-edge-stable \ | |
-y -f >/dev/null 2>&1 | |
sudo aptitude purge google-cloud-sdk -f -y >/dev/null 2>&1 | |
sudo aptitude purge microsoft-edge-stable -f -y >/dev/null 2>&1 || true | |
sudo apt purge microsoft-edge-stable -f -y >/dev/null 2>&1 || true | |
sudo aptitude purge '~n ^mysql' -f -y >/dev/null 2>&1 | |
sudo aptitude purge '~n ^php' -f -y >/dev/null 2>&1 | |
sudo aptitude purge '~n ^dotnet' -f -y >/dev/null 2>&1 | |
sudo apt-get autoremove -y >/dev/null 2>&1 | |
sudo apt-get autoclean -y >/dev/null 2>&1 | |
echo "some packages purged" | |
echo "Disk space after uninstalling unnecessary software" | |
sudo df -h | |
- name: Delete huge unnecessary tools folder | |
run: | | |
echo "Disk space before deleting huge unnecessary tools folder:" | |
sudo df -h | |
rm -rf /opt/hostedtoolcache | |
sudo rm -rf /usr/share/dotnet | |
sudo rm -rf /usr/local/games | |
sudo rm -rf /usr/local/sqlpackage | |
sudo rm -rf /usr/local/.ghcup | |
sudo rm -rf /usr/local/share/powershell | |
sudo rm -rf /usr/local/share/edge_driver | |
sudo rm -rf /usr/local/share/gecko_driver | |
sudo rm -rf /usr/local/share/chromium | |
sudo rm -rf /usr/local/share/chromedriver-linux64 | |
sudo rm -rf /usr/local/share/vcpkg | |
sudo rm -rf /usr/local/lib/python* | |
sudo rm -rf /usr/local/lib/node_modules | |
sudo rm -rf /usr/local/julia* | |
sudo rm -rf /opt/mssql-tools | |
sudo rm -rf /etc/skel | |
sudo rm -rf /usr/share/vim | |
sudo rm -rf /usr/share/postgresql | |
sudo rm -rf /usr/share/man | |
sudo rm -rf /usr/share/apache-maven-* | |
sudo rm -rf /usr/share/R | |
sudo rm -rf /usr/share/alsa | |
sudo rm -rf /usr/share/miniconda | |
sudo rm -rf /usr/share/grub | |
sudo rm -rf /usr/share/gradle-* | |
sudo rm -rf /usr/share/locale | |
sudo rm -rf /usr/share/texinfo | |
sudo rm -rf /usr/share/kotlinc | |
sudo rm -rf /usr/share/swift | |
sudo rm -rf /usr/share/doc | |
sudo rm -rf /usr/share/az_9.3.0 | |
sudo rm -rf /usr/share/sbt | |
sudo rm -rf /usr/share/ri | |
sudo rm -rf /usr/share/icons | |
sudo rm -rf /usr/share/java | |
sudo rm -rf /usr/share/fonts | |
sudo rm -rf /usr/lib/google-cloud-sdk | |
sudo rm -rf /usr/lib/jvm | |
sudo rm -rf /usr/lib/mono | |
sudo rm -rf /usr/lib/R | |
sudo rm -rf /usr/lib/postgresql | |
sudo rm -rf /usr/lib/heroku | |
sudo rm -rf "$AGENT_TOOLSDIRECTORY" | |
echo "Disk space after deleting huge unnecessary tools folder:" | |
sudo df -h | |
- name: Maximize build space | |
uses: easimon/maximize-build-space@master | |
with: | |
root-reserve-mb: 59392 | |
swap-size-mb: 1024 | |
remove-dotnet: 'true' | |
remove-android: 'true' | |
remove-haskell: 'true' | |
remove-codeql: 'true' | |
remove-docker-images: 'true' | |
- name: checkout | |
uses: actions/checkout@v4 | |
- name: set up QEMU | |
uses: docker/setup-qemu-action@v3 | |
- name: set up docker buildx | |
uses: docker/setup-buildx-action@v3 | |
- name: login to Docker Hub | |
uses: docker/login-action@v3 | |
with: | |
username: ${{ secrets.DOCKERHUB_USERNAME }} | |
password: ${{ secrets.DOCKERHUB_TOKEN }} | |
- name: build and push | |
uses: docker/build-push-action@v5 | |
with: | |
context: ./jupyterhub/deeplearning | |
push: true | |
tags: | | |
brineylab/jupyterhub-deeplearning:latest | |
brineylab/jupyterhub-deeplearning:${{ github.event.release.tag_name }} | |
brineylab/deeplearning:latest | |
brineylab/deeplearning:${{ github.event.release.tag_name }} | |
# ------------------ | |
# KUBEFLOW | |
# ------------------ | |
kubeflow-base: | |
runs-on: ubuntu-latest | |
needs: [base] | |
permissions: | |
contents: read | |
packages: write | |
steps: | |
- name: Delete huge unnecessary tools folder | |
run: rm -rf /opt/hostedtoolcache | |
- name: checkout | |
uses: actions/checkout@v4 | |
- name: set up QEMU | |
uses: docker/setup-qemu-action@v3 | |
- name: set up docker buildx | |
uses: docker/setup-buildx-action@v3 | |
- name: login to Docker Hub | |
uses: docker/login-action@v3 | |
with: | |
username: ${{ secrets.DOCKERHUB_USERNAME }} | |
password: ${{ secrets.DOCKERHUB_TOKEN }} | |
- name: build and push | |
uses: docker/build-push-action@v5 | |
with: | |
context: ./kubeflow/base | |
push: true | |
tags: | | |
brineylab/kubeflow-base:latest | |
brineylab/kubeflow-base:${{ github.event.release.tag_name }} | |
# python depends on base and needs to wait to be built | |
kubeflow-python: | |
runs-on: ubuntu-latest | |
needs: [kubeflow-base] | |
permissions: | |
contents: read | |
packages: write | |
steps: | |
- name: Delete huge unnecessary tools folder | |
run: rm -rf /opt/hostedtoolcache | |
- name: checkout | |
uses: actions/checkout@v4 | |
- name: set up QEMU | |
uses: docker/setup-qemu-action@v3 | |
- name: set up docker buildx | |
uses: docker/setup-buildx-action@v3 | |
- name: login to Docker Hub | |
uses: docker/login-action@v3 | |
with: | |
username: ${{ secrets.DOCKERHUB_USERNAME }} | |
password: ${{ secrets.DOCKERHUB_TOKEN }} | |
- name: build and push | |
uses: docker/build-push-action@v5 | |
with: | |
context: ./kubeflow/python | |
push: true | |
tags: | | |
brineylab/kubeflow-python:latest | |
brineylab/kubeflow-python:${{ github.event.release.tag_name }} | |
# jupyter depends on python and needs to wait to be built | |
kubeflow-jupyter: | |
runs-on: ubuntu-latest | |
needs: [kubeflow-python] | |
permissions: | |
contents: read | |
packages: write | |
steps: | |
- name: Delete huge unnecessary tools folder | |
run: rm -rf /opt/hostedtoolcache | |
- name: checkout | |
uses: actions/checkout@v4 | |
- name: set up QEMU | |
uses: docker/setup-qemu-action@v3 | |
- name: set up docker buildx | |
uses: docker/setup-buildx-action@v3 | |
- name: login to Docker Hub | |
uses: docker/login-action@v3 | |
with: | |
username: ${{ secrets.DOCKERHUB_USERNAME }} | |
password: ${{ secrets.DOCKERHUB_TOKEN }} | |
- name: build and push | |
uses: docker/build-push-action@v5 | |
with: | |
context: ./kubeflow/jupyter | |
push: true | |
tags: | | |
brineylab/kubeflow-jupyter:latest | |
brineylab/kubeflow-jupyter:${{ github.event.release.tag_name }} | |
# datascience image depends on jupyter | |
kubeflow-datascience: | |
runs-on: ubuntu-latest | |
needs: [kubeflow-jupyter] | |
permissions: | |
contents: read | |
packages: write | |
steps: | |
- name: Uninstall unnecessary software | |
run: | | |
echo "Disk space before uninstalling unnecessary software:" | |
sudo df -h | |
sudo apt install aptitude -y >/dev/null 2>&1 | |
sudo aptitude purge aria2 ansible azure-cli shellcheck rpm xorriso zsync \ | |
esl-erlang firefox gfortran-8 gfortran-9 google-chrome-stable \ | |
google-cloud-sdk google-cloud-cli imagemagick \ | |
libmagickcore-dev libmagickwand-dev libmagic-dev ant ant-optional kubectl \ | |
mercurial apt-transport-https mono-complete libmysqlclient \ | |
unixodbc-dev yarn chrpath libssl-dev libxft-dev \ | |
libfreetype6 libfreetype6-dev libfontconfig1 libfontconfig1-dev \ | |
snmp pollinate libpq-dev postgresql-client powershell ruby-full \ | |
sphinxsearch subversion mongodb-org azure-cli microsoft-edge-stable \ | |
-y -f >/dev/null 2>&1 | |
sudo aptitude purge google-cloud-sdk -f -y >/dev/null 2>&1 | |
sudo aptitude purge microsoft-edge-stable -f -y >/dev/null 2>&1 || true | |
sudo apt purge microsoft-edge-stable -f -y >/dev/null 2>&1 || true | |
echo "Disk space after uninstalling unnecessary software" | |
sudo df -h | |
- name: Delete huge unnecessary tools folder | |
run: | | |
echo "Disk space before deleting huge unnecessary tools folder:" | |
sudo df -h | |
rm -rf /opt/hostedtoolcache | |
sudo rm -rf /usr/share/dotnet | |
sudo rm -rf /usr/local/games | |
sudo rm -rf /usr/local/sqlpackage | |
sudo rm -rf /usr/local/.ghcup | |
sudo rm -rf /usr/local/share/powershell | |
sudo rm -rf /usr/local/share/edge_driver | |
sudo rm -rf /usr/local/share/gecko_driver | |
sudo rm -rf /usr/local/share/chromium | |
sudo rm -rf /usr/local/share/chromedriver-linux64 | |
sudo rm -rf /usr/local/share/vcpkg | |
sudo rm -rf /usr/local/lib/python* | |
sudo rm -rf /usr/local/lib/node_modules | |
sudo rm -rf /usr/local/julia* | |
sudo rm -rf /opt/mssql-tools | |
sudo rm -rf /etc/skel | |
sudo rm -rf /usr/share/vim | |
sudo rm -rf /usr/share/postgresql | |
sudo rm -rf /usr/share/man | |
sudo rm -rf /usr/share/apache-maven-* | |
sudo rm -rf /usr/share/R | |
sudo rm -rf /usr/share/alsa | |
sudo rm -rf /usr/share/miniconda | |
sudo rm -rf /usr/share/grub | |
sudo rm -rf /usr/share/gradle-* | |
sudo rm -rf /usr/share/locale | |
sudo rm -rf /usr/share/texinfo | |
sudo rm -rf /usr/share/kotlinc | |
sudo rm -rf /usr/share/swift | |
sudo rm -rf /usr/share/doc | |
sudo rm -rf /usr/share/az_9.3.0 | |
sudo rm -rf /usr/share/sbt | |
sudo rm -rf /usr/share/ri | |
sudo rm -rf /usr/share/icons | |
sudo rm -rf /usr/share/java | |
sudo rm -rf /usr/share/fonts | |
sudo rm -rf /usr/lib/google-cloud-sdk | |
sudo rm -rf /usr/lib/jvm | |
sudo rm -rf /usr/lib/mono | |
sudo rm -rf /usr/lib/R | |
sudo rm -rf /usr/lib/postgresql | |
sudo rm -rf /usr/lib/heroku | |
sudo rm -rf "$AGENT_TOOLSDIRECTORY" | |
echo "Disk space after deleting huge unnecessary tools folder:" | |
sudo df -h | |
- name: Maximize build space | |
uses: easimon/maximize-build-space@master | |
with: | |
root-reserve-mb: 59392 | |
swap-size-mb: 1024 | |
remove-dotnet: 'true' | |
remove-android: 'true' | |
remove-haskell: 'true' | |
remove-codeql: 'true' | |
remove-docker-images: 'true' | |
- name: checkout | |
uses: actions/checkout@v4 | |
- name: set up QEMU | |
uses: docker/setup-qemu-action@v3 | |
- name: set up docker buildx | |
uses: docker/setup-buildx-action@v3 | |
- name: login to Docker Hub | |
uses: docker/login-action@v3 | |
with: | |
username: ${{ secrets.DOCKERHUB_USERNAME }} | |
password: ${{ secrets.DOCKERHUB_TOKEN }} | |
- name: build and push | |
uses: docker/build-push-action@v5 | |
with: | |
context: ./kubeflow/datascience | |
push: true | |
tags: | | |
brineylab/kubeflow-datascience:latest | |
brineylab/kubeflow-datascience:${{ github.event.release.tag_name }} | |
# deeplearning image depends on datascience | |
kubeflow-deeplearning: | |
runs-on: ubuntu-latest | |
needs: [kubeflow-datascience] | |
permissions: | |
contents: read | |
packages: write | |
steps: | |
- name: Uninstall unnecessary software | |
run: | | |
echo "Disk space before uninstalling unnecessary software:" | |
sudo df -h | |
sudo rm -rf \ | |
/usr/share/dotnet /usr/local/lib/android /opt/ghc \ | |
/usr/local/share/powershell /usr/share/swift /usr/local/.ghcup \ | |
/usr/lib/jvm || true | |
sudo apt install aptitude -y >/dev/null 2>&1 | |
sudo aptitude purge aria2 ansible azure-cli shellcheck rpm xorriso zsync \ | |
esl-erlang firefox gfortran-8 gfortran-9 google-chrome-stable \ | |
google-cloud-sdk google-cloud-cli imagemagick \ | |
libmagickcore-dev libmagickwand-dev libmagic-dev ant ant-optional kubectl \ | |
mercurial apt-transport-https mono-complete libmysqlclient \ | |
unixodbc-dev yarn chrpath libssl-dev libxft-dev \ | |
libfreetype6 libfreetype6-dev libfontconfig1 libfontconfig1-dev \ | |
snmp pollinate libpq-dev postgresql-client powershell ruby-full \ | |
sphinxsearch subversion mongodb-org azure-cli microsoft-edge-stable \ | |
-y -f >/dev/null 2>&1 | |
sudo aptitude purge google-cloud-sdk -f -y >/dev/null 2>&1 | |
sudo aptitude purge microsoft-edge-stable -f -y >/dev/null 2>&1 || true | |
sudo apt purge microsoft-edge-stable -f -y >/dev/null 2>&1 || true | |
sudo aptitude purge '~n ^mysql' -f -y >/dev/null 2>&1 | |
sudo aptitude purge '~n ^php' -f -y >/dev/null 2>&1 | |
sudo aptitude purge '~n ^dotnet' -f -y >/dev/null 2>&1 | |
sudo apt-get autoremove -y >/dev/null 2>&1 | |
sudo apt-get autoclean -y >/dev/null 2>&1 | |
echo "Disk space after uninstalling unnecessary software" | |
sudo df -h | |
- name: Delete huge unnecessary tools folder | |
run: | | |
echo "Disk space before deleting huge unnecessary tools folder:" | |
sudo df -h | |
rm -rf /opt/hostedtoolcache | |
sudo rm -rf /usr/share/dotnet | |
sudo rm -rf /usr/local/games | |
sudo rm -rf /usr/local/sqlpackage | |
sudo rm -rf /usr/local/.ghcup | |
sudo rm -rf /usr/local/share/powershell | |
sudo rm -rf /usr/local/share/edge_driver | |
sudo rm -rf /usr/local/share/gecko_driver | |
sudo rm -rf /usr/local/share/chromium | |
sudo rm -rf /usr/local/share/chromedriver-linux64 | |
sudo rm -rf /usr/local/share/vcpkg | |
sudo rm -rf /usr/local/lib/python* | |
sudo rm -rf /usr/local/lib/node_modules | |
sudo rm -rf /usr/local/julia* | |
sudo rm -rf /opt/mssql-tools | |
sudo rm -rf /etc/skel | |
sudo rm -rf /usr/share/vim | |
sudo rm -rf /usr/share/postgresql | |
sudo rm -rf /usr/share/man | |
sudo rm -rf /usr/share/apache-maven-* | |
sudo rm -rf /usr/share/R | |
sudo rm -rf /usr/share/alsa | |
sudo rm -rf /usr/share/miniconda | |
sudo rm -rf /usr/share/grub | |
sudo rm -rf /usr/share/gradle-* | |
sudo rm -rf /usr/share/locale | |
sudo rm -rf /usr/share/texinfo | |
sudo rm -rf /usr/share/kotlinc | |
sudo rm -rf /usr/share/swift | |
sudo rm -rf /usr/share/doc | |
sudo rm -rf /usr/share/az_9.3.0 | |
sudo rm -rf /usr/share/sbt | |
sudo rm -rf /usr/share/ri | |
sudo rm -rf /usr/share/icons | |
sudo rm -rf /usr/share/java | |
sudo rm -rf /usr/share/fonts | |
sudo rm -rf /usr/lib/google-cloud-sdk | |
sudo rm -rf /usr/lib/jvm | |
sudo rm -rf /usr/lib/mono | |
sudo rm -rf /usr/lib/R | |
sudo rm -rf /usr/lib/postgresql | |
sudo rm -rf /usr/lib/heroku | |
sudo rm -rf "$AGENT_TOOLSDIRECTORY" | |
echo "Disk space after deleting huge unnecessary tools folder:" | |
sudo df -h | |
- name: Maximize build space | |
uses: easimon/maximize-build-space@master | |
with: | |
root-reserve-mb: 59392 | |
swap-size-mb: 1024 | |
remove-dotnet: 'true' | |
remove-android: 'true' | |
remove-haskell: 'true' | |
remove-codeql: 'true' | |
remove-docker-images: 'true' | |
- name: checkout | |
uses: actions/checkout@v4 | |
- name: set up QEMU | |
uses: docker/setup-qemu-action@v3 | |
- name: set up docker buildx | |
uses: docker/setup-buildx-action@v3 | |
- name: login to Docker Hub | |
uses: docker/login-action@v3 | |
with: | |
username: ${{ secrets.DOCKERHUB_USERNAME }} | |
password: ${{ secrets.DOCKERHUB_TOKEN }} | |
- name: build and push | |
uses: docker/build-push-action@v5 | |
with: | |
context: ./kubeflow/deeplearning | |
push: true | |
tags: | | |
brineylab/kubeflow-deeplearning:latest | |
brineylab/kubeflow-deeplearning:${{ github.event.release.tag_name }} | |