-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: bump image and bump actions versions
- Loading branch information
Showing
3 changed files
with
25 additions
and
25 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,14 @@ | ||
# syntax=docker/dockerfile:1 | ||
ARG PYTHON_VERSION="3.11" | ||
ARG PYTHON_VERSION="3.12" | ||
FROM mcr.microsoft.com/devcontainers/python:${PYTHON_VERSION} | ||
|
||
LABEL org.opencontainers.image.authors="Ryan Boehning <[email protected]>" | ||
|
||
RUN <<-EOT | ||
apt update | ||
apt full-upgrade | ||
rm -rf /var/lib/apt/lists/* | ||
apt update | ||
apt full-upgrade | ||
apt clean | ||
rm -rf /var/lib/apt/lists/* | ||
EOT | ||
|
||
# Enable pipefail to catch errors. | ||
|
@@ -17,26 +18,25 @@ SHELL ["/bin/zsh", "-o", "pipefail", "-c"] | |
RUN sed -i 's/\/home\/vscode:\/bin\/bash/\/home\/vscode:\/bin\/zsh/' /etc/passwd | ||
USER vscode | ||
|
||
# Create local bin directory for gh, poetry, and other command line tools. | ||
RUN mkdir -p /home/vscode/.local/bin | ||
ENV PATH="/home/vscode/.local/bin:$PATH" | ||
|
||
# Remove shell configs from the base image. | ||
RUN rm -rf ~/.bash_logout ~/.bashrc ~/.oh-my-zsh ~/.profile | ||
|
||
# Install the latest gh CLI tool. The first request fetches the URL for the | ||
# latest release tarball. The second request downloads the tarball. | ||
# Create local bin directory for gh, poetry, and other command line tools. | ||
RUN mkdir -p /home/vscode/.local/bin | ||
|
||
# Install poetry and enable its completions. | ||
RUN <<-EOT | ||
wget --quiet --timeout=30 --output-document=- 'https://api.github.com/repos/cli/cli/releases/latest' | | ||
jq -r ".assets[] | select(.name | test(\"gh_.*?_linux_amd64.tar.gz\")).browser_download_url" | | ||
wget --quiet --timeout=180 --input-file=- --output-document=- | | ||
tar -xvz -C /home/vscode/.local/ --strip-components=1 | ||
curl -sSL https://install.python-poetry.org | python - | ||
mkdir -p ~/.zfunc | ||
poetry completions zsh > ~/.zfunc/_poetrywhic | ||
fpath+=~/.zfunc | ||
EOT | ||
|
||
# Install poetry and enable its completions. | ||
# Install the latest gh CLI tool. The first request fetches the URL for the | ||
# latest release tarball. The second request downloads the tarball. | ||
RUN <<-EOT | ||
curl -sSL https://install.python-poetry.org | python - | ||
mkdir -p ~/.zfunc | ||
poetry completions zsh > ~/.zfunc/_poetrywhic | ||
fpath+=~/.zfunc | ||
wget --quiet --timeout=30 --output-document=- 'https://api.github.com/repos/cli/cli/releases/latest' | | ||
jq -r ".assets[] | select(.name | test(\"gh_.*?_linux_amd64.tar.gz\")).browser_download_url" | | ||
wget --quiet --timeout=180 --input-file=- --output-document=- | | ||
tar -xvz -C ~/.local/bin --strip-components=2 | ||
EOT |