├── .gitignore ├── update.sh ├── .gitattributes ├── shared.jq ├── docker-entrypoint.sh ├── 1.10 ├── trixie │ ├── docker-entrypoint.sh │ └── Dockerfile ├── alpine3.22 │ ├── docker-entrypoint.sh │ └── Dockerfile ├── alpine3.23 │ ├── docker-entrypoint.sh │ └── Dockerfile ├── bookworm │ ├── docker-entrypoint.sh │ └── Dockerfile └── windows │ ├── servercore-ltsc2022 │ └── Dockerfile │ └── servercore-ltsc2025 │ └── Dockerfile ├── rc ├── bookworm │ ├── docker-entrypoint.sh │ └── Dockerfile ├── trixie │ ├── docker-entrypoint.sh │ └── Dockerfile └── windows │ ├── servercore-ltsc2022 │ └── Dockerfile │ └── servercore-ltsc2025 │ └── Dockerfile ├── stable ├── bookworm │ ├── docker-entrypoint.sh │ └── Dockerfile ├── trixie │ ├── docker-entrypoint.sh │ └── Dockerfile └── windows │ ├── servercore-ltsc2022 │ └── Dockerfile │ └── servercore-ltsc2025 │ └── Dockerfile ├── .github └── workflows │ ├── verify-templating.yml │ └── ci.yml ├── LICENSE ├── Dockerfile-windows.template ├── generate-stackbrew-library.sh ├── README.md ├── apply-templates.sh ├── Dockerfile-linux.template ├── generate-stackbrew-library.jq ├── versions.sh └── versions.json /.gitignore: -------------------------------------------------------------------------------- 1 | .jq-template.awk 2 | -------------------------------------------------------------------------------- /update.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | set -Eeuo pipefail 3 | 4 | cd "$(dirname "$(readlink -f "$BASH_SOURCE")")" 5 | 6 | ./versions.sh "$@" 7 | ./apply-templates.sh "$@" 8 | -------------------------------------------------------------------------------- /.gitattributes: -------------------------------------------------------------------------------- 1 | /*/**/Dockerfile linguist-generated 2 | /*/**/docker-entrypoint.sh linguist-generated 3 | /Dockerfile*.template linguist-language=Dockerfile 4 | -------------------------------------------------------------------------------- /shared.jq: -------------------------------------------------------------------------------- 1 | def from($variant): 2 | $variant 3 | | if startswith("alpine") then 4 | "alpine:\(ltrimstr("alpine"))" 5 | elif startswith("windows/") then 6 | "mcr.microsoft.com/\(sub("-"; ":"))" # mcr.microsoft.com/windows/servercore:ltsc2025, ... 7 | else 8 | "debian:\(.)-slim" 9 | end 10 | ; 11 | -------------------------------------------------------------------------------- /docker-entrypoint.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | set -eu 3 | 4 | # first arg is `-e` or `--some-option` (docker run julia -e '42') 5 | # ... is a "*.jl" file (docker run -v ...:/my/file.jl:ro julia /my/file.jl) 6 | # ... or there are no args 7 | if [ "$#" -eq 0 ] || [ "${1#-}" != "$1" ] || [ "${1%.jl}" != "$1" ]; then 8 | exec julia "$@" 9 | fi 10 | 11 | exec "$@" 12 | -------------------------------------------------------------------------------- /1.10/trixie/docker-entrypoint.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | set -eu 3 | 4 | # first arg is `-e` or `--some-option` (docker run julia -e '42') 5 | # ... is a "*.jl" file (docker run -v ...:/my/file.jl:ro julia /my/file.jl) 6 | # ... or there are no args 7 | if [ "$#" -eq 0 ] || [ "${1#-}" != "$1" ] || [ "${1%.jl}" != "$1" ]; then 8 | exec julia "$@" 9 | fi 10 | 11 | exec "$@" 12 | -------------------------------------------------------------------------------- /rc/bookworm/docker-entrypoint.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | set -eu 3 | 4 | # first arg is `-e` or `--some-option` (docker run julia -e '42') 5 | # ... is a "*.jl" file (docker run -v ...:/my/file.jl:ro julia /my/file.jl) 6 | # ... or there are no args 7 | if [ "$#" -eq 0 ] || [ "${1#-}" != "$1" ] || [ "${1%.jl}" != "$1" ]; then 8 | exec julia "$@" 9 | fi 10 | 11 | exec "$@" 12 | -------------------------------------------------------------------------------- /rc/trixie/docker-entrypoint.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | set -eu 3 | 4 | # first arg is `-e` or `--some-option` (docker run julia -e '42') 5 | # ... is a "*.jl" file (docker run -v ...:/my/file.jl:ro julia /my/file.jl) 6 | # ... or there are no args 7 | if [ "$#" -eq 0 ] || [ "${1#-}" != "$1" ] || [ "${1%.jl}" != "$1" ]; then 8 | exec julia "$@" 9 | fi 10 | 11 | exec "$@" 12 | -------------------------------------------------------------------------------- /1.10/alpine3.22/docker-entrypoint.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | set -eu 3 | 4 | # first arg is `-e` or `--some-option` (docker run julia -e '42') 5 | # ... is a "*.jl" file (docker run -v ...:/my/file.jl:ro julia /my/file.jl) 6 | # ... or there are no args 7 | if [ "$#" -eq 0 ] || [ "${1#-}" != "$1" ] || [ "${1%.jl}" != "$1" ]; then 8 | exec julia "$@" 9 | fi 10 | 11 | exec "$@" 12 | -------------------------------------------------------------------------------- /1.10/alpine3.23/docker-entrypoint.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | set -eu 3 | 4 | # first arg is `-e` or `--some-option` (docker run julia -e '42') 5 | # ... is a "*.jl" file (docker run -v ...:/my/file.jl:ro julia /my/file.jl) 6 | # ... or there are no args 7 | if [ "$#" -eq 0 ] || [ "${1#-}" != "$1" ] || [ "${1%.jl}" != "$1" ]; then 8 | exec julia "$@" 9 | fi 10 | 11 | exec "$@" 12 | -------------------------------------------------------------------------------- /1.10/bookworm/docker-entrypoint.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | set -eu 3 | 4 | # first arg is `-e` or `--some-option` (docker run julia -e '42') 5 | # ... is a "*.jl" file (docker run -v ...:/my/file.jl:ro julia /my/file.jl) 6 | # ... or there are no args 7 | if [ "$#" -eq 0 ] || [ "${1#-}" != "$1" ] || [ "${1%.jl}" != "$1" ]; then 8 | exec julia "$@" 9 | fi 10 | 11 | exec "$@" 12 | -------------------------------------------------------------------------------- /stable/bookworm/docker-entrypoint.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | set -eu 3 | 4 | # first arg is `-e` or `--some-option` (docker run julia -e '42') 5 | # ... is a "*.jl" file (docker run -v ...:/my/file.jl:ro julia /my/file.jl) 6 | # ... or there are no args 7 | if [ "$#" -eq 0 ] || [ "${1#-}" != "$1" ] || [ "${1%.jl}" != "$1" ]; then 8 | exec julia "$@" 9 | fi 10 | 11 | exec "$@" 12 | -------------------------------------------------------------------------------- /stable/trixie/docker-entrypoint.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | set -eu 3 | 4 | # first arg is `-e` or `--some-option` (docker run julia -e '42') 5 | # ... is a "*.jl" file (docker run -v ...:/my/file.jl:ro julia /my/file.jl) 6 | # ... or there are no args 7 | if [ "$#" -eq 0 ] || [ "${1#-}" != "$1" ] || [ "${1%.jl}" != "$1" ]; then 8 | exec julia "$@" 9 | fi 10 | 11 | exec "$@" 12 | -------------------------------------------------------------------------------- /.github/workflows/verify-templating.yml: -------------------------------------------------------------------------------- 1 | name: Verify Templating 2 | 3 | on: 4 | pull_request: 5 | push: 6 | workflow_dispatch: 7 | 8 | defaults: 9 | run: 10 | shell: 'bash -Eeuo pipefail -x {0}' 11 | 12 | jobs: 13 | apply-templates: 14 | name: Check For Uncomitted Changes 15 | runs-on: ubuntu-latest 16 | steps: 17 | - uses: actions/checkout@v4 18 | - run: ./apply-templates.sh 19 | - run: git diff --exit-code 20 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | Copyright (c) 2014 Docker, Inc. 2 | 3 | Permission is hereby granted, free of charge, to any person obtaining 4 | a copy of this software and associated documentation files (the 5 | "Software"), to deal in the Software without restriction, including 6 | without limitation the rights to use, copy, modify, merge, publish, 7 | distribute, sublicense, and/or sell copies of the Software, and to 8 | permit persons to whom the Software is furnished to do so, subject to 9 | the following conditions: 10 | 11 | The above copyright notice and this permission notice shall be included 12 | in all copies or substantial portions of the Software. 13 | 14 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 15 | EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 16 | MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 17 | IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY 18 | CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, 19 | TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE 20 | SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 21 | -------------------------------------------------------------------------------- /Dockerfile-windows.template: -------------------------------------------------------------------------------- 1 | {{ include "shared" -}} 2 | FROM {{ from(env.variant) }} 3 | 4 | # $ProgressPreference: https://github.com/PowerShell/PowerShell/issues/2138#issuecomment-251261324 5 | SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"] 6 | 7 | ENV JULIA_VERSION {{ .version }} 8 | ENV JULIA_URL {{ .arches["windows-amd64"].url }} 9 | ENV JULIA_SHA256 {{ .arches["windows-amd64"].sha256 }} 10 | 11 | RUN Write-Host ('Downloading {0} ...' -f $env:JULIA_URL); \ 12 | [Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12; \ 13 | Invoke-WebRequest -Uri $env:JULIA_URL -OutFile 'julia.exe'; \ 14 | \ 15 | Write-Host ('Verifying sha256 ({0}) ...' -f $env:JULIA_SHA256); \ 16 | if ((Get-FileHash julia.exe -Algorithm sha256).Hash -ne $env:JULIA_SHA256) { \ 17 | Write-Host 'FAILED!'; \ 18 | exit 1; \ 19 | }; \ 20 | \ 21 | Write-Host 'Installing ...'; \ 22 | Start-Process -Wait -NoNewWindow \ 23 | -FilePath '.\julia.exe' \ 24 | -ArgumentList @( \ 25 | '/SILENT', \ 26 | '/DIR=C:\julia' \ 27 | ); \ 28 | \ 29 | Write-Host 'Removing ...'; \ 30 | Remove-Item julia.exe -Force; \ 31 | \ 32 | Write-Host 'Updating PATH ...'; \ 33 | $env:PATH = 'C:\julia\bin;' + $env:PATH; \ 34 | [Environment]::SetEnvironmentVariable('PATH', $env:PATH, [EnvironmentVariableTarget]::Machine); \ 35 | \ 36 | Write-Host 'Verifying install ("julia --version") ...'; \ 37 | julia --version; \ 38 | \ 39 | Write-Host 'Complete.' 40 | 41 | CMD ["julia"] 42 | -------------------------------------------------------------------------------- /generate-stackbrew-library.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | set -Eeuo pipefail 3 | 4 | self="$(basename "$BASH_SOURCE")" 5 | cd "$(dirname "$(readlink -f "$BASH_SOURCE")")" 6 | 7 | # get the most recent commit which modified any files related to a build context 8 | commit="$(git log -1 --format='format:%H' HEAD -- '[^.]*/**')" 9 | 10 | getArches() { 11 | local repo="$1"; shift 12 | local oiBase="${BASHBREW_LIBRARY:-https://github.com/docker-library/official-images/raw/HEAD/library}/" 13 | 14 | # grab supported architectures for each parent image, except self-referential 15 | jq --raw-output \ 16 | --arg oiBase "$oiBase" \ 17 | --arg repo "$repo" ' 18 | include "shared"; 19 | [ 20 | from(.[].variants[]) 21 | | select(startswith($repo + ":") or index("/") | not) 22 | ] 23 | | unique[] 24 | | $oiBase + . 25 | ' versions.json \ 26 | | xargs -r bashbrew cat --format '{ {{ join ":" .RepoName .TagName | json }}: {{ json .TagEntry.Architectures }} }' \ 27 | | jq --compact-output --slurp 'add' 28 | } 29 | parentsArches="$(getArches 'julia')" 30 | 31 | selfCommit="$(git log -1 --format='format:%H' HEAD -- "$self")" 32 | cat <<-EOH 33 | # this file is generated via https://github.com/docker-library/julia/blob/$selfCommit/$self 34 | 35 | Maintainers: Tianon Gravi (@tianon), 36 | Joseph Ferguson (@yosifkit) 37 | GitRepo: https://github.com/docker-library/julia.git 38 | GitCommit: $commit 39 | EOH 40 | 41 | exec jq \ 42 | --raw-output \ 43 | --argjson parentsArches "$parentsArches" \ 44 | --from-file generate-stackbrew-library.jq \ 45 | versions.json \ 46 | --args -- "$@" 47 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # https://github.com/docker-library/julia 2 | 3 | ## Maintained by: [the Docker Community](https://github.com/docker-library/julia) 4 | 5 | This is the Git repo of the [Docker "Official Image"](https://github.com/docker-library/official-images#what-are-official-images) for [`julia`](https://hub.docker.com/_/julia/) (not to be confused with any official `julia` image provided by `julia` upstream). See [the Docker Hub page](https://hub.docker.com/_/julia/) for the full readme on how to use this Docker image and for information regarding contributing and issues. 6 | 7 | The [full image description on Docker Hub](https://hub.docker.com/_/julia/) is generated/maintained over in [the docker-library/docs repository](https://github.com/docker-library/docs), specifically in [the `julia` directory](https://github.com/docker-library/docs/tree/master/julia). 8 | 9 | ## See a change merged here that doesn't show up on Docker Hub yet? 10 | 11 | For more information about the full official images change lifecycle, see [the "An image's source changed in Git, now what?" FAQ entry](https://github.com/docker-library/faq#an-images-source-changed-in-git-now-what). 12 | 13 | For outstanding `julia` image PRs, check [PRs with the "library/julia" label on the official-images repository](https://github.com/docker-library/official-images/labels/library%2Fjulia). For the current "source of truth" for [`julia`](https://hub.docker.com/_/julia/), see [the `library/julia` file in the official-images repository](https://github.com/docker-library/official-images/blob/master/library/julia). 14 | 15 | 16 | -------------------------------------------------------------------------------- /1.10/windows/servercore-ltsc2022/Dockerfile: -------------------------------------------------------------------------------- 1 | # 2 | # NOTE: THIS DOCKERFILE IS GENERATED VIA "apply-templates.sh" 3 | # 4 | # PLEASE DO NOT EDIT IT DIRECTLY. 5 | # 6 | 7 | FROM mcr.microsoft.com/windows/servercore:ltsc2022 8 | 9 | # $ProgressPreference: https://github.com/PowerShell/PowerShell/issues/2138#issuecomment-251261324 10 | SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"] 11 | 12 | ENV JULIA_VERSION 1.10.10 13 | ENV JULIA_URL https://julialang-s3.julialang.org/bin/winnt/x64/1.10/julia-1.10.10-win64.exe 14 | ENV JULIA_SHA256 c2a9087064a193e8c2219cc03fac2264445bc9ccf626e30acc39ebd5fa7ad09f 15 | 16 | RUN Write-Host ('Downloading {0} ...' -f $env:JULIA_URL); \ 17 | [Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12; \ 18 | Invoke-WebRequest -Uri $env:JULIA_URL -OutFile 'julia.exe'; \ 19 | \ 20 | Write-Host ('Verifying sha256 ({0}) ...' -f $env:JULIA_SHA256); \ 21 | if ((Get-FileHash julia.exe -Algorithm sha256).Hash -ne $env:JULIA_SHA256) { \ 22 | Write-Host 'FAILED!'; \ 23 | exit 1; \ 24 | }; \ 25 | \ 26 | Write-Host 'Installing ...'; \ 27 | Start-Process -Wait -NoNewWindow \ 28 | -FilePath '.\julia.exe' \ 29 | -ArgumentList @( \ 30 | '/SILENT', \ 31 | '/DIR=C:\julia' \ 32 | ); \ 33 | \ 34 | Write-Host 'Removing ...'; \ 35 | Remove-Item julia.exe -Force; \ 36 | \ 37 | Write-Host 'Updating PATH ...'; \ 38 | $env:PATH = 'C:\julia\bin;' + $env:PATH; \ 39 | [Environment]::SetEnvironmentVariable('PATH', $env:PATH, [EnvironmentVariableTarget]::Machine); \ 40 | \ 41 | Write-Host 'Verifying install ("julia --version") ...'; \ 42 | julia --version; \ 43 | \ 44 | Write-Host 'Complete.' 45 | 46 | CMD ["julia"] 47 | -------------------------------------------------------------------------------- /1.10/windows/servercore-ltsc2025/Dockerfile: -------------------------------------------------------------------------------- 1 | # 2 | # NOTE: THIS DOCKERFILE IS GENERATED VIA "apply-templates.sh" 3 | # 4 | # PLEASE DO NOT EDIT IT DIRECTLY. 5 | # 6 | 7 | FROM mcr.microsoft.com/windows/servercore:ltsc2025 8 | 9 | # $ProgressPreference: https://github.com/PowerShell/PowerShell/issues/2138#issuecomment-251261324 10 | SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"] 11 | 12 | ENV JULIA_VERSION 1.10.10 13 | ENV JULIA_URL https://julialang-s3.julialang.org/bin/winnt/x64/1.10/julia-1.10.10-win64.exe 14 | ENV JULIA_SHA256 c2a9087064a193e8c2219cc03fac2264445bc9ccf626e30acc39ebd5fa7ad09f 15 | 16 | RUN Write-Host ('Downloading {0} ...' -f $env:JULIA_URL); \ 17 | [Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12; \ 18 | Invoke-WebRequest -Uri $env:JULIA_URL -OutFile 'julia.exe'; \ 19 | \ 20 | Write-Host ('Verifying sha256 ({0}) ...' -f $env:JULIA_SHA256); \ 21 | if ((Get-FileHash julia.exe -Algorithm sha256).Hash -ne $env:JULIA_SHA256) { \ 22 | Write-Host 'FAILED!'; \ 23 | exit 1; \ 24 | }; \ 25 | \ 26 | Write-Host 'Installing ...'; \ 27 | Start-Process -Wait -NoNewWindow \ 28 | -FilePath '.\julia.exe' \ 29 | -ArgumentList @( \ 30 | '/SILENT', \ 31 | '/DIR=C:\julia' \ 32 | ); \ 33 | \ 34 | Write-Host 'Removing ...'; \ 35 | Remove-Item julia.exe -Force; \ 36 | \ 37 | Write-Host 'Updating PATH ...'; \ 38 | $env:PATH = 'C:\julia\bin;' + $env:PATH; \ 39 | [Environment]::SetEnvironmentVariable('PATH', $env:PATH, [EnvironmentVariableTarget]::Machine); \ 40 | \ 41 | Write-Host 'Verifying install ("julia --version") ...'; \ 42 | julia --version; \ 43 | \ 44 | Write-Host 'Complete.' 45 | 46 | CMD ["julia"] 47 | -------------------------------------------------------------------------------- /stable/windows/servercore-ltsc2022/Dockerfile: -------------------------------------------------------------------------------- 1 | # 2 | # NOTE: THIS DOCKERFILE IS GENERATED VIA "apply-templates.sh" 3 | # 4 | # PLEASE DO NOT EDIT IT DIRECTLY. 5 | # 6 | 7 | FROM mcr.microsoft.com/windows/servercore:ltsc2022 8 | 9 | # $ProgressPreference: https://github.com/PowerShell/PowerShell/issues/2138#issuecomment-251261324 10 | SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"] 11 | 12 | ENV JULIA_VERSION 1.12.2 13 | ENV JULIA_URL https://julialang-s3.julialang.org/bin/winnt/x64/1.12/julia-1.12.2-win64.exe 14 | ENV JULIA_SHA256 b8c6ffd3f760e088820f0f208b799167a02d528df467337852ffcc599eaa8e7e 15 | 16 | RUN Write-Host ('Downloading {0} ...' -f $env:JULIA_URL); \ 17 | [Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12; \ 18 | Invoke-WebRequest -Uri $env:JULIA_URL -OutFile 'julia.exe'; \ 19 | \ 20 | Write-Host ('Verifying sha256 ({0}) ...' -f $env:JULIA_SHA256); \ 21 | if ((Get-FileHash julia.exe -Algorithm sha256).Hash -ne $env:JULIA_SHA256) { \ 22 | Write-Host 'FAILED!'; \ 23 | exit 1; \ 24 | }; \ 25 | \ 26 | Write-Host 'Installing ...'; \ 27 | Start-Process -Wait -NoNewWindow \ 28 | -FilePath '.\julia.exe' \ 29 | -ArgumentList @( \ 30 | '/SILENT', \ 31 | '/DIR=C:\julia' \ 32 | ); \ 33 | \ 34 | Write-Host 'Removing ...'; \ 35 | Remove-Item julia.exe -Force; \ 36 | \ 37 | Write-Host 'Updating PATH ...'; \ 38 | $env:PATH = 'C:\julia\bin;' + $env:PATH; \ 39 | [Environment]::SetEnvironmentVariable('PATH', $env:PATH, [EnvironmentVariableTarget]::Machine); \ 40 | \ 41 | Write-Host 'Verifying install ("julia --version") ...'; \ 42 | julia --version; \ 43 | \ 44 | Write-Host 'Complete.' 45 | 46 | CMD ["julia"] 47 | -------------------------------------------------------------------------------- /stable/windows/servercore-ltsc2025/Dockerfile: -------------------------------------------------------------------------------- 1 | # 2 | # NOTE: THIS DOCKERFILE IS GENERATED VIA "apply-templates.sh" 3 | # 4 | # PLEASE DO NOT EDIT IT DIRECTLY. 5 | # 6 | 7 | FROM mcr.microsoft.com/windows/servercore:ltsc2025 8 | 9 | # $ProgressPreference: https://github.com/PowerShell/PowerShell/issues/2138#issuecomment-251261324 10 | SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"] 11 | 12 | ENV JULIA_VERSION 1.12.2 13 | ENV JULIA_URL https://julialang-s3.julialang.org/bin/winnt/x64/1.12/julia-1.12.2-win64.exe 14 | ENV JULIA_SHA256 b8c6ffd3f760e088820f0f208b799167a02d528df467337852ffcc599eaa8e7e 15 | 16 | RUN Write-Host ('Downloading {0} ...' -f $env:JULIA_URL); \ 17 | [Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12; \ 18 | Invoke-WebRequest -Uri $env:JULIA_URL -OutFile 'julia.exe'; \ 19 | \ 20 | Write-Host ('Verifying sha256 ({0}) ...' -f $env:JULIA_SHA256); \ 21 | if ((Get-FileHash julia.exe -Algorithm sha256).Hash -ne $env:JULIA_SHA256) { \ 22 | Write-Host 'FAILED!'; \ 23 | exit 1; \ 24 | }; \ 25 | \ 26 | Write-Host 'Installing ...'; \ 27 | Start-Process -Wait -NoNewWindow \ 28 | -FilePath '.\julia.exe' \ 29 | -ArgumentList @( \ 30 | '/SILENT', \ 31 | '/DIR=C:\julia' \ 32 | ); \ 33 | \ 34 | Write-Host 'Removing ...'; \ 35 | Remove-Item julia.exe -Force; \ 36 | \ 37 | Write-Host 'Updating PATH ...'; \ 38 | $env:PATH = 'C:\julia\bin;' + $env:PATH; \ 39 | [Environment]::SetEnvironmentVariable('PATH', $env:PATH, [EnvironmentVariableTarget]::Machine); \ 40 | \ 41 | Write-Host 'Verifying install ("julia --version") ...'; \ 42 | julia --version; \ 43 | \ 44 | Write-Host 'Complete.' 45 | 46 | CMD ["julia"] 47 | -------------------------------------------------------------------------------- /apply-templates.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | set -Eeuo pipefail 3 | 4 | [ -f versions.json ] # run "versions.sh" first 5 | 6 | jqt='.jq-template.awk' 7 | if [ -n "${BASHBREW_SCRIPTS:-}" ]; then 8 | jqt="$BASHBREW_SCRIPTS/jq-template.awk" 9 | elif [ "$BASH_SOURCE" -nt "$jqt" ]; then 10 | # https://github.com/docker-library/bashbrew/blob/master/scripts/jq-template.awk 11 | wget -qO "$jqt" 'https://github.com/docker-library/bashbrew/raw/9f6a35772ac863a0241f147c820354e4008edf38/scripts/jq-template.awk' 12 | fi 13 | 14 | if [ "$#" -eq 0 ]; then 15 | versions="$(jq -r 'keys | map(@sh) | join(" ")' versions.json)" 16 | eval "set -- $versions" 17 | fi 18 | 19 | generated_warning() { 20 | cat <<-EOH 21 | # 22 | # NOTE: THIS DOCKERFILE IS GENERATED VIA "apply-templates.sh" 23 | # 24 | # PLEASE DO NOT EDIT IT DIRECTLY. 25 | # 26 | 27 | EOH 28 | } 29 | 30 | for version; do 31 | export version 32 | 33 | rm -rf "$version/" 34 | 35 | if jq -e '.[env.version] | not' versions.json > /dev/null; then 36 | echo "deleting $version ..." 37 | continue 38 | fi 39 | 40 | variants="$(jq -r '.[env.version].variants | map(@sh) | join(" ")' versions.json)" 41 | eval "variants=( $variants )" 42 | 43 | for variant in "${variants[@]}"; do 44 | export variant 45 | 46 | mkdir -p "$version/$variant" 47 | 48 | case "$variant" in 49 | windows/*) 50 | template='Dockerfile-windows.template' 51 | ;; 52 | 53 | *) 54 | template='Dockerfile-linux.template' 55 | cp -a docker-entrypoint.sh "$version/$variant/" 56 | ;; 57 | esac 58 | 59 | echo "processing $version/$variant ..." 60 | 61 | { 62 | generated_warning 63 | gawk -f "$jqt" "$template" 64 | } > "$version/$variant/Dockerfile" 65 | done 66 | done 67 | -------------------------------------------------------------------------------- /rc/windows/servercore-ltsc2022/Dockerfile: -------------------------------------------------------------------------------- 1 | # 2 | # NOTE: THIS DOCKERFILE IS GENERATED VIA "apply-templates.sh" 3 | # 4 | # PLEASE DO NOT EDIT IT DIRECTLY. 5 | # 6 | 7 | FROM mcr.microsoft.com/windows/servercore:ltsc2022 8 | 9 | # $ProgressPreference: https://github.com/PowerShell/PowerShell/issues/2138#issuecomment-251261324 10 | SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"] 11 | 12 | ENV JULIA_VERSION 1.13.0-alpha2 13 | ENV JULIA_URL https://julialang-s3.julialang.org/bin/winnt/x64/1.13/julia-1.13.0-alpha2-win64.exe 14 | ENV JULIA_SHA256 ec84bd651c739436b2ab397f4a156ed269030f277d075031104eecbf6904079a 15 | 16 | RUN Write-Host ('Downloading {0} ...' -f $env:JULIA_URL); \ 17 | [Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12; \ 18 | Invoke-WebRequest -Uri $env:JULIA_URL -OutFile 'julia.exe'; \ 19 | \ 20 | Write-Host ('Verifying sha256 ({0}) ...' -f $env:JULIA_SHA256); \ 21 | if ((Get-FileHash julia.exe -Algorithm sha256).Hash -ne $env:JULIA_SHA256) { \ 22 | Write-Host 'FAILED!'; \ 23 | exit 1; \ 24 | }; \ 25 | \ 26 | Write-Host 'Installing ...'; \ 27 | Start-Process -Wait -NoNewWindow \ 28 | -FilePath '.\julia.exe' \ 29 | -ArgumentList @( \ 30 | '/SILENT', \ 31 | '/DIR=C:\julia' \ 32 | ); \ 33 | \ 34 | Write-Host 'Removing ...'; \ 35 | Remove-Item julia.exe -Force; \ 36 | \ 37 | Write-Host 'Updating PATH ...'; \ 38 | $env:PATH = 'C:\julia\bin;' + $env:PATH; \ 39 | [Environment]::SetEnvironmentVariable('PATH', $env:PATH, [EnvironmentVariableTarget]::Machine); \ 40 | \ 41 | Write-Host 'Verifying install ("julia --version") ...'; \ 42 | julia --version; \ 43 | \ 44 | Write-Host 'Complete.' 45 | 46 | CMD ["julia"] 47 | -------------------------------------------------------------------------------- /rc/windows/servercore-ltsc2025/Dockerfile: -------------------------------------------------------------------------------- 1 | # 2 | # NOTE: THIS DOCKERFILE IS GENERATED VIA "apply-templates.sh" 3 | # 4 | # PLEASE DO NOT EDIT IT DIRECTLY. 5 | # 6 | 7 | FROM mcr.microsoft.com/windows/servercore:ltsc2025 8 | 9 | # $ProgressPreference: https://github.com/PowerShell/PowerShell/issues/2138#issuecomment-251261324 10 | SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"] 11 | 12 | ENV JULIA_VERSION 1.13.0-alpha2 13 | ENV JULIA_URL https://julialang-s3.julialang.org/bin/winnt/x64/1.13/julia-1.13.0-alpha2-win64.exe 14 | ENV JULIA_SHA256 ec84bd651c739436b2ab397f4a156ed269030f277d075031104eecbf6904079a 15 | 16 | RUN Write-Host ('Downloading {0} ...' -f $env:JULIA_URL); \ 17 | [Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12; \ 18 | Invoke-WebRequest -Uri $env:JULIA_URL -OutFile 'julia.exe'; \ 19 | \ 20 | Write-Host ('Verifying sha256 ({0}) ...' -f $env:JULIA_SHA256); \ 21 | if ((Get-FileHash julia.exe -Algorithm sha256).Hash -ne $env:JULIA_SHA256) { \ 22 | Write-Host 'FAILED!'; \ 23 | exit 1; \ 24 | }; \ 25 | \ 26 | Write-Host 'Installing ...'; \ 27 | Start-Process -Wait -NoNewWindow \ 28 | -FilePath '.\julia.exe' \ 29 | -ArgumentList @( \ 30 | '/SILENT', \ 31 | '/DIR=C:\julia' \ 32 | ); \ 33 | \ 34 | Write-Host 'Removing ...'; \ 35 | Remove-Item julia.exe -Force; \ 36 | \ 37 | Write-Host 'Updating PATH ...'; \ 38 | $env:PATH = 'C:\julia\bin;' + $env:PATH; \ 39 | [Environment]::SetEnvironmentVariable('PATH', $env:PATH, [EnvironmentVariableTarget]::Machine); \ 40 | \ 41 | Write-Host 'Verifying install ("julia --version") ...'; \ 42 | julia --version; \ 43 | \ 44 | Write-Host 'Complete.' 45 | 46 | CMD ["julia"] 47 | -------------------------------------------------------------------------------- /.github/workflows/ci.yml: -------------------------------------------------------------------------------- 1 | name: GitHub CI 2 | 3 | on: 4 | pull_request: 5 | push: 6 | schedule: 7 | - cron: 0 0 * * 0 8 | 9 | defaults: 10 | run: 11 | shell: 'bash -Eeuo pipefail -x {0}' 12 | 13 | jobs: 14 | 15 | generate-jobs: 16 | name: Generate Jobs 17 | runs-on: ubuntu-latest 18 | outputs: 19 | strategy: ${{ steps.generate-jobs.outputs.strategy }} 20 | steps: 21 | - uses: actions/checkout@v4 22 | - uses: docker-library/bashbrew@HEAD 23 | - id: generate-jobs 24 | name: Generate Jobs 25 | run: | 26 | strategy="$("$BASHBREW_SCRIPTS/github-actions/generate.sh")" 27 | strategy="$("$BASHBREW_SCRIPTS/github-actions/munge-i386.sh" -c <<<"$strategy")" 28 | strategy="$(jq -c <<<"$strategy" '.matrix.include = [ .matrix.include[] | select(.name | test("alpine.*i386") | not) ]')" # Alpine releases do not exist for i386 29 | echo "strategy=$strategy" >> "$GITHUB_OUTPUT" 30 | jq . <<<"$strategy" # sanity check / debugging aid 31 | 32 | test: 33 | needs: generate-jobs 34 | strategy: ${{ fromJson(needs.generate-jobs.outputs.strategy) }} 35 | name: ${{ matrix.name }} 36 | runs-on: ${{ matrix.os }} 37 | steps: 38 | - uses: actions/checkout@v4 39 | - name: Prepare Environment 40 | run: ${{ matrix.runs.prepare }} 41 | - name: Pull Dependencies 42 | run: ${{ matrix.runs.pull }} 43 | - name: Build ${{ matrix.name }} 44 | run: ${{ matrix.runs.build }} 45 | - name: History ${{ matrix.name }} 46 | run: ${{ matrix.runs.history }} 47 | - name: Test ${{ matrix.name }} 48 | run: ${{ matrix.runs.test }} 49 | - name: '"docker images"' 50 | run: ${{ matrix.runs.images }} 51 | -------------------------------------------------------------------------------- /1.10/alpine3.22/Dockerfile: -------------------------------------------------------------------------------- 1 | # 2 | # NOTE: THIS DOCKERFILE IS GENERATED VIA "apply-templates.sh" 3 | # 4 | # PLEASE DO NOT EDIT IT DIRECTLY. 5 | # 6 | 7 | FROM alpine:3.22 8 | 9 | ENV JULIA_PATH /usr/local/julia 10 | ENV PATH $JULIA_PATH/bin:$PATH 11 | 12 | # https://julialang.org/juliareleases.asc 13 | # Julia (Binary signing key) 14 | ENV JULIA_GPG 3673DF529D9049477F76B37566E3C7DC03D6E495 15 | 16 | # https://julialang.org/downloads/ 17 | ENV JULIA_VERSION 1.10.10 18 | 19 | RUN set -eux; \ 20 | \ 21 | apk add --no-cache --virtual .fetch-deps gnupg; \ 22 | \ 23 | # https://julialang.org/downloads/#julia-command-line-version 24 | # https://julialang-s3.julialang.org/bin/checksums/julia-1.10.10.sha256 25 | arch="$(apk --print-arch)"; \ 26 | case "$arch" in \ 27 | 'x86_64') \ 28 | url='https://julialang-s3.julialang.org/bin/musl/x64/1.10/julia-1.10.10-musl-x86_64.tar.gz'; \ 29 | sha256='2d109f3f96f2be8ea45a0676f506642c20d972aeb3d526e8fa10ed49c0d6c786'; \ 30 | ;; \ 31 | *) \ 32 | echo >&2 "error: current architecture ($arch) does not have a corresponding Julia binary release"; \ 33 | exit 1; \ 34 | ;; \ 35 | esac; \ 36 | \ 37 | wget -O julia.tar.gz.asc "$url.asc"; \ 38 | wget -O julia.tar.gz "$url"; \ 39 | \ 40 | echo "$sha256 *julia.tar.gz" | sha256sum -w -c -; \ 41 | \ 42 | export GNUPGHOME="$(mktemp -d)"; \ 43 | gpg --batch --keyserver keyserver.ubuntu.com --recv-keys "$JULIA_GPG"; \ 44 | gpg --batch --verify julia.tar.gz.asc julia.tar.gz; \ 45 | gpgconf --kill all; \ 46 | rm -rf "$GNUPGHOME" julia.tar.gz.asc; \ 47 | \ 48 | mkdir "$JULIA_PATH"; \ 49 | tar -xzf julia.tar.gz -C "$JULIA_PATH" --strip-components 1; \ 50 | rm julia.tar.gz; \ 51 | \ 52 | apk del --no-network .fetch-deps; \ 53 | \ 54 | # smoke test 55 | julia --version 56 | 57 | COPY docker-entrypoint.sh /usr/local/bin/ 58 | ENTRYPOINT ["docker-entrypoint.sh"] 59 | CMD ["julia"] 60 | -------------------------------------------------------------------------------- /1.10/alpine3.23/Dockerfile: -------------------------------------------------------------------------------- 1 | # 2 | # NOTE: THIS DOCKERFILE IS GENERATED VIA "apply-templates.sh" 3 | # 4 | # PLEASE DO NOT EDIT IT DIRECTLY. 5 | # 6 | 7 | FROM alpine:3.23 8 | 9 | ENV JULIA_PATH /usr/local/julia 10 | ENV PATH $JULIA_PATH/bin:$PATH 11 | 12 | # https://julialang.org/juliareleases.asc 13 | # Julia (Binary signing key) 14 | ENV JULIA_GPG 3673DF529D9049477F76B37566E3C7DC03D6E495 15 | 16 | # https://julialang.org/downloads/ 17 | ENV JULIA_VERSION 1.10.10 18 | 19 | RUN set -eux; \ 20 | \ 21 | apk add --no-cache --virtual .fetch-deps gnupg; \ 22 | \ 23 | # https://julialang.org/downloads/#julia-command-line-version 24 | # https://julialang-s3.julialang.org/bin/checksums/julia-1.10.10.sha256 25 | arch="$(apk --print-arch)"; \ 26 | case "$arch" in \ 27 | 'x86_64') \ 28 | url='https://julialang-s3.julialang.org/bin/musl/x64/1.10/julia-1.10.10-musl-x86_64.tar.gz'; \ 29 | sha256='2d109f3f96f2be8ea45a0676f506642c20d972aeb3d526e8fa10ed49c0d6c786'; \ 30 | ;; \ 31 | *) \ 32 | echo >&2 "error: current architecture ($arch) does not have a corresponding Julia binary release"; \ 33 | exit 1; \ 34 | ;; \ 35 | esac; \ 36 | \ 37 | wget -O julia.tar.gz.asc "$url.asc"; \ 38 | wget -O julia.tar.gz "$url"; \ 39 | \ 40 | echo "$sha256 *julia.tar.gz" | sha256sum -w -c -; \ 41 | \ 42 | export GNUPGHOME="$(mktemp -d)"; \ 43 | gpg --batch --keyserver keyserver.ubuntu.com --recv-keys "$JULIA_GPG"; \ 44 | gpg --batch --verify julia.tar.gz.asc julia.tar.gz; \ 45 | gpgconf --kill all; \ 46 | rm -rf "$GNUPGHOME" julia.tar.gz.asc; \ 47 | \ 48 | mkdir "$JULIA_PATH"; \ 49 | tar -xzf julia.tar.gz -C "$JULIA_PATH" --strip-components 1; \ 50 | rm julia.tar.gz; \ 51 | \ 52 | apk del --no-network .fetch-deps; \ 53 | \ 54 | # smoke test 55 | julia --version 56 | 57 | COPY docker-entrypoint.sh /usr/local/bin/ 58 | ENTRYPOINT ["docker-entrypoint.sh"] 59 | CMD ["julia"] 60 | -------------------------------------------------------------------------------- /stable/trixie/Dockerfile: -------------------------------------------------------------------------------- 1 | # 2 | # NOTE: THIS DOCKERFILE IS GENERATED VIA "apply-templates.sh" 3 | # 4 | # PLEASE DO NOT EDIT IT DIRECTLY. 5 | # 6 | 7 | FROM debian:trixie-slim 8 | 9 | RUN set -eux; \ 10 | apt-get update; \ 11 | apt-get install -y --no-install-recommends \ 12 | ca-certificates \ 13 | # ERROR: no download agent available; install curl, wget, or fetch 14 | curl \ 15 | ; \ 16 | rm -rf /var/lib/apt/lists/* 17 | 18 | ENV JULIA_PATH /usr/local/julia 19 | ENV PATH $JULIA_PATH/bin:$PATH 20 | 21 | # https://julialang.org/juliareleases.asc 22 | # Julia (Binary signing key) 23 | ENV JULIA_GPG 3673DF529D9049477F76B37566E3C7DC03D6E495 24 | 25 | # https://julialang.org/downloads/ 26 | ENV JULIA_VERSION 1.12.2 27 | 28 | RUN set -eux; \ 29 | \ 30 | savedAptMark="$(apt-mark showmanual)"; \ 31 | apt-get update; \ 32 | apt-get install -y --no-install-recommends \ 33 | gnupg \ 34 | ; \ 35 | rm -rf /var/lib/apt/lists/*; \ 36 | \ 37 | # https://julialang.org/downloads/#julia-command-line-version 38 | # https://julialang-s3.julialang.org/bin/checksums/julia-1.12.2.sha256 39 | arch="$(dpkg --print-architecture)"; \ 40 | case "$arch" in \ 41 | 'amd64') \ 42 | url='https://julialang-s3.julialang.org/bin/linux/x64/1.12/julia-1.12.2-linux-x86_64.tar.gz'; \ 43 | sha256='a6d0c39ea57303ebcffa7a8d453429b86eb271e150c7cb0f5958fe65909b493a'; \ 44 | ;; \ 45 | 'i386') \ 46 | url='https://julialang-s3.julialang.org/bin/linux/x86/1.12/julia-1.12.2-linux-i686.tar.gz'; \ 47 | sha256='e7492e2454ecfd03f4da6fd30fb60391d184128bf683c96d1ea6f13cd35a20c8'; \ 48 | ;; \ 49 | 'arm64') \ 50 | url='https://julialang-s3.julialang.org/bin/linux/aarch64/1.12/julia-1.12.2-linux-aarch64.tar.gz'; \ 51 | sha256='0383a2ce378b64356269f6f15e612f344523f507a9753f71a0b64ca02092445b'; \ 52 | ;; \ 53 | *) \ 54 | echo >&2 "error: current architecture ($arch) does not have a corresponding Julia binary release"; \ 55 | exit 1; \ 56 | ;; \ 57 | esac; \ 58 | \ 59 | curl -fL -o julia.tar.gz.asc "$url.asc"; \ 60 | curl -fL -o julia.tar.gz "$url"; \ 61 | \ 62 | echo "$sha256 *julia.tar.gz" | sha256sum --strict --check -; \ 63 | \ 64 | export GNUPGHOME="$(mktemp -d)"; \ 65 | gpg --batch --keyserver keyserver.ubuntu.com --recv-keys "$JULIA_GPG"; \ 66 | gpg --batch --verify julia.tar.gz.asc julia.tar.gz; \ 67 | gpgconf --kill all; \ 68 | rm -rf "$GNUPGHOME" julia.tar.gz.asc; \ 69 | \ 70 | mkdir "$JULIA_PATH"; \ 71 | tar -xzf julia.tar.gz -C "$JULIA_PATH" --strip-components 1; \ 72 | rm julia.tar.gz; \ 73 | \ 74 | apt-mark auto '.*' > /dev/null; \ 75 | [ -z "$savedAptMark" ] || apt-mark manual $savedAptMark; \ 76 | apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false; \ 77 | \ 78 | # smoke test 79 | julia --version 80 | 81 | COPY docker-entrypoint.sh /usr/local/bin/ 82 | ENTRYPOINT ["docker-entrypoint.sh"] 83 | CMD ["julia"] 84 | -------------------------------------------------------------------------------- /stable/bookworm/Dockerfile: -------------------------------------------------------------------------------- 1 | # 2 | # NOTE: THIS DOCKERFILE IS GENERATED VIA "apply-templates.sh" 3 | # 4 | # PLEASE DO NOT EDIT IT DIRECTLY. 5 | # 6 | 7 | FROM debian:bookworm-slim 8 | 9 | RUN set -eux; \ 10 | apt-get update; \ 11 | apt-get install -y --no-install-recommends \ 12 | ca-certificates \ 13 | # ERROR: no download agent available; install curl, wget, or fetch 14 | curl \ 15 | ; \ 16 | rm -rf /var/lib/apt/lists/* 17 | 18 | ENV JULIA_PATH /usr/local/julia 19 | ENV PATH $JULIA_PATH/bin:$PATH 20 | 21 | # https://julialang.org/juliareleases.asc 22 | # Julia (Binary signing key) 23 | ENV JULIA_GPG 3673DF529D9049477F76B37566E3C7DC03D6E495 24 | 25 | # https://julialang.org/downloads/ 26 | ENV JULIA_VERSION 1.12.2 27 | 28 | RUN set -eux; \ 29 | \ 30 | savedAptMark="$(apt-mark showmanual)"; \ 31 | apt-get update; \ 32 | apt-get install -y --no-install-recommends \ 33 | gnupg \ 34 | ; \ 35 | rm -rf /var/lib/apt/lists/*; \ 36 | \ 37 | # https://julialang.org/downloads/#julia-command-line-version 38 | # https://julialang-s3.julialang.org/bin/checksums/julia-1.12.2.sha256 39 | arch="$(dpkg --print-architecture)"; \ 40 | case "$arch" in \ 41 | 'amd64') \ 42 | url='https://julialang-s3.julialang.org/bin/linux/x64/1.12/julia-1.12.2-linux-x86_64.tar.gz'; \ 43 | sha256='a6d0c39ea57303ebcffa7a8d453429b86eb271e150c7cb0f5958fe65909b493a'; \ 44 | ;; \ 45 | 'i386') \ 46 | url='https://julialang-s3.julialang.org/bin/linux/x86/1.12/julia-1.12.2-linux-i686.tar.gz'; \ 47 | sha256='e7492e2454ecfd03f4da6fd30fb60391d184128bf683c96d1ea6f13cd35a20c8'; \ 48 | ;; \ 49 | 'arm64') \ 50 | url='https://julialang-s3.julialang.org/bin/linux/aarch64/1.12/julia-1.12.2-linux-aarch64.tar.gz'; \ 51 | sha256='0383a2ce378b64356269f6f15e612f344523f507a9753f71a0b64ca02092445b'; \ 52 | ;; \ 53 | *) \ 54 | echo >&2 "error: current architecture ($arch) does not have a corresponding Julia binary release"; \ 55 | exit 1; \ 56 | ;; \ 57 | esac; \ 58 | \ 59 | curl -fL -o julia.tar.gz.asc "$url.asc"; \ 60 | curl -fL -o julia.tar.gz "$url"; \ 61 | \ 62 | echo "$sha256 *julia.tar.gz" | sha256sum --strict --check -; \ 63 | \ 64 | export GNUPGHOME="$(mktemp -d)"; \ 65 | gpg --batch --keyserver keyserver.ubuntu.com --recv-keys "$JULIA_GPG"; \ 66 | gpg --batch --verify julia.tar.gz.asc julia.tar.gz; \ 67 | gpgconf --kill all; \ 68 | rm -rf "$GNUPGHOME" julia.tar.gz.asc; \ 69 | \ 70 | mkdir "$JULIA_PATH"; \ 71 | tar -xzf julia.tar.gz -C "$JULIA_PATH" --strip-components 1; \ 72 | rm julia.tar.gz; \ 73 | \ 74 | apt-mark auto '.*' > /dev/null; \ 75 | [ -z "$savedAptMark" ] || apt-mark manual $savedAptMark; \ 76 | apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false; \ 77 | \ 78 | # smoke test 79 | julia --version 80 | 81 | COPY docker-entrypoint.sh /usr/local/bin/ 82 | ENTRYPOINT ["docker-entrypoint.sh"] 83 | CMD ["julia"] 84 | -------------------------------------------------------------------------------- /rc/trixie/Dockerfile: -------------------------------------------------------------------------------- 1 | # 2 | # NOTE: THIS DOCKERFILE IS GENERATED VIA "apply-templates.sh" 3 | # 4 | # PLEASE DO NOT EDIT IT DIRECTLY. 5 | # 6 | 7 | FROM debian:trixie-slim 8 | 9 | RUN set -eux; \ 10 | apt-get update; \ 11 | apt-get install -y --no-install-recommends \ 12 | ca-certificates \ 13 | # ERROR: no download agent available; install curl, wget, or fetch 14 | curl \ 15 | ; \ 16 | rm -rf /var/lib/apt/lists/* 17 | 18 | ENV JULIA_PATH /usr/local/julia 19 | ENV PATH $JULIA_PATH/bin:$PATH 20 | 21 | # https://julialang.org/juliareleases.asc 22 | # Julia (Binary signing key) 23 | ENV JULIA_GPG 3673DF529D9049477F76B37566E3C7DC03D6E495 24 | 25 | # https://julialang.org/downloads/ 26 | ENV JULIA_VERSION 1.13.0-alpha2 27 | 28 | RUN set -eux; \ 29 | \ 30 | savedAptMark="$(apt-mark showmanual)"; \ 31 | apt-get update; \ 32 | apt-get install -y --no-install-recommends \ 33 | gnupg \ 34 | ; \ 35 | rm -rf /var/lib/apt/lists/*; \ 36 | \ 37 | # https://julialang.org/downloads/#julia-command-line-version 38 | # https://julialang-s3.julialang.org/bin/checksums/julia-1.13.0-alpha2.sha256 39 | arch="$(dpkg --print-architecture)"; \ 40 | case "$arch" in \ 41 | 'amd64') \ 42 | url='https://julialang-s3.julialang.org/bin/linux/x64/1.13/julia-1.13.0-alpha2-linux-x86_64.tar.gz'; \ 43 | sha256='987aa3aad11e0b5c078dfdee7f8d54eeabdc10bcddd245bda18e28ab4de6119d'; \ 44 | ;; \ 45 | 'i386') \ 46 | url='https://julialang-s3.julialang.org/bin/linux/x86/1.13/julia-1.13.0-alpha2-linux-i686.tar.gz'; \ 47 | sha256='15b15af06b603efa0523e2f1b19cacaefcddda13595906c276ddec0b3194c0b2'; \ 48 | ;; \ 49 | 'arm64') \ 50 | url='https://julialang-s3.julialang.org/bin/linux/aarch64/1.13/julia-1.13.0-alpha2-linux-aarch64.tar.gz'; \ 51 | sha256='c558a08f69d1984096d0bac825148cba2dd6b2eea3c5a3d8a5def2cd718af196'; \ 52 | ;; \ 53 | *) \ 54 | echo >&2 "error: current architecture ($arch) does not have a corresponding Julia binary release"; \ 55 | exit 1; \ 56 | ;; \ 57 | esac; \ 58 | \ 59 | curl -fL -o julia.tar.gz.asc "$url.asc"; \ 60 | curl -fL -o julia.tar.gz "$url"; \ 61 | \ 62 | echo "$sha256 *julia.tar.gz" | sha256sum --strict --check -; \ 63 | \ 64 | export GNUPGHOME="$(mktemp -d)"; \ 65 | gpg --batch --keyserver keyserver.ubuntu.com --recv-keys "$JULIA_GPG"; \ 66 | gpg --batch --verify julia.tar.gz.asc julia.tar.gz; \ 67 | gpgconf --kill all; \ 68 | rm -rf "$GNUPGHOME" julia.tar.gz.asc; \ 69 | \ 70 | mkdir "$JULIA_PATH"; \ 71 | tar -xzf julia.tar.gz -C "$JULIA_PATH" --strip-components 1; \ 72 | rm julia.tar.gz; \ 73 | \ 74 | apt-mark auto '.*' > /dev/null; \ 75 | [ -z "$savedAptMark" ] || apt-mark manual $savedAptMark; \ 76 | apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false; \ 77 | \ 78 | # smoke test 79 | julia --version 80 | 81 | COPY docker-entrypoint.sh /usr/local/bin/ 82 | ENTRYPOINT ["docker-entrypoint.sh"] 83 | CMD ["julia"] 84 | -------------------------------------------------------------------------------- /rc/bookworm/Dockerfile: -------------------------------------------------------------------------------- 1 | # 2 | # NOTE: THIS DOCKERFILE IS GENERATED VIA "apply-templates.sh" 3 | # 4 | # PLEASE DO NOT EDIT IT DIRECTLY. 5 | # 6 | 7 | FROM debian:bookworm-slim 8 | 9 | RUN set -eux; \ 10 | apt-get update; \ 11 | apt-get install -y --no-install-recommends \ 12 | ca-certificates \ 13 | # ERROR: no download agent available; install curl, wget, or fetch 14 | curl \ 15 | ; \ 16 | rm -rf /var/lib/apt/lists/* 17 | 18 | ENV JULIA_PATH /usr/local/julia 19 | ENV PATH $JULIA_PATH/bin:$PATH 20 | 21 | # https://julialang.org/juliareleases.asc 22 | # Julia (Binary signing key) 23 | ENV JULIA_GPG 3673DF529D9049477F76B37566E3C7DC03D6E495 24 | 25 | # https://julialang.org/downloads/ 26 | ENV JULIA_VERSION 1.13.0-alpha2 27 | 28 | RUN set -eux; \ 29 | \ 30 | savedAptMark="$(apt-mark showmanual)"; \ 31 | apt-get update; \ 32 | apt-get install -y --no-install-recommends \ 33 | gnupg \ 34 | ; \ 35 | rm -rf /var/lib/apt/lists/*; \ 36 | \ 37 | # https://julialang.org/downloads/#julia-command-line-version 38 | # https://julialang-s3.julialang.org/bin/checksums/julia-1.13.0-alpha2.sha256 39 | arch="$(dpkg --print-architecture)"; \ 40 | case "$arch" in \ 41 | 'amd64') \ 42 | url='https://julialang-s3.julialang.org/bin/linux/x64/1.13/julia-1.13.0-alpha2-linux-x86_64.tar.gz'; \ 43 | sha256='987aa3aad11e0b5c078dfdee7f8d54eeabdc10bcddd245bda18e28ab4de6119d'; \ 44 | ;; \ 45 | 'i386') \ 46 | url='https://julialang-s3.julialang.org/bin/linux/x86/1.13/julia-1.13.0-alpha2-linux-i686.tar.gz'; \ 47 | sha256='15b15af06b603efa0523e2f1b19cacaefcddda13595906c276ddec0b3194c0b2'; \ 48 | ;; \ 49 | 'arm64') \ 50 | url='https://julialang-s3.julialang.org/bin/linux/aarch64/1.13/julia-1.13.0-alpha2-linux-aarch64.tar.gz'; \ 51 | sha256='c558a08f69d1984096d0bac825148cba2dd6b2eea3c5a3d8a5def2cd718af196'; \ 52 | ;; \ 53 | *) \ 54 | echo >&2 "error: current architecture ($arch) does not have a corresponding Julia binary release"; \ 55 | exit 1; \ 56 | ;; \ 57 | esac; \ 58 | \ 59 | curl -fL -o julia.tar.gz.asc "$url.asc"; \ 60 | curl -fL -o julia.tar.gz "$url"; \ 61 | \ 62 | echo "$sha256 *julia.tar.gz" | sha256sum --strict --check -; \ 63 | \ 64 | export GNUPGHOME="$(mktemp -d)"; \ 65 | gpg --batch --keyserver keyserver.ubuntu.com --recv-keys "$JULIA_GPG"; \ 66 | gpg --batch --verify julia.tar.gz.asc julia.tar.gz; \ 67 | gpgconf --kill all; \ 68 | rm -rf "$GNUPGHOME" julia.tar.gz.asc; \ 69 | \ 70 | mkdir "$JULIA_PATH"; \ 71 | tar -xzf julia.tar.gz -C "$JULIA_PATH" --strip-components 1; \ 72 | rm julia.tar.gz; \ 73 | \ 74 | apt-mark auto '.*' > /dev/null; \ 75 | [ -z "$savedAptMark" ] || apt-mark manual $savedAptMark; \ 76 | apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false; \ 77 | \ 78 | # smoke test 79 | julia --version 80 | 81 | COPY docker-entrypoint.sh /usr/local/bin/ 82 | ENTRYPOINT ["docker-entrypoint.sh"] 83 | CMD ["julia"] 84 | -------------------------------------------------------------------------------- /1.10/trixie/Dockerfile: -------------------------------------------------------------------------------- 1 | # 2 | # NOTE: THIS DOCKERFILE IS GENERATED VIA "apply-templates.sh" 3 | # 4 | # PLEASE DO NOT EDIT IT DIRECTLY. 5 | # 6 | 7 | FROM debian:trixie-slim 8 | 9 | RUN set -eux; \ 10 | apt-get update; \ 11 | apt-get install -y --no-install-recommends \ 12 | ca-certificates \ 13 | # ERROR: no download agent available; install curl, wget, or fetch 14 | curl \ 15 | ; \ 16 | rm -rf /var/lib/apt/lists/* 17 | 18 | ENV JULIA_PATH /usr/local/julia 19 | ENV PATH $JULIA_PATH/bin:$PATH 20 | 21 | # https://julialang.org/juliareleases.asc 22 | # Julia (Binary signing key) 23 | ENV JULIA_GPG 3673DF529D9049477F76B37566E3C7DC03D6E495 24 | 25 | # https://julialang.org/downloads/ 26 | ENV JULIA_VERSION 1.10.10 27 | 28 | RUN set -eux; \ 29 | \ 30 | savedAptMark="$(apt-mark showmanual)"; \ 31 | apt-get update; \ 32 | apt-get install -y --no-install-recommends \ 33 | gnupg \ 34 | ; \ 35 | rm -rf /var/lib/apt/lists/*; \ 36 | \ 37 | # https://julialang.org/downloads/#julia-command-line-version 38 | # https://julialang-s3.julialang.org/bin/checksums/julia-1.10.10.sha256 39 | arch="$(dpkg --print-architecture)"; \ 40 | case "$arch" in \ 41 | 'amd64') \ 42 | url='https://julialang-s3.julialang.org/bin/linux/x64/1.10/julia-1.10.10-linux-x86_64.tar.gz'; \ 43 | sha256='6a78a03a71c7ab792e8673dc5cedb918e037f081ceb58b50971dfb7c64c5bf81'; \ 44 | ;; \ 45 | 'i386') \ 46 | url='https://julialang-s3.julialang.org/bin/linux/x86/1.10/julia-1.10.10-linux-i686.tar.gz'; \ 47 | sha256='32186f38e7f6c7830375da1d1327bec3b187d93e3f0ff007829f20f578fd8c35'; \ 48 | ;; \ 49 | 'arm64') \ 50 | url='https://julialang-s3.julialang.org/bin/linux/aarch64/1.10/julia-1.10.10-linux-aarch64.tar.gz'; \ 51 | sha256='a4b157ed68da10471ea86acc05a0ab61c1a6931ee592a9b236be227d72da50ff'; \ 52 | ;; \ 53 | 'ppc64el') \ 54 | url='https://julialang-s3.julialang.org/bin/linux/ppc64le/1.10/julia-1.10.10-linux-ppc64le.tar.gz'; \ 55 | sha256='f47516c511f100670cad72f3c7a1d95d2c20862f1aa14b1162b0b90424167f16'; \ 56 | ;; \ 57 | *) \ 58 | echo >&2 "error: current architecture ($arch) does not have a corresponding Julia binary release"; \ 59 | exit 1; \ 60 | ;; \ 61 | esac; \ 62 | \ 63 | curl -fL -o julia.tar.gz.asc "$url.asc"; \ 64 | curl -fL -o julia.tar.gz "$url"; \ 65 | \ 66 | echo "$sha256 *julia.tar.gz" | sha256sum --strict --check -; \ 67 | \ 68 | export GNUPGHOME="$(mktemp -d)"; \ 69 | gpg --batch --keyserver keyserver.ubuntu.com --recv-keys "$JULIA_GPG"; \ 70 | gpg --batch --verify julia.tar.gz.asc julia.tar.gz; \ 71 | gpgconf --kill all; \ 72 | rm -rf "$GNUPGHOME" julia.tar.gz.asc; \ 73 | \ 74 | mkdir "$JULIA_PATH"; \ 75 | tar -xzf julia.tar.gz -C "$JULIA_PATH" --strip-components 1; \ 76 | rm julia.tar.gz; \ 77 | \ 78 | apt-mark auto '.*' > /dev/null; \ 79 | [ -z "$savedAptMark" ] || apt-mark manual $savedAptMark; \ 80 | apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false; \ 81 | \ 82 | # smoke test 83 | julia --version 84 | 85 | COPY docker-entrypoint.sh /usr/local/bin/ 86 | ENTRYPOINT ["docker-entrypoint.sh"] 87 | CMD ["julia"] 88 | -------------------------------------------------------------------------------- /1.10/bookworm/Dockerfile: -------------------------------------------------------------------------------- 1 | # 2 | # NOTE: THIS DOCKERFILE IS GENERATED VIA "apply-templates.sh" 3 | # 4 | # PLEASE DO NOT EDIT IT DIRECTLY. 5 | # 6 | 7 | FROM debian:bookworm-slim 8 | 9 | RUN set -eux; \ 10 | apt-get update; \ 11 | apt-get install -y --no-install-recommends \ 12 | ca-certificates \ 13 | # ERROR: no download agent available; install curl, wget, or fetch 14 | curl \ 15 | ; \ 16 | rm -rf /var/lib/apt/lists/* 17 | 18 | ENV JULIA_PATH /usr/local/julia 19 | ENV PATH $JULIA_PATH/bin:$PATH 20 | 21 | # https://julialang.org/juliareleases.asc 22 | # Julia (Binary signing key) 23 | ENV JULIA_GPG 3673DF529D9049477F76B37566E3C7DC03D6E495 24 | 25 | # https://julialang.org/downloads/ 26 | ENV JULIA_VERSION 1.10.10 27 | 28 | RUN set -eux; \ 29 | \ 30 | savedAptMark="$(apt-mark showmanual)"; \ 31 | apt-get update; \ 32 | apt-get install -y --no-install-recommends \ 33 | gnupg \ 34 | ; \ 35 | rm -rf /var/lib/apt/lists/*; \ 36 | \ 37 | # https://julialang.org/downloads/#julia-command-line-version 38 | # https://julialang-s3.julialang.org/bin/checksums/julia-1.10.10.sha256 39 | arch="$(dpkg --print-architecture)"; \ 40 | case "$arch" in \ 41 | 'amd64') \ 42 | url='https://julialang-s3.julialang.org/bin/linux/x64/1.10/julia-1.10.10-linux-x86_64.tar.gz'; \ 43 | sha256='6a78a03a71c7ab792e8673dc5cedb918e037f081ceb58b50971dfb7c64c5bf81'; \ 44 | ;; \ 45 | 'i386') \ 46 | url='https://julialang-s3.julialang.org/bin/linux/x86/1.10/julia-1.10.10-linux-i686.tar.gz'; \ 47 | sha256='32186f38e7f6c7830375da1d1327bec3b187d93e3f0ff007829f20f578fd8c35'; \ 48 | ;; \ 49 | 'arm64') \ 50 | url='https://julialang-s3.julialang.org/bin/linux/aarch64/1.10/julia-1.10.10-linux-aarch64.tar.gz'; \ 51 | sha256='a4b157ed68da10471ea86acc05a0ab61c1a6931ee592a9b236be227d72da50ff'; \ 52 | ;; \ 53 | 'ppc64el') \ 54 | url='https://julialang-s3.julialang.org/bin/linux/ppc64le/1.10/julia-1.10.10-linux-ppc64le.tar.gz'; \ 55 | sha256='f47516c511f100670cad72f3c7a1d95d2c20862f1aa14b1162b0b90424167f16'; \ 56 | ;; \ 57 | *) \ 58 | echo >&2 "error: current architecture ($arch) does not have a corresponding Julia binary release"; \ 59 | exit 1; \ 60 | ;; \ 61 | esac; \ 62 | \ 63 | curl -fL -o julia.tar.gz.asc "$url.asc"; \ 64 | curl -fL -o julia.tar.gz "$url"; \ 65 | \ 66 | echo "$sha256 *julia.tar.gz" | sha256sum --strict --check -; \ 67 | \ 68 | export GNUPGHOME="$(mktemp -d)"; \ 69 | gpg --batch --keyserver keyserver.ubuntu.com --recv-keys "$JULIA_GPG"; \ 70 | gpg --batch --verify julia.tar.gz.asc julia.tar.gz; \ 71 | gpgconf --kill all; \ 72 | rm -rf "$GNUPGHOME" julia.tar.gz.asc; \ 73 | \ 74 | mkdir "$JULIA_PATH"; \ 75 | tar -xzf julia.tar.gz -C "$JULIA_PATH" --strip-components 1; \ 76 | rm julia.tar.gz; \ 77 | \ 78 | apt-mark auto '.*' > /dev/null; \ 79 | [ -z "$savedAptMark" ] || apt-mark manual $savedAptMark; \ 80 | apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false; \ 81 | \ 82 | # smoke test 83 | julia --version 84 | 85 | COPY docker-entrypoint.sh /usr/local/bin/ 86 | ENTRYPOINT ["docker-entrypoint.sh"] 87 | CMD ["julia"] 88 | -------------------------------------------------------------------------------- /Dockerfile-linux.template: -------------------------------------------------------------------------------- 1 | {{ 2 | include "shared" 3 | ; 4 | def is_alpine: 5 | env.variant | startswith("alpine") 6 | ; 7 | def os_arches: 8 | if is_alpine then 9 | { 10 | amd64: "x86_64", 11 | arm32v6: "armhf", 12 | arm32v7: "armv7", 13 | arm64v8: "aarch64", 14 | i386: "x86", 15 | ppc64le: "ppc64le", 16 | riscv64: "riscv64", 17 | s390x: "s390x", 18 | } 19 | else 20 | { 21 | amd64: "amd64", 22 | arm32v5: "armel", 23 | arm32v7: "armhf", 24 | arm64v8: "arm64", 25 | i386: "i386", 26 | mips64le: "mips64el", 27 | ppc64le: "ppc64el", 28 | riscv64: "riscv64", 29 | s390x: "s390x", 30 | } 31 | end 32 | -}} 33 | FROM {{ from(env.variant) }} 34 | 35 | {{ if is_alpine then "" else ( -}} 36 | RUN set -eux; \ 37 | apt-get update; \ 38 | apt-get install -y --no-install-recommends \ 39 | ca-certificates \ 40 | # ERROR: no download agent available; install curl, wget, or fetch 41 | curl \ 42 | ; \ 43 | rm -rf /var/lib/apt/lists/* 44 | 45 | {{ ) end -}} 46 | ENV JULIA_PATH /usr/local/julia 47 | ENV PATH $JULIA_PATH/bin:$PATH 48 | 49 | # https://julialang.org/juliareleases.asc 50 | # Julia (Binary signing key) 51 | ENV JULIA_GPG 3673DF529D9049477F76B37566E3C7DC03D6E495 52 | 53 | # https://julialang.org/downloads/ 54 | ENV JULIA_VERSION {{ .version }} 55 | 56 | RUN set -eux; \ 57 | \ 58 | {{ if is_alpine then ( -}} 59 | apk add --no-cache --virtual .fetch-deps gnupg; \ 60 | {{ ) else ( -}} 61 | savedAptMark="$(apt-mark showmanual)"; \ 62 | apt-get update; \ 63 | apt-get install -y --no-install-recommends \ 64 | gnupg \ 65 | ; \ 66 | rm -rf /var/lib/apt/lists/*; \ 67 | {{ ) end -}} 68 | \ 69 | # https://julialang.org/downloads/#julia-command-line-version 70 | # https://julialang-s3.julialang.org/bin/checksums/julia-{{ .version }}.sha256 71 | {{ if is_alpine then ( -}} 72 | arch="$(apk --print-arch)"; \ 73 | {{ ) else ( -}} 74 | arch="$(dpkg --print-architecture)"; \ 75 | {{ ) end -}} 76 | case "$arch" in \ 77 | {{ 78 | [ 79 | .arches 80 | | to_entries[] 81 | | select(.key | if is_alpine then startswith("alpine-") else contains("-") | not end) 82 | | (.key | ltrimstr("alpine-")) as $bashbrewArch 83 | | (os_arches[$bashbrewArch] // empty) as $osArch 84 | | .value 85 | | ( 86 | -}} 87 | {{ $osArch | @sh }}) \ 88 | url={{ .url | @sh }}; \ 89 | sha256={{ .sha256 | @sh }}; \ 90 | ;; \ 91 | {{ 92 | ) 93 | ] | add 94 | -}} 95 | *) \ 96 | echo >&2 "error: current architecture ($arch) does not have a corresponding Julia binary release"; \ 97 | exit 1; \ 98 | ;; \ 99 | esac; \ 100 | \ 101 | {{ def wget: if is_alpine then "wget -O" else "curl -fL -o" end -}} 102 | {{ wget }} julia.tar.gz.asc "$url.asc"; \ 103 | {{ wget }} julia.tar.gz "$url"; \ 104 | \ 105 | echo "$sha256 *julia.tar.gz" | sha256sum {{ if is_alpine then "-w -c" else "--strict --check" end }} -; \ 106 | \ 107 | export GNUPGHOME="$(mktemp -d)"; \ 108 | gpg --batch --keyserver keyserver.ubuntu.com --recv-keys "$JULIA_GPG"; \ 109 | gpg --batch --verify julia.tar.gz.asc julia.tar.gz; \ 110 | gpgconf --kill all; \ 111 | rm -rf "$GNUPGHOME" julia.tar.gz.asc; \ 112 | \ 113 | mkdir "$JULIA_PATH"; \ 114 | tar -xzf julia.tar.gz -C "$JULIA_PATH" --strip-components 1; \ 115 | rm julia.tar.gz; \ 116 | \ 117 | {{ if is_alpine then ( -}} 118 | apk del --no-network .fetch-deps; \ 119 | {{ ) else ( -}} 120 | apt-mark auto '.*' > /dev/null; \ 121 | [ -z "$savedAptMark" ] || apt-mark manual $savedAptMark; \ 122 | apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false; \ 123 | {{ ) end -}} 124 | \ 125 | # smoke test 126 | julia --version 127 | 128 | COPY docker-entrypoint.sh /usr/local/bin/ 129 | ENTRYPOINT ["docker-entrypoint.sh"] 130 | CMD ["julia"] 131 | -------------------------------------------------------------------------------- /generate-stackbrew-library.jq: -------------------------------------------------------------------------------- 1 | include "shared"; 2 | 3 | to_entries 4 | | map_values(select(.)) # ignore nulls ("rc" post-GA) 5 | 6 | | ( 7 | # our entries are in precedence order, so loop over them in order and assign "generic" tags like "1" to the first entry that might use them 8 | reduce .[] as $v ({}; 9 | .[ 10 | $v.value.version 11 | | if $v.key == "rc" then 12 | # pre-releases get an intentionally limited set of tags 13 | [ 14 | ., # "1.13.0-alpha2" 15 | (split(".")[0:2] | join(".") + "-rc"), # "1.13-rc" 16 | "rc", 17 | empty 18 | ] 19 | else 20 | # TODO should we add an explicit "stable" alias? for us, that's currently spelled "latest" and that's probably good enough? 21 | # (see similar TODO in "versions.sh" about "lts") 22 | split(".") 23 | | [ 24 | foreach .[] as $c ([]; . += [ $c ]) 25 | | join(".") 26 | ] 27 | | reverse + [ "" ] 28 | end 29 | | .[] 30 | ] //= $v.key 31 | ) 32 | # now that object is backwards ({ "1": "stable", "1.X": "stable" }), so let's reduce it back the other way ({ "stable": [ "1", "1.X" ] }) so lookups are trivial below 33 | | reduce to_entries[] as $e ({}; .[$e.value] += [ $e.key ]) 34 | ) as $versionsTags 35 | 36 | | (first(.[].value.variants[] | select(startswith("alpine") or startswith("windows/") | not)) // "") as $latestDebian 37 | | (first(.[].value.variants[] | select(startswith("alpine"))) // "") as $latestAlpine 38 | 39 | | .[] 40 | | .key as $key 41 | | .value 42 | 43 | # only the major versions asked for "./generate-stackbrew-library.sh X Y ..." 44 | | if $ARGS.positional != [] then 45 | select(IN($key; $ARGS.positional[])) 46 | else . end 47 | 48 | | $versionsTags[$key] as $versionTags 49 | 50 | | .variants[] as $variant # "trixie", "alpine3.22", "windows/servercore-ltsc2025", etc 51 | 52 | # Tags: 53 | | [ 54 | ( 55 | $variant 56 | | if startswith("windows/servercore-") then 57 | sub("/"; "") 58 | elif startswith("windows/nanoserver-") then 59 | ltrimstr("windows/") 60 | else 61 | . 62 | end 63 | ), 64 | 65 | if $variant == $latestAlpine then 66 | "alpine" 67 | else empty end, 68 | 69 | empty 70 | 71 | | $versionTags[] as $versionTag 72 | | [ $versionTag, . | select(. != "") ] 73 | | join("-") 74 | | if . == "" then "latest" else . end 75 | ] as $tags 76 | 77 | # SharedTags: 78 | | [ 79 | ( 80 | $variant 81 | | if startswith("windows/servercore-") then 82 | "windowsservercore", 83 | "" 84 | elif startswith("windows/nanoserver-") then 85 | "nanoserver" 86 | elif . == $latestDebian then 87 | "" 88 | else empty end 89 | ), 90 | 91 | empty 92 | 93 | | $versionTags[] as $versionTag 94 | | [ $versionTag, . | select(. != "") ] 95 | | join("-") 96 | | if . == "" then "latest" else . end 97 | ] as $sharedTags 98 | 99 | # Architectures: 100 | | ( 101 | .arches 102 | | keys_unsorted 103 | 104 | | if $variant | startswith("alpine") then 105 | map( 106 | select(startswith("alpine-")) 107 | | ltrimstr("alpine-") 108 | ) 109 | else . end 110 | 111 | | ( 112 | $parentsArches[from($variant)] 113 | // if $variant | startswith("windows/") then 114 | [ "windows-amd64" ] # TODO windows-arm64v8 someday? 115 | else [] end 116 | ) as $parentArches 117 | | . - (. - $parentArches) # intersection 118 | ) as $arches 119 | 120 | | ( 121 | "", 122 | "Tags: \($tags | join(", "))", 123 | if $sharedTags != [] then "SharedTags: \($sharedTags | join(", "))" else empty end, 124 | "Directory: \($key)/\($variant)", 125 | "Architectures: \($arches | join(", "))", 126 | ( 127 | $variant 128 | | if startswith("windows/") then 129 | split("-")[-1] as $winver 130 | | [ 131 | if startswith("windows/nanoserver-") then 132 | "nanoserver-" + $winver 133 | else empty end, 134 | "windowsservercore-" + $winver, 135 | empty 136 | ] 137 | | "Constraints: " + join(", ") 138 | else empty end 139 | ), 140 | empty 141 | ) 142 | -------------------------------------------------------------------------------- /versions.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | set -Eeuo pipefail 3 | 4 | cd "$(dirname "$(readlink -f "$BASH_SOURCE")")" 5 | 6 | versions=( "$@" ) 7 | if [ ${#versions[@]} -eq 0 ]; then 8 | versions=( */ ) 9 | json='{}' 10 | else 11 | json="$(< versions.json)" 12 | fi 13 | versions=( "${versions[@]%/}" ) 14 | 15 | # TODO scrape LTS version track from somewhere so we can rename the "1.x" folder of LTS to just "lts" and have this script deal with it completely 16 | # see also https://github.com/docker-library/julia/issues/92 17 | 18 | # https://julialang.org/downloads/#json_release_feed 19 | # https://julialang-s3.julialang.org/bin/versions.json 20 | # https://julialang-s3.julialang.org/bin/versions-schema.json 21 | juliaVersions="$( 22 | wget -qO- 'https://julialang-s3.julialang.org/bin/versions.json' | jq -c ' 23 | [ 24 | to_entries[] 25 | | .key as $version 26 | | .value 27 | | { 28 | $version, 29 | stable, 30 | arches: (.files | map( 31 | # map values from the julia versions-schema.json to bashbrew architecture values 32 | # (plus some extra fiddly bits for Alpine) 33 | { 34 | mac: "darwin", 35 | winnt: "windows", 36 | linux: ( 37 | if .triplet | endswith("-musl") then 38 | "alpine" 39 | else 40 | "linux" 41 | end 42 | ), 43 | freebsd: "freebsd", 44 | }[.os] as $os 45 | | { 46 | x86_64: "amd64", 47 | i686: "i386", 48 | powerpc64le: "ppc64le", 49 | aarch64: "arm64v8", 50 | armv7l: "arm32v7", 51 | }[.arch] as $arch 52 | | if $os == null or $arch == null then empty 53 | elif .kind != (if $os == "windows" then "installer" else "archive" end) then empty 54 | else { 55 | key: ( 56 | if $os == "linux" then "" else $os + "-" end 57 | + $arch 58 | ), 59 | value: { 60 | url: .url, 61 | sha256: .sha256, 62 | }, 63 | } end 64 | ) | from_entries), 65 | } 66 | ] 67 | 68 | | ( 69 | def scan_version: 70 | [ 71 | scan("[0-9]+|[^0-9]+|^$") 72 | | tonumber? // . 73 | ] 74 | ; 75 | 76 | sort_by(.version | scan_version) 77 | | reverse 78 | 79 | | first(.[] | select(.stable) | .version) as $stable 80 | | first(.[] | select(.stable | not) | .version) as $rc 81 | | if ($stable | scan_version) >= ($rc | scan_version) then 82 | # if latest "stable" is newer than the latest pre-release, remove *all* the pre-releases 83 | map(select(.stable)) 84 | else . end 85 | ) 86 | ' 87 | )" 88 | 89 | for version in "${versions[@]}"; do 90 | export version 91 | 92 | if \ 93 | ! doc="$(jq <<<"$juliaVersions" -ce ' 94 | first(.[] | select( 95 | if IN(env.version; "stable", "rc") then 96 | .stable == (env.version == "stable") 97 | else 98 | .stable and ( 99 | .version 100 | | startswith(env.version + ".") 101 | ) 102 | end 103 | )) 104 | ')" \ 105 | || ! fullVersion="$(jq <<<"$doc" -r '.version')" \ 106 | || [ -z "$fullVersion" ] \ 107 | ; then 108 | echo >&2 "warning: cannot find full version for $version" 109 | json="$(jq <<<"$json" -c '.[env.version] = null')" 110 | continue 111 | fi 112 | 113 | echo "$version: $fullVersion" 114 | 115 | json="$(jq <<<"$json" -c --argjson doc "$doc" '.[env.version] = ( 116 | $doc 117 | | del(.stable) 118 | | .variants = ([ 119 | "trixie", 120 | "bookworm", 121 | if .arches | keys | any(startswith("alpine-")) then 122 | "3.23", 123 | "3.22", 124 | empty 125 | | "alpine" + . 126 | else empty end, 127 | if .arches | has("windows-amd64") then # TODO "windows-arm64v8" someday? 👀 128 | "ltsc2025", 129 | "ltsc2022", 130 | empty 131 | | "windows/servercore-" + . 132 | else empty end 133 | ]) 134 | )')" 135 | done 136 | 137 | jq <<<"$json" ' 138 | to_entries 139 | | sort_by( 140 | .key as $k 141 | # match the order on https://julialang.org/downloads/manual-downloads/ 142 | | [ "stable", "lts" ] | (index($k) // length + ([ "rc" ] | (index($k) // -1) + 1)), $k 143 | # (this is a compressed clone of https://github.com/docker-library/meta-scripts/blob/af716438af4178d318a03f4144668d76c9c8222f/sort.jq#L29-L52) 144 | ) 145 | | from_entries 146 | ' > versions.json 147 | -------------------------------------------------------------------------------- /versions.json: -------------------------------------------------------------------------------- 1 | { 2 | "stable": { 3 | "version": "1.12.2", 4 | "arches": { 5 | "amd64": { 6 | "url": "https://julialang-s3.julialang.org/bin/linux/x64/1.12/julia-1.12.2-linux-x86_64.tar.gz", 7 | "sha256": "a6d0c39ea57303ebcffa7a8d453429b86eb271e150c7cb0f5958fe65909b493a" 8 | }, 9 | "i386": { 10 | "url": "https://julialang-s3.julialang.org/bin/linux/x86/1.12/julia-1.12.2-linux-i686.tar.gz", 11 | "sha256": "e7492e2454ecfd03f4da6fd30fb60391d184128bf683c96d1ea6f13cd35a20c8" 12 | }, 13 | "arm64v8": { 14 | "url": "https://julialang-s3.julialang.org/bin/linux/aarch64/1.12/julia-1.12.2-linux-aarch64.tar.gz", 15 | "sha256": "0383a2ce378b64356269f6f15e612f344523f507a9753f71a0b64ca02092445b" 16 | }, 17 | "darwin-amd64": { 18 | "url": "https://julialang-s3.julialang.org/bin/mac/x64/1.12/julia-1.12.2-mac64.tar.gz", 19 | "sha256": "c4bf4dfb76cfb017311bfc22ada369d1cf27fc27cb32882358a758e190026a8b" 20 | }, 21 | "darwin-arm64v8": { 22 | "url": "https://julialang-s3.julialang.org/bin/mac/aarch64/1.12/julia-1.12.2-macaarch64.tar.gz", 23 | "sha256": "08cdada747db752e0cd733eda3caba20136ef1729723e4065cec83d412d70d6e" 24 | }, 25 | "windows-amd64": { 26 | "url": "https://julialang-s3.julialang.org/bin/winnt/x64/1.12/julia-1.12.2-win64.exe", 27 | "sha256": "b8c6ffd3f760e088820f0f208b799167a02d528df467337852ffcc599eaa8e7e" 28 | }, 29 | "windows-i386": { 30 | "url": "https://julialang-s3.julialang.org/bin/winnt/x86/1.12/julia-1.12.2-win32.exe", 31 | "sha256": "cb915520b4d8bd12ef966e4fa55810c105e72c0b858223cb45a57ef2c5d23150" 32 | }, 33 | "freebsd-amd64": { 34 | "url": "https://julialang-s3.julialang.org/bin/freebsd/x64/1.12/julia-1.12.2-freebsd-x86_64.tar.gz", 35 | "sha256": "9ff4561d89a17a985aca78f33b0f77e8c0c5634117e754cd03614a588637508c" 36 | } 37 | }, 38 | "variants": [ 39 | "trixie", 40 | "bookworm", 41 | "windows/servercore-ltsc2025", 42 | "windows/servercore-ltsc2022" 43 | ] 44 | }, 45 | "1.10": { 46 | "version": "1.10.10", 47 | "arches": { 48 | "amd64": { 49 | "url": "https://julialang-s3.julialang.org/bin/linux/x64/1.10/julia-1.10.10-linux-x86_64.tar.gz", 50 | "sha256": "6a78a03a71c7ab792e8673dc5cedb918e037f081ceb58b50971dfb7c64c5bf81" 51 | }, 52 | "i386": { 53 | "url": "https://julialang-s3.julialang.org/bin/linux/x86/1.10/julia-1.10.10-linux-i686.tar.gz", 54 | "sha256": "32186f38e7f6c7830375da1d1327bec3b187d93e3f0ff007829f20f578fd8c35" 55 | }, 56 | "arm64v8": { 57 | "url": "https://julialang-s3.julialang.org/bin/linux/aarch64/1.10/julia-1.10.10-linux-aarch64.tar.gz", 58 | "sha256": "a4b157ed68da10471ea86acc05a0ab61c1a6931ee592a9b236be227d72da50ff" 59 | }, 60 | "ppc64le": { 61 | "url": "https://julialang-s3.julialang.org/bin/linux/ppc64le/1.10/julia-1.10.10-linux-ppc64le.tar.gz", 62 | "sha256": "f47516c511f100670cad72f3c7a1d95d2c20862f1aa14b1162b0b90424167f16" 63 | }, 64 | "alpine-amd64": { 65 | "url": "https://julialang-s3.julialang.org/bin/musl/x64/1.10/julia-1.10.10-musl-x86_64.tar.gz", 66 | "sha256": "2d109f3f96f2be8ea45a0676f506642c20d972aeb3d526e8fa10ed49c0d6c786" 67 | }, 68 | "darwin-amd64": { 69 | "url": "https://julialang-s3.julialang.org/bin/mac/x64/1.10/julia-1.10.10-mac64.tar.gz", 70 | "sha256": "942b0d4accc9704861c7781558829b1d521df21226ad97bd01e1e43b1518d3e6" 71 | }, 72 | "darwin-arm64v8": { 73 | "url": "https://julialang-s3.julialang.org/bin/mac/aarch64/1.10/julia-1.10.10-macaarch64.tar.gz", 74 | "sha256": "52d3f82c50d9402e42298b52edc3d36e0f73e59f81fc8609d22fa094fbad18be" 75 | }, 76 | "windows-amd64": { 77 | "url": "https://julialang-s3.julialang.org/bin/winnt/x64/1.10/julia-1.10.10-win64.exe", 78 | "sha256": "c2a9087064a193e8c2219cc03fac2264445bc9ccf626e30acc39ebd5fa7ad09f" 79 | }, 80 | "windows-i386": { 81 | "url": "https://julialang-s3.julialang.org/bin/winnt/x86/1.10/julia-1.10.10-win32.exe", 82 | "sha256": "8e52c9ebcdf58a7ba54dad8280cda5b5775489f121bc7a73dc85083d5982d6f7" 83 | }, 84 | "freebsd-amd64": { 85 | "url": "https://julialang-s3.julialang.org/bin/freebsd/x64/1.10/julia-1.10.10-freebsd-x86_64.tar.gz", 86 | "sha256": "df2990b7461f6b3f753dd714cda3335d79168967f47a633baa9ebc583e10e6b4" 87 | } 88 | }, 89 | "variants": [ 90 | "trixie", 91 | "bookworm", 92 | "alpine3.23", 93 | "alpine3.22", 94 | "windows/servercore-ltsc2025", 95 | "windows/servercore-ltsc2022" 96 | ] 97 | }, 98 | "rc": { 99 | "version": "1.13.0-alpha2", 100 | "arches": { 101 | "amd64": { 102 | "url": "https://julialang-s3.julialang.org/bin/linux/x64/1.13/julia-1.13.0-alpha2-linux-x86_64.tar.gz", 103 | "sha256": "987aa3aad11e0b5c078dfdee7f8d54eeabdc10bcddd245bda18e28ab4de6119d" 104 | }, 105 | "i386": { 106 | "url": "https://julialang-s3.julialang.org/bin/linux/x86/1.13/julia-1.13.0-alpha2-linux-i686.tar.gz", 107 | "sha256": "15b15af06b603efa0523e2f1b19cacaefcddda13595906c276ddec0b3194c0b2" 108 | }, 109 | "arm64v8": { 110 | "url": "https://julialang-s3.julialang.org/bin/linux/aarch64/1.13/julia-1.13.0-alpha2-linux-aarch64.tar.gz", 111 | "sha256": "c558a08f69d1984096d0bac825148cba2dd6b2eea3c5a3d8a5def2cd718af196" 112 | }, 113 | "darwin-amd64": { 114 | "url": "https://julialang-s3.julialang.org/bin/mac/x64/1.13/julia-1.13.0-alpha2-mac64.tar.gz", 115 | "sha256": "d14484d4335cf3259eb62ea48095f18f9e8cb1de9f37c6961adc03aea4942e95" 116 | }, 117 | "darwin-arm64v8": { 118 | "url": "https://julialang-s3.julialang.org/bin/mac/aarch64/1.13/julia-1.13.0-alpha2-macaarch64.tar.gz", 119 | "sha256": "c9273c63c065139f802c7f52d81c985eba08aed41e428ae377ff0b6786c29346" 120 | }, 121 | "windows-amd64": { 122 | "url": "https://julialang-s3.julialang.org/bin/winnt/x64/1.13/julia-1.13.0-alpha2-win64.exe", 123 | "sha256": "ec84bd651c739436b2ab397f4a156ed269030f277d075031104eecbf6904079a" 124 | }, 125 | "windows-i386": { 126 | "url": "https://julialang-s3.julialang.org/bin/winnt/x86/1.13/julia-1.13.0-alpha2-win32.exe", 127 | "sha256": "ef006e89ce706ef94e2fdba19aa7a153523f927e0e2ae4eea5dc00953d4261a5" 128 | }, 129 | "freebsd-amd64": { 130 | "url": "https://julialang-s3.julialang.org/bin/freebsd/x64/1.13/julia-1.13.0-alpha2-freebsd-x86_64.tar.gz", 131 | "sha256": "8d530bb48af0ba99467b00236e1c0e10872302a729b40d719a241b2ec9885393" 132 | } 133 | }, 134 | "variants": [ 135 | "trixie", 136 | "bookworm", 137 | "windows/servercore-ltsc2025", 138 | "windows/servercore-ltsc2022" 139 | ] 140 | } 141 | } 142 | --------------------------------------------------------------------------------