Skip to content

Latest commit

 

History

History
202 lines (162 loc) · 7.55 KB

NOTES.md

File metadata and controls

202 lines (162 loc) · 7.55 KB

Notes

These dev containers are derived from the language docker stacks, share their environment variables and incorporate most tweaks and default settings of the JupyterLab docker stacks.

They depend on very few Dev Container Features and add some extra customisation through build argument (build.args) and environment variables (remoteEnv).
ℹ️ See Notes on INSTALL_DEVTOOLS.

Tweaks

In comparison to the rocker-org/devcontainer-images, these dev containers are tweaked as follows:

Startup scripts

Julia images

The following startup scripts are put in place:

Environment variables

Julia images

  • JULIA_VERSION
  • JULIA_NUM_THREADS: If unset (default), Julia starts up with a single thread of execution.
    👉 User-settable at runtime.

R images

  • R_VERSION
  • QGIS_VERSION (R qgisprocess image)
  • OTB_VERSION (R qgisprocess image)
  • CRAN: The CRAN mirror URL.
    👉 User-settable at build time.
  • R_BINARY_PACKAGES: R package type to use.
    👉 User-settable at build time.
    • unset: Source packages. (default)
    • 1/yes: Binary packages.
  • DOWNLOAD_STATIC_LIBV8=1: R (V8): Installing V8 on Linux, the alternative way.
  • RETICULATE_MINICONDA_ENABLED=0: R (reticulate): Disable prompt to install miniconda.
  • QT_QPA_PLATFORM (R qgisprocess image): Qt Platform Plugin to use.
    👉 User-settable at runtime.
    • offscreen: Renders to an offscreen buffer. (default)
    • unset: Auto-detect Qt Platform Plugin.
  • LIBGL_ALWAYS_SOFTWARE=1 (R qgisprocess image): Always use software rendering.
    👉 User-settable at runtime.

MAX/Mojo images

  • MOJO_VERSION
  • MODULAR_HOME

Versions

  • PYTHON_VERSION
  • JUPYTERLAB_VERSION
  • GIT_VERSION
  • GIT_LFS_VERSION
  • PANDOC_VERSION
  • QUARTO_VERSION (Julia pubtools, MAX/Mojo/Python scipy, R verse+ images)

Miscellaneous

  • BASE_IMAGE: Its very base, a Docker Official Image.
  • PARENT_IMAGE: The image it was derived from.
  • PARENT_IMAGE_BUILD_DATE: The date the parent image was built (ISO 8601 format).
  • LANG: The locale inside the container.
    👉 User-settable at build time.
  • TZ: The timezone inside the container.
    👉 User-settable at build time.
  • PIP_USER: The Python package install directory.
    👉 User-settable at runtime.
    • 1: user directory (~/.local, persistent (default))
    • 0: system directory (/usr/local, not persistent)
  • CTAN_REPO: The CTAN mirror URL. (Julia pubtools, MAX/Mojo/Python scipy, R verse+ images)
  • OMP_NUM_THREADS: If unset (default), BLAS/OpenMP will use as many threads as possible.
    👉 User-settable at runtime.

Shell

The default shell is Zsh.

TeX packages (Julia pubtools, MAX/Mojo/Python scipy, R verse+ images)

In addition to the TeX packages used in rocker/verse, jupyter/scipy-notebook and required for nbconvert, the packages requested by the community are installed.

Settings

Default

  • IPython:
    • Only enable figure formats svg and pdf for IPython.
  • JupyterLab:
  • VS Code
    • Extensions > GitLab Workflow
      • Ai Assisted Code Suggestions: Enabled: false
    • Extensions > GitLens — Git supercharged
      • General > Show Welcome On Install: false
      • General > Show Whats New After Upgrade: false
    • Extensions > Resource Monitor Configuration
      • Show: Battery: false
      • Show: Cpufreq: false
  • Zsh
    • Oh My Zsh: ~/.zshrc
      • Set PATH so it includes user's private bin if it exists
  • Bash: /etc/skel/.profile
    • Update PATH for login shells, e.g. when started as a server associated with JupyterHub.

Julia images

  • VS Code
    • Extensions > Julia
      • Enable Crash Reporter: false
      • Enable Telemetry: false

MAX/Mojo images

R images

  • R: $(R RHOME)/etc/Rprofile.site
    • IRkernel: Only enable image/svg+xml and application/pdf for plot display.
    • R Extension (VS Code): Disable help panel and revert to old behaviour.
  • JupyterLab:
  • VS Code
    • Extensions > R
      • Bracketed Paste: true
      • Plot: Use Httpgd: true
      • Rterm: Linux: /usr/local/bin/radian
      • Rterm: Option: ["--no-save", "--no-restore"]
      • Workspace Viewer: Show Object Size: true

Customise

  • IPython: Create file ~/.ipython/profile_default/ipython_config.py
    • Valid figure formats: png, retina, jpeg, svg, pdf.
  • JupyterLab: Settings > Advanced Settings Editor
  • VS Code Server: Manage > Settings
  • Zsh
    • Oh My Zsh: Edit ~/.zshrc.
  • Bash
    • Edit ~/.bashrc.

R images

  • R: Create file ~/.Rprofile
    • Valid plot mimetypes: image/png, image/jpeg, image/svg+xml, application/pdf.
      ℹ️ MIME type text/plain must always be specified.

Python

The Python version is selected as follows:

  • Julia/MAX/Mojo/R images: The latest Python version Numba, PyTorch and TensorFlow are compatible with.
  • Python images: The latest Python version, regardless of whether all packages – such as Numba, PyTorch, TensorFlow, etc. – are already compatible with it.

This Python version is installed at /usr/local/bin.