Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ export BASE_2i2c_IMAGE_NAME = "${PROJECT_PREFIX}2i2c_${2i2c_IMAGE_NAME}"

# 2i2c commands
build-2i2c-image:
@cd base_images/2i2c/${IMAGE_NAME}; \
@cd base_images/2i2c/${2i2c_IMAGE_NAME}; \
pwd; \
docker buildx build --platform linux/amd64 --progress=plain $(RUN_OPTIONS) -t ${BASE_2i2c_IMAGE_NAME} -f docker/Dockerfile .

Expand Down
2 changes: 1 addition & 1 deletion base_images/2i2c/isce3/docker/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM pangeo/base-notebook:2025.08.14
FROM pangeo/base-notebook:2026.01.30
ENV LANG=en_US.UTF-8
ENV TZ=US/Pacific
ARG DEBIAN_FRONTEND=noninteractive
Expand Down
75 changes: 36 additions & 39 deletions base_images/2i2c/isce3/environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,53 +3,56 @@ channels:
- conda-forge
- nodefaults
dependencies:
- anywidget=0.9.18
- awscli=1.42.49
- anywidget=0.9.21
- awscli=1.44.32
- backoff=2.2.1
- boto3=1.40.49
- cython=3.1.6
- earthengine-api=1.6.14
- fsspec=2025.9.0
- gdal=3.11.4
- geopandas=1.1.1
- boto3=1.42.42
- code-server=3.3.1
- cython=3.2.4
- earthaccess=0.16.0
- earthengine-api=1.7.13
- fsspec=2026.2.0
- gdal=3.11.5
- geopandas=1.1.2
- groff=1.23.0
- h5py=3.15.1
- hdf5=1.14.6
- httpx=0.28.1
- hvplot=0.12.1
- isce3=0.25.3
- jupyterlab=4.4.10
- lonboard=0.12.1
- hvplot=0.12.2
- isce3=0.25.7
- jupyter-vscode-proxy=0.7
- lonboard=0.13.0
- mapclassify=2.10.0
- matplotlib=3.9.1
- matplotlib=3.10.8
- mpl-scatter-density=0.8
- nodejs=24.9.0
- numba=0.62.1
- numpy=2.3.4
- nodejs=25.2.1
- numba=0.63.1
- numpy=2.3.5
- openssh=10.2p1
- pandas=2.3.3
- pre_commit=4.5.1
- pycurl=7.45.7
- pyproj=3.7.2
#- pyogrio causes dependency conflicts with isce3
- pyopenssl=25.1.0
#- rasterio causes dependency conflicts with isce3
#- rasterstats causes dependency conflicts with isce3
- requests=2.32.5
#- rio-cogeo causes dependency conflicts with isce3
- pyopenssl=25.3.0
#- rasterstats
#- rio-cogeo
- pyviz_comms=3.0.4
- rtree=1.4.1
- s3fs=2025.9.0
- scikit-learn=1.7.2
- scipy=1.16.3
- s3fs=2026.2.0
- scikit-learn=1.8.0
- scipy=1.17.0
- seaborn=0.13.2
- shapely=2.1.2
- sliderule=4.5.3
- statsmodels=0.14.5
- tqdm=4.67.1
- unidecode=1.3.8
- sliderule=5.0.7
- statsmodels=0.14.6
- tqdm=4.67.3
- unidecode=1.4.0
- unzip=6.0
- xarray=2025.10.1
- pip=25.2
- xarray=2026.1.0
- pip=26.0
- pip:
- jupyter-resource-usage==1.2.0
- jupyter-sshd-proxy==0.3.0
- jupyterlab-bxplorer==0.2.30
# - git+https://github.com/MAAP-Project/stac_ipyleaflet.git@0.3.6
- morecantile==6.1.0
- rio-tiler==7.2.2
Expand All @@ -60,10 +63,4 @@ dependencies:
# - maap-edsc-jupyter-extension==1.1.1
- maap-help-jupyter-extension==2.0.2
- maap-libs-jupyter-extension==1.2.5
- maap-user-workspace-management-jupyter-extension==1.0.0
variables:
TITILER_STAC_ENDPOINT: 'https://openveda.cloud/api/stac'
TITILER_ENDPOINT: 'https://openveda.cloud/api/raster'
STAC_CATALOG_NAME: 'VEDA STAC'
STAC_CATALOG_URL: 'https://openveda.cloud/api/stac'
STAC_BROWSER_URL: 'https://openveda.cloud/'
- maap-user-workspace-management-jupyter-extension==1.0.0
2 changes: 1 addition & 1 deletion base_images/2i2c/pangeo/docker/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM pangeo/pangeo-notebook:2025.08.14
FROM public.ecr.aws/nasa-veda/pangeo-notebook-veda-image:2025.12.30-v1
ENV LANG=en_US.UTF-8
ENV TZ=US/Pacific
ARG DEBIAN_FRONTEND=noninteractive
Expand Down
16 changes: 3 additions & 13 deletions base_images/2i2c/pangeo/environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,24 +3,14 @@ channels:
- conda-forge
- nodefaults
dependencies:
- duckdb=1.3.2
- nodejs=24.9.0
- pip=25.2
- pip=26.0
- pip:
# - git+https://github.com/MAAP-Project/stac_ipyleaflet.git@0.3.6
- morecantile==6.1.0
- rio-tiler==7.2.2
- rio-tiler==8.0.5
- maap-py==4.2.0
- maap-algorithms-jupyter-extension==0.5.1
- maap-jupyter-server-extension==3.0.0
- maap-dps-jupyter-extension==0.7.7
# - maap-edsc-jupyter-extension==1.1.1
- maap-help-jupyter-extension==2.0.2
- maap-libs-jupyter-extension==1.2.5
- maap-user-workspace-management-jupyter-extension==1.0.0
variables:
TITILER_STAC_ENDPOINT: 'https://openveda.cloud/api/stac'
TITILER_ENDPOINT: 'https://openveda.cloud/api/raster'
STAC_CATALOG_NAME: 'VEDA STAC'
STAC_CATALOG_URL: 'https://openveda.cloud/api/stac'
STAC_BROWSER_URL: 'https://openveda.cloud/'
- maap-user-workspace-management-jupyter-extension==1.0.0
13 changes: 13 additions & 0 deletions base_images/2i2c/pytorch/docker/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
FROM quay.io/pangeo/pytorch-notebook:2025.12.30
ENV LANG=en_US.UTF-8
ENV TZ=US/Pacific
ARG DEBIAN_FRONTEND=noninteractive

# Install additional packages from environment.yml
COPY ./environment.yml /tmp
RUN conda env update -n ${CONDA_ENV} -f "/tmp/environment.yml" \
&& find ${CONDA_DIR}/ -follow -type f -name '*.a' -delete \
&& find ${CONDA_DIR}/ -follow -type f -name '*.js.map' -delete \
&& ${CONDA_DIR}/bin/conda clean -afy

RUN conda init
24 changes: 24 additions & 0 deletions base_images/2i2c/pytorch/environment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: notebook
channels:
- conda-forge
- nodefaults
dependencies:
# Dependencies for VS Code IDE
- code-server>=3.2
- jupyter-vscode-proxy=0.7
- pre_commit=3.4.0
# Upgrade from py torch notebook image
- earthaccess>=0.16.0
# Pin down to avoid https://github.com/holoviz/pyviz_comms/issues/143
- pyviz_comms==3.0.4
- pip=25.2
- pip:
- jupyter-sshd-proxy==0.3.0
- jupyterlab-bxplorer==0.2.30
- maap-py==4.2.0
- maap-algorithms-jupyter-extension==0.5.1
- maap-jupyter-server-extension==3.0.0
- maap-dps-jupyter-extension==0.7.7
- maap-help-jupyter-extension==2.0.2
- maap-libs-jupyter-extension==1.2.5
- maap-user-workspace-management-jupyter-extension==1.0.0
74 changes: 74 additions & 0 deletions base_images/2i2c/r-base/docker/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
FROM ghcr.io/nmfs-opensci/container-images/py-rocket-geospatial-2:2026.01.25
ENV LANG=en_US.UTF-8
ENV TZ=US/Pacific
ARG DEBIAN_FRONTEND=noninteractive

USER root

# Install system R and development libraries
# R will be completely separate from conda
RUN apt-get clean && apt-get update && \
apt-get install -y --no-install-recommends \
gdal-bin=3.8.4+dfsg-3ubuntu3 \
lbzip2=2.5-2.3 \
libfftw3-dev=3.3.10-1ubuntu3 \
libgdal-dev=3.8.4+dfsg-3ubuntu3 \
libgeos-dev=3.12.1-3build1 \
libgl1-mesa-dev=25.0.7-0ubuntu0.24.04.2 \
libglu1-mesa-dev=9.0.2-1.1build1 \
libhdf4-alt-dev=4.2.16-4build1 \
libhdf5-dev=1.10.10+repack-3.1ubuntu4 \
libjq-dev=1.7.1-3ubuntu0.24.04.1 \
libpq-dev=16.11-0ubuntu0.24.04.1 \
libproj-dev=9.4.0-1build2 \
libprotobuf-dev=3.21.12-8.2ubuntu0.2 \
libnetcdf-dev=1:4.9.2-5ubuntu4 \
libsqlite3-dev=3.45.1-1ubuntu2.5 \
libssl-dev=3.0.13-0ubuntu3.6 \
libudunits2-dev=2.2.28-7build1 \
netcdf-bin=1:4.9.2-5ubuntu4 \
postgis=3.4.2+dfsg-1ubuntu3 \
protobuf-compiler=3.21.12-8.2ubuntu0.2 \
sqlite3=3.45.1-1ubuntu2.5 \
tk-dev=8.6.14build1 \
unixodbc-dev=2.3.12-1ubuntu0.24.04.1 && \
apt-get clean && \
rm -rf /var/lib/apt/lists/*

USER ${NB_USER}

# Install additional packages from environment.yml
COPY ./environment.yml /tmp
RUN conda env update -n ${CONDA_ENV} -f "/tmp/environment.yml" \
&& find ${CONDA_DIR}/ -follow -type f -name '*.a' -delete \
&& find ${CONDA_DIR}/ -follow -type f -name '*.js.map' -delete \
&& ${CONDA_DIR}/bin/conda clean -afy

RUN conda init

USER root
SHELL ["/bin/bash", "-c"]
ADD . /
RUN ["chmod", "+x", "/scripts/install_cran_packages_r.sh"]
# Install R packages using SYSTEM R (not conda R)
# Do NOT activate conda environment here
# Clear conda's compiler paths to force use of system compiler
RUN export PATH=/usr/local/bin:/usr/bin:/bin:$PATH && \
/scripts/install_cran_packages_r.sh

RUN PYTHON_PATH=$(which python) && \
R_HOME=$(R RHOME) && \
CONDA_LIB="${CONDA_DIR}/envs/${CONDA_ENV}/lib" && \
echo "# Preload conda OpenSSL libraries to prevent GDAL from loading system OpenSSL" >> "$R_HOME/etc/Rprofile.site" && \
echo "Sys.setenv(LD_PRELOAD = '$CONDA_LIB/libcrypto.so.3:$CONDA_LIB/libssl.so.3')" >> "$R_HOME/etc/Rprofile.site" && \
echo "library(reticulate)" >> "$R_HOME/etc/Rprofile.site" && \
echo "use_python(\"$PYTHON_PATH\", required = TRUE)" >> "$R_HOME/etc/Rprofile.site" && \
echo "py_config()" >> "$R_HOME/etc/Rprofile.site"

COPY scripts/init-user.sh /usr/local/bin/init-user.sh
RUN chmod +x /usr/local/bin/init-user.sh

USER ${NB_USER}

# This script returns control to base image's /srv/start after
ENTRYPOINT ["/usr/local/bin/init-user.sh"]
15 changes: 15 additions & 0 deletions base_images/2i2c/r-base/environment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
name: notebook
channels:
- conda-forge
- nodefaults
dependencies:
# Python packages only - NO R packages in conda
- gdal=3.10.2
- nodejs=20.19.5
- rtree=1.4.1
- unzip=6.0
- pip=26.0
- pip:
# - git+https://github.com/MAAP-Project/stac_ipyleaflet.git@0.3.6
- morecantile==6.1.0
- rio-tiler==7.2.2
38 changes: 38 additions & 0 deletions base_images/2i2c/r-base/scripts/init-user.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
#!/bin/bash

R_SITE_ENV=$(R RHOME)/etc/Renviron.site

# Variables we want to add to Renviron
VARS=("AWS_ROLE_ARN" "AWS_WEB_IDENTITY_TOKEN_FILE" "AWS_DEFAULT_REGION" "MAAP_PGT")

echo "--- Updating R Site Environment Variables ---"

# Loop through the variables and append them if they exist in the current shell
for var_name in "${VARS[@]}"; do
# Use indirect expansion to get the value of the variable name
var_value="${!var_name}"

if [ -n "$var_value" ]; then
echo "Adding $var_name to $R_SITE_ENV"
# Check if the line already exists to avoid duplicates
if ! grep -q "^$var_name=" "$R_SITE_ENV"; then
echo "$var_name=$var_value" >> "$R_SITE_ENV"
else
# Update existing line if it changed
sed -i "s|^$var_name=.*|$var_name=$var_value|" "$R_SITE_ENV"
fi
else
echo "Skipping $var_name: Not set in shell environment."
fi
done

# File ends with a newline
echo "" >> "$R_SITE_ENV"

# Needed to run awsv2 and aws
awscliv2 --install
CONDA_BIN=$(dirname $(which python))
ln -sf $(which awsv2) "$CONDA_BIN/aws"

# Hand control to the base image's /srv/start which handles all initialization
exec /srv/start "$@"
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,10 @@ R_LIB=${R_LIB:-/usr/local/lib/R/site-library}

# Install recommended R packages first to avoid warnings
Rscript /scripts/install2.r --error --skipmissing --skipinstalled -l "$R_LIB" -r "https://cran.r-project.org" -n "$NCPUS" "codetools"
Rscript /scripts/install2.r --error --skipmissing --skipinstalled -l "$R_LIB" -r "https://cran.r-project.org" -n "$NCPUS" "tmap"
Rscript /scripts/install2.r --error --skipmissing --skipinstalled -l "$R_LIB" -r "https://cran.r-project.org" -n "$NCPUS" "tidyterra"
Rscript /scripts/install2.r --error --skipmissing --skipinstalled -l "$R_LIB" -r "https://cran.r-project.org" -n "$NCPUS" "BIOMASS"
Rscript /scripts/install2.r --error --skipmissing --skipinstalled -l "$R_LIB" -r "https://cran.r-project.org" -n "$NCPUS" "nlraa"
Rscript /scripts/install2.r --error --skipmissing --skipinstalled -l "$R_LIB" -r "https://cran.r-project.org" -n "$NCPUS" "essentials"
Rscript /scripts/install2.r --error --skipmissing --skipinstalled -l "$R_LIB" -r "https://cran.r-project.org" -n "$NCPUS" "geojsonio"
Rscript /scripts/install2.r --error --skipmissing --skipinstalled -l "$R_LIB" -r "https://cran.r-project.org" -n "$NCPUS" "future"
Rscript /scripts/install2.r --error --skipmissing --skipinstalled -l "$R_LIB" -r "https://r-lidar.r-universe.dev" -n "$NCPUS" "lasR"
Expand Down
45 changes: 1 addition & 44 deletions base_images/2i2c/r/docker/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,40 +1,8 @@
FROM ghcr.io/nmfs-opensci/container-images/py-rocket-geospatial:2025.04.26
FROM mas.dit.maap-project.org/root/maap-workspaces/2i2c/r-base:develop
ENV LANG=en_US.UTF-8
ENV TZ=US/Pacific
ARG DEBIAN_FRONTEND=noninteractive

USER root

# Install system R and development libraries
# R will be completely separate from conda
RUN apt-get clean && apt-get update && \
apt-get install -y --no-install-recommends \
gdal-bin=3.4.1+dfsg-1build4 \
lbzip2=2.5-2.3 \
libfftw3-dev=3.3.8-2ubuntu8 \
libgdal-dev=3.4.1+dfsg-1build4 \
libgeos-dev=3.10.2-1 \
libgl1-mesa-dev=23.2.1-1ubuntu3.1~22.04.3 \
libglu1-mesa-dev=9.0.2-1 \
libhdf4-alt-dev=4.2.15-4 \
libhdf5-dev=1.10.7+repack-4ubuntu2 \
libjq-dev=1.6-2.1ubuntu3.1 \
libpq-dev=14.19-0ubuntu0.22.04.1 \
libproj-dev=8.2.1-1 \
libprotobuf-dev=3.12.4-1ubuntu7.22.04.4 \
libnetcdf-dev=1:4.8.1-1 \
libsqlite3-dev=3.37.2-2ubuntu0.5 \
libssl-dev=3.0.2-0ubuntu1.20 \
libudunits2-dev=2.2.28-3 \
netcdf-bin=1:4.8.1-1 \
postgis=3.2.0+dfsg-1ubuntu1 \
protobuf-compiler=3.12.4-1ubuntu7.22.04.4 \
sqlite3=3.37.2-2ubuntu0.5 \
tk-dev=8.6.11+1build2 \
unixodbc-dev=2.3.9-5ubuntu0.1 && \
apt-get clean && \
rm -rf /var/lib/apt/lists/*

USER ${NB_USER}

# Install additional packages from environment.yml
Expand All @@ -45,14 +13,3 @@ RUN conda env update -n ${CONDA_ENV} -f "/tmp/environment.yml" \
&& ${CONDA_DIR}/bin/conda clean -afy

RUN conda init

USER root
SHELL ["/bin/bash", "-c"]
ADD . /
RUN ["chmod", "+x", "/scripts/install_cran_packages_r.sh"]
# Install R packages using SYSTEM R (not conda R)
# Do NOT activate conda environment here
# Clear conda's compiler paths to force use of system compiler
RUN export PATH=/usr/local/bin:/usr/bin:/bin:$PATH && \
/scripts/install_cran_packages_r.sh
USER ${NB_USER}
Loading