Skip to content

Instantly share code, notes, and snippets.

@vjcitn
Last active July 17, 2026 23:11
Show Gist options
  • Select an option

  • Save vjcitn/26441f68f0e4c37c99b4e1471575ca43 to your computer and use it in GitHub Desktop.

Select an option

Save vjcitn/26441f68f0e4c37c99b4e1471575ca43 to your computer and use it in GitHub Desktop.
For Antigravity in AnVIL
FROM us.gcr.io/broad-dsp-gcr-public/terra-base:1.0.1
USER root
# utilities for Bioconductor AnVIL package installation
RUN apt-get update && \
apt-get install -y libuv1-dev libcurl4-openssl-dev libssl-dev
# If `AnVILGCP` is being installed, it relies on the `gcloud` command line utility
RUN curl -fsSL https://packages.cloud.google.com/apt/doc/apt-key.gpg | gpg --batch --yes --no-tty --dearmor -o /usr/share/keyrings/cloud.google.gpg
RUN echo "deb [signed-by=/usr/share/keyrings/cloud.google.gpg] https://packages.cloud.google.com/apt cloud-sdk main" | tee -a /etc/apt/sources.list.d/google-cloud-sdk.list
RUN apt-get update && \
apt-get install -y google-cloud-cli
## Step 3: Run Bioconductor Installation with Parallel Compilation
RUN Rscript -e 'install.packages("BiocManager")'
RUN Rscript -e 'BiocManager::install(c("AnVIL", "AnVILGCP", "dplyr"), update = FALSE, ask = FALSE, Ncpus = 4)'
## Step 4: Verify the Installation
RUN Rscript -e 'library(AnVIL); sessionInfo()'
## Install antigravity so it won't be overwritten by terra startup
RUN curl -fsSL https://antigravity.google/cli/install.sh | HOME=/root bash \
&& mv /root/.local/bin/agy /usr/local/bin/agy
USER jupyter
@vjcitn

vjcitn commented Jul 17, 2026

Copy link
Copy Markdown
Author

FROM us.gcr.io/broad-dsp-gcr-public/terra-base:1.0.1

USER root

utilities for Bioconductor AnVIL package installation

RUN apt-get update &&
apt-get install -y libuv1-dev libcurl4-openssl-dev libssl-dev

If AnVILGCP is being installed, it relies on the gcloud command line utility

RUN curl -fsSL https://packages.cloud.google.com/apt/doc/apt-key.gpg | gpg --batch --yes --no-tty --dearmor -o /usr/share/keyrings/cloud.google.gpg
RUN echo "deb [signed-by=/usr/share/keyrings/cloud.google.gpg] https://packages.cloud.google.com/apt cloud-sdk main" | tee -a /etc/apt/sources.list.d/google-cloud-sdk.list
RUN apt-get update &&
apt-get install -y google-cloud-cli

Step 3: Run Bioconductor Installation with Parallel Compilation

RUN Rscript -e 'install.packages("BiocManager")'
RUN Rscript -e 'BiocManager::install(c("AnVIL", "AnVILGCP", "dplyr"), update = FALSE, ask = FALSE, Ncpus = 4)'

Step 4: Verify the Installation

RUN Rscript -e 'library(AnVIL); sessionInfo()'

Install antigravity persistently

RUN curl -fsSL https://antigravity.google/cli/install.sh | HOME=/root bash
&& mv /root/.local/bin/agy /usr/local/bin/agy

USER jupyter

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment